车辆对接

This commit is contained in:
wangshiming
2022-01-13 19:22:42 +08:00
parent 03af0d2dfb
commit 8bab2011fd
5 changed files with 68 additions and 99 deletions

View File

@ -42,8 +42,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
currentRate = 0; //实时计算的费率
id = this.route.snapshot.params.id;
// // 单位
startInfo: any = []; // 发货地数据
endInfo: any = []; // 卸货地数据
startInfo: any = []; // 发货地数据
endInfo: any = []; // 卸货地数据
PageStatus = '';
enterpriseProjectIds: any;
constructor(
@ -488,9 +488,11 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
type: 'number',
title: '预付',
minimum: 0,
maximum: 999999,
default: 0,
ui: {
prefix: '¥',
widgetWidth: 300,
change: _args => this.payChange()
} as SFNumberWidgetSchema
},
@ -498,22 +500,37 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
type: 'number',
title: '到付',
minimum: 0,
maximum: 999999,
default: 0,
ui: { prefix: '¥', change: _args => this.payChange() } as SFNumberWidgetSchema
ui: {
prefix: '¥',
widgetWidth: 300,
change: _args => this.payChange()
} as SFNumberWidgetSchema
},
oilCardPay: {
type: 'number',
title: '油卡',
minimum: 0,
maximum: 999999,
default: 0,
ui: { prefix: '¥', change: _args => this.payChange() } as SFNumberWidgetSchema
ui: {
prefix: '¥',
widgetWidth: 300,
change: _args => this.payChange()
} as SFNumberWidgetSchema
},
receiptPay: {
type: 'number',
title: '回单付',
minimum: 0,
maximum: 999999,
default: 0,
ui: { prefix: '¥', change: _args => this.payChange() } as SFNumberWidgetSchema
ui: {
prefix: '¥',
widgetWidth: 300,
change: _args => this.payChange()
} as SFNumberWidgetSchema
},
subtotal: { type: 'number', title: '小计', default: 0, ui: { widget: 'custom' } as SFNumberWidgetSchema },
appendFee: { type: 'number', title: '附加费', default: 0, ui: { widget: 'custom' } as SFNumberWidgetSchema },
@ -539,24 +556,24 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
}
// 获取城市列表
getRegionCode(regionCode: any) {
console.log(regionCode);
return this.service
.request(this.service.$api_get_enterprise_project, { id: regionCode })
.pipe(
map(res =>
res.map((item: any) => ({
label: item.projectName,
value: item.id
}))
)
console.log(regionCode);
return this.service
.request(this.service.$api_get_enterprise_project, { id: regionCode })
.pipe(
map(res =>
res.map((item: any) => ({
label: item.projectName,
value: item.id
}))
)
.subscribe(res => {
this.sf1.getProperty('/enterpriseProjectId')!.schema.enum = res;
this.sf1.getProperty('/enterpriseProjectId')!.widget.reset(res);
if (this.enterpriseProjectIds) {
this.sf1.setValue('/enterpriseProjectId', this.enterpriseProjectIds);
}
});
)
.subscribe(res => {
this.sf1.getProperty('/enterpriseProjectId')!.schema.enum = res;
this.sf1.getProperty('/enterpriseProjectId')!.widget.reset(res);
if (this.enterpriseProjectIds) {
this.sf1.setValue('/enterpriseProjectId', this.enterpriseProjectIds);
}
});
}
changeValue() {
this.totalFees =
@ -722,7 +739,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
nzContent: PublishSuccessComponent,
nzWidth: 900,
nzFooter: null,
nzComponentParams: { type: 'onecar', resourceObj , change: change}
nzComponentParams: { type: 'onecar', resourceObj, change: change }
});
}
// 提交前确认,委托运输协议弹窗
@ -816,7 +833,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
if (this.PageStatus === '整车修改') {
this.requests(this.service.$api_set_WholeModify, params, 1);
} else if (this.PageStatus === '整车下一单') {
this.requests(this.service.$api_set_saveAnotherWholeOrder, params,2);
this.requests(this.service.$api_set_saveAnotherWholeOrder, params, 2);
}
}
addPreZero(num: any) {