|
|
|
@ -11,6 +11,7 @@ import {LocalStorageService} from '../../../services/local-storage.service'; |
|
|
|
|
import {CommonsService} from '../../../services/commons.service'; |
|
|
|
|
import {WebsocketService} from '../../../services/websocket.service'; |
|
|
|
|
import {ADMIN_INFO_OBJECT} from '../../../services/local-storage.namespace'; |
|
|
|
|
import {MerchantStoreService} from "../../../services/merchant-store.service"; |
|
|
|
|
|
|
|
|
|
@Component({ |
|
|
|
|
selector: 'app-oil-station-order', |
|
|
|
@ -37,15 +38,7 @@ export class OilStationOrderComponent implements OnInit { |
|
|
|
|
roleType: number; |
|
|
|
|
secUser: object; |
|
|
|
|
|
|
|
|
|
printDataObject: PrintData = { |
|
|
|
|
gasName: '', |
|
|
|
|
orderNo: '', |
|
|
|
|
createTime: '', |
|
|
|
|
gasOilNo: '', |
|
|
|
|
gasGunNo: '', |
|
|
|
|
gasOilLiters: 0, |
|
|
|
|
oilPrice: 0 |
|
|
|
|
}; |
|
|
|
|
gasArray = []; |
|
|
|
|
|
|
|
|
|
constructor( |
|
|
|
|
private form: FormBuilder, |
|
|
|
@ -56,6 +49,7 @@ export class OilStationOrderComponent implements OnInit { |
|
|
|
|
private router: Router, |
|
|
|
|
private company: CompanyService, |
|
|
|
|
private merchant: MerchantService, |
|
|
|
|
private merchantStoreService: MerchantStoreService, |
|
|
|
|
private orderService: OrderService, |
|
|
|
|
private store: LocalStorageService, // 数据请求
|
|
|
|
|
private common: CommonsService |
|
|
|
@ -64,6 +58,13 @@ export class OilStationOrderComponent implements OnInit { |
|
|
|
|
|
|
|
|
|
ngOnInit(): void { |
|
|
|
|
this.secUser = this.store.get(ADMIN_INFO_OBJECT)['secUser']; |
|
|
|
|
if (this.secUser['objectType'] === 2) { |
|
|
|
|
this.merchantStoreService.getStoreListByMerchant({ pageNum: 1, pageSize: 100}, data => { |
|
|
|
|
if (data['return_code'] === '000000') { |
|
|
|
|
this.gasArray = data['return_data']['list']; |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
this.init(); |
|
|
|
|
// 接收消息
|
|
|
|
|
this.webSocketService.messageSubject.subscribe( |
|
|
|
@ -77,6 +78,7 @@ export class OilStationOrderComponent implements OnInit { |
|
|
|
|
|
|
|
|
|
public init(): void { |
|
|
|
|
this.searchForm = this.form.group({ |
|
|
|
|
storeId: [null], |
|
|
|
|
orderNo: [null], |
|
|
|
|
status: [null], |
|
|
|
|
createTime: [null], |
|
|
|
|