车辆对接
This commit is contained in:
@ -633,7 +633,7 @@ tabs = {
|
|||||||
nzTitle: '变更运费',
|
nzTitle: '变更运费',
|
||||||
nzWidth: 580,
|
nzWidth: 580,
|
||||||
nzContent: UpdateFreightComponent,
|
nzContent: UpdateFreightComponent,
|
||||||
nzComponentParams: { data },
|
nzComponentParams: { data: { ...data, billId: item.id } },
|
||||||
nzOnOk: sin => {
|
nzOnOk: sin => {
|
||||||
this.service.request(this.service.$api_insertFreightChangeBulk, { billId: item.id, ...sin.sf.value }).subscribe(res => {
|
this.service.request(this.service.$api_insertFreightChangeBulk, { billId: item.id, ...sin.sf.value }).subscribe(res => {
|
||||||
if (res) {
|
if (res) {
|
||||||
|
|||||||
@ -585,7 +585,16 @@ resourceStatus: any;
|
|||||||
nzWidth: 580,
|
nzWidth: 580,
|
||||||
nzContent: VehicleUpdateFreightComponent,
|
nzContent: VehicleUpdateFreightComponent,
|
||||||
nzComponentParams: { data: { ...data, id: item.id } },
|
nzComponentParams: { data: { ...data, id: item.id } },
|
||||||
nzFooter: null
|
nzOnOk: sin => {
|
||||||
|
this.service.request(this.service.$api_change_bulk, { billId: item.id, ...sin.sf.value }).subscribe(res => {
|
||||||
|
if (res) {
|
||||||
|
this.service.msgSrv.success('变更运费成功');
|
||||||
|
modal.destroy();
|
||||||
|
this.st.reload();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
modal.afterClose.subscribe(_ => this.st.reload());
|
modal.afterClose.subscribe(_ => this.st.reload());
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
<!--
|
<!--
|
||||||
* @Author: your name
|
* @Author: your name
|
||||||
* @Date: 2021-12-14 14:03:07
|
* @Date: 2021-12-14 14:03:07
|
||||||
* @LastEditTime: 2021-12-21 15:03:17
|
* @LastEditTime: 2021-12-22 20:04:15
|
||||||
* @LastEditors: your name
|
* @LastEditors: your name
|
||||||
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||||
* @FilePath: \tms-obc-web\src\app\routes\order-management\modal\bulk\update-freight\update-freight.component.html
|
* @FilePath: \tms-obc-web\src\app\routes\order-management\modal\bulk\update-freight\update-freight.component.html
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* @Author: your name
|
* @Author: your name
|
||||||
* @Date: 2021-12-14 14:03:07
|
* @Date: 2021-12-14 14:03:07
|
||||||
* @LastEditTime: 2021-12-14 15:16:27
|
* @LastEditTime: 2021-12-22 20:08:13
|
||||||
* @LastEditors: Please set LastEditors
|
* @LastEditors: Please set LastEditors
|
||||||
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||||
* @FilePath: \tms-obc-web\src\app\routes\order-management\modal\bulk\update-freight\update-freight.component.ts
|
* @FilePath: \tms-obc-web\src\app\routes\order-management\modal\bulk\update-freight\update-freight.component.ts
|
||||||
@ -12,6 +12,8 @@ import {
|
|||||||
SFSelectWidgetSchema,
|
SFSelectWidgetSchema,
|
||||||
SFStringWidgetSchema, SFTextWidgetSchema
|
SFStringWidgetSchema, SFTextWidgetSchema
|
||||||
} from '@delon/form';
|
} from '@delon/form';
|
||||||
|
import { Subscription } from 'rxjs';
|
||||||
|
import { OrderManagementService } from '../../../services/order-management.service';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-order-management-update-freight',
|
selector: 'app-order-management-update-freight',
|
||||||
@ -25,7 +27,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
@Input()
|
@Input()
|
||||||
data: any;
|
data: any;
|
||||||
|
|
||||||
constructor() {}
|
calculateSub!: Subscription;
|
||||||
|
constructor(private service: OrderManagementService) {}
|
||||||
|
|
||||||
ngOnInit(): void {
|
ngOnInit(): void {
|
||||||
this.schema = this.initSF(this.data);
|
this.schema = this.initSF(this.data);
|
||||||
@ -48,7 +51,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
placeholder: '请输入',
|
placeholder: '请输入',
|
||||||
grid: {
|
grid: {
|
||||||
span: 12
|
span: 12
|
||||||
}
|
},
|
||||||
|
change: (val: any) => this.changeNumVal()
|
||||||
} as SFStringWidgetSchema,
|
} as SFStringWidgetSchema,
|
||||||
default: data.freightPrice
|
default: data.freightPrice
|
||||||
},
|
},
|
||||||
@ -106,7 +110,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
grid: {
|
grid: {
|
||||||
span: 12
|
span: 12
|
||||||
},
|
},
|
||||||
hideStep: true
|
hideStep: true,
|
||||||
|
change: (val: any) => this.changeNumVal()
|
||||||
} as SFNumberWidgetSchema
|
} as SFNumberWidgetSchema
|
||||||
},
|
},
|
||||||
acceptVolume: {
|
acceptVolume: {
|
||||||
@ -119,7 +124,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
grid: {
|
grid: {
|
||||||
span: 12
|
span: 12
|
||||||
},
|
},
|
||||||
hideStep: true
|
hideStep: true,
|
||||||
|
change: (val: any) => this.changeNumVal()
|
||||||
} as SFNumberWidgetSchema
|
} as SFNumberWidgetSchema
|
||||||
},
|
},
|
||||||
settlementWeight: {
|
settlementWeight: {
|
||||||
@ -132,7 +138,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
grid: {
|
grid: {
|
||||||
span: 12
|
span: 12
|
||||||
},
|
},
|
||||||
hideStep: true
|
hideStep: true,
|
||||||
|
change: (val: any) => this.changeNumVal()
|
||||||
} as SFNumberWidgetSchema
|
} as SFNumberWidgetSchema
|
||||||
},
|
},
|
||||||
settlementVolume: {
|
settlementVolume: {
|
||||||
@ -145,7 +152,8 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
grid: {
|
grid: {
|
||||||
span: 12
|
span: 12
|
||||||
},
|
},
|
||||||
hideStep: true
|
hideStep: true,
|
||||||
|
change: (val: any) => this.changeNumVal()
|
||||||
} as SFNumberWidgetSchema
|
} as SFNumberWidgetSchema
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -169,4 +177,21 @@ export class UpdateFreightComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
changeNumVal() {
|
||||||
|
if (this.calculateSub) {
|
||||||
|
this.calculateSub.unsubscribe();
|
||||||
|
}
|
||||||
|
this.calculateSub = this.service
|
||||||
|
.request(this.service.$api_calculate_cost, { billId: this.data.billId, ...this.sf.value, changeCause: '' })
|
||||||
|
.subscribe((res: any) => {
|
||||||
|
if (res) {
|
||||||
|
Object.assign(this.data, {
|
||||||
|
totalFreight: res.totalFreight,
|
||||||
|
freight: res.freight,
|
||||||
|
surcharge: res.surcharge
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* @Author: your name
|
* @Author: your name
|
||||||
* @Date: 2021-12-03 15:31:52
|
* @Date: 2021-12-03 15:31:52
|
||||||
* @LastEditTime: 2021-12-22 10:09:37
|
* @LastEditTime: 2021-12-22 20:06:45
|
||||||
* @LastEditors: Please set LastEditors
|
* @LastEditors: Please set LastEditors
|
||||||
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||||
* @FilePath: \tms-obc-web\src\app\routes\order-management\services\order-management.service.ts
|
* @FilePath: \tms-obc-web\src\app\routes\order-management\services\order-management.service.ts
|
||||||
@ -81,7 +81,12 @@ export class OrderManagementService extends BaseService {
|
|||||||
public $api_getChangeRecordBulkDetail = `/api/sdc/billFreightChangeRecord/getChangeRecordBulkDetail`;
|
public $api_getChangeRecordBulkDetail = `/api/sdc/billFreightChangeRecord/getChangeRecordBulkDetail`;
|
||||||
// 查看运费变更记录详情-整车
|
// 查看运费变更记录详情-整车
|
||||||
public $api_getChangeRecordWholeDetail = `/api/sdc/billFreightChangeRecord/getChangeRecordWholeDetail`;
|
public $api_getChangeRecordWholeDetail = `/api/sdc/billFreightChangeRecord/getChangeRecordWholeDetail`;
|
||||||
|
//运费变更申请计算费用-大宗
|
||||||
|
$api_calculate_cost = `/api/sdc/billFreightChangeApplication/getBulkSurchargeDetail`;
|
||||||
|
//运费变更申请计算费用-大宗
|
||||||
|
$api_getWholeSurchargeDetail = `/api/sdc/billFreightChangeApplication/getWholeSurchargeDetail`;
|
||||||
|
//运费变更申请-大宗
|
||||||
|
$api_change_bulk = `/api/sdc/billFreightChangeApplication/insertFreightChangeBulk`;
|
||||||
constructor(public injector: Injector) {
|
constructor(public injector: Injector) {
|
||||||
super(injector)
|
super(injector)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user