Merge branch 'develop' of https://gitlab.eascs.com/tms-ui/tms-obc-web into develop
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-18 09:51:21
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-01-19 11:29:14
|
||||
* @LastEditTime : 2022-01-19 13:56:39
|
||||
* @FilePath : \\tms-obc-web\\proxy.conf.js
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
*/
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-12 10:52:50
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-01-18 17:17:56
|
||||
* @LastEditTime : 2022-01-19 14:39:52
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk\\bulk.component.html
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
-->
|
||||
@ -71,7 +71,7 @@
|
||||
</ng-template>
|
||||
<ng-template st-row="driverName" let-item let-index="index">
|
||||
<div>
|
||||
{{item?.driverName}}/{{item?.driverPhone}}
|
||||
{{item?.driverName}}/{{item?.driverPhone}}/{{item?.carNo}}
|
||||
</div>
|
||||
</ng-template>
|
||||
<ng-template st-row="payeeName" let-item let-index="index">
|
||||
|
||||
@ -238,7 +238,7 @@ export class OrderManagementBulkComponent implements OnInit {
|
||||
}
|
||||
}
|
||||
},
|
||||
captainName: {
|
||||
carCaptainName: {
|
||||
title: '车队长',
|
||||
type: 'string',
|
||||
ui: {
|
||||
@ -247,7 +247,7 @@ export class OrderManagementBulkComponent implements OnInit {
|
||||
}
|
||||
}
|
||||
},
|
||||
paymentstatus: {
|
||||
paymentStatus: {
|
||||
title: '支付状态',
|
||||
type: 'string',
|
||||
ui: {
|
||||
@ -427,7 +427,7 @@ export class OrderManagementBulkComponent implements OnInit {
|
||||
{
|
||||
title: '承运司机',
|
||||
className: 'text-left',
|
||||
width: '180px',
|
||||
width: '250px',
|
||||
index: 'driverName',
|
||||
render: 'driverName'
|
||||
},
|
||||
|
||||
@ -126,6 +126,7 @@ export class OrderManagementComplaintComponent implements OnInit {
|
||||
{
|
||||
title: '投诉单号',
|
||||
width: '170px',
|
||||
fixed: 'left',
|
||||
className: 'text-center',
|
||||
render: 'complaintCode'
|
||||
},
|
||||
@ -141,7 +142,7 @@ export class OrderManagementComplaintComponent implements OnInit {
|
||||
index: 'complainantTime',
|
||||
className: 'text-center',
|
||||
},
|
||||
{ title: '托运方', index: 'shipperAppUserName', width: '120px', className: 'text-center' },
|
||||
{ title: '托运方', index: 'shipperAppUserName', width: '200px', className: 'text-center' },
|
||||
{ title: '司机', index: 'driverIdLabel', width: '120px', className: 'text-center' },
|
||||
{
|
||||
title: '投诉原因',
|
||||
|
||||
@ -223,23 +223,23 @@ export class OrderManagementRiskComponent implements OnInit {
|
||||
initST() {
|
||||
this.columns = [
|
||||
{ title: '', type: 'checkbox', width: '50px', className: 'text-center' },
|
||||
{
|
||||
title: '申诉状态',
|
||||
width: '100px',
|
||||
className: 'text-left',
|
||||
index: 'representationsStatusLabel'
|
||||
},
|
||||
{
|
||||
title: '订单号',
|
||||
width: '200px',
|
||||
className: 'text-left',
|
||||
render: 'billCode'
|
||||
},
|
||||
{
|
||||
title: '申诉状态',
|
||||
width: '100px',
|
||||
className: 'text-left',
|
||||
index: 'representationsStatusLabel'
|
||||
},
|
||||
{
|
||||
title: '货源编号',
|
||||
width: '200px',
|
||||
className: 'text-left',
|
||||
index: 'resourceId'
|
||||
index: 'resourceCode'
|
||||
},
|
||||
{
|
||||
title: '异常信息',
|
||||
|
||||
@ -4,7 +4,7 @@
|
||||
* @Author : Shiming
|
||||
* @Date : 2022-01-12 10:52:50
|
||||
* @LastEditors : Shiming
|
||||
* @LastEditTime : 2022-01-18 17:12:59
|
||||
* @LastEditTime : 2022-01-19 14:39:41
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle\\vehicle.component.html
|
||||
* Copyright (C) 2022 huzhenhong. All rights reserved.
|
||||
-->
|
||||
@ -101,7 +101,7 @@
|
||||
</ng-template>
|
||||
<ng-template st-row="driverName" let-item let-index="index">
|
||||
<div>
|
||||
{{item?.driverName}}/{{item?.driverPhone}}
|
||||
{{item?.driverName}}/{{item?.driverPhone}}/{{item?.carNo}}
|
||||
</div>
|
||||
</ng-template>
|
||||
<ng-template st-row="payeeName" let-item let-index="index">
|
||||
|
||||
@ -239,7 +239,7 @@ resourceStatus: any;
|
||||
}
|
||||
}
|
||||
},
|
||||
captainName: {
|
||||
carCaptainName: {
|
||||
title: '车队长',
|
||||
type: 'string',
|
||||
ui: {
|
||||
@ -384,7 +384,7 @@ resourceStatus: any;
|
||||
}, {
|
||||
title: '承运司机',
|
||||
className: 'text-left',
|
||||
width: '180px',
|
||||
width: '250px',
|
||||
render: 'driverName'
|
||||
},
|
||||
{
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex;">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
@ -92,7 +92,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex;">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
@ -240,8 +240,8 @@
|
||||
<nz-card>
|
||||
<div class="align-center">
|
||||
<!-- <button nz-button nzType="primary" (click)="chooseFamifiar()">生成二维码</button> -->
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submit('assign')">指派熟车</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('assign')">指派熟车</button>
|
||||
<!-- <button nz-button nzType="primary" (click)="choose()">取消</button> -->
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submit('publish')">司机抢单</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')">司机抢单</button>
|
||||
</div>
|
||||
</nz-card>
|
||||
|
||||
@ -19,6 +19,7 @@ import { map } from 'rxjs/operators';
|
||||
import { of } from 'rxjs';
|
||||
import { PublishSuccessComponent } from '../onecar-publish/publish-success/publish-success.component';
|
||||
import { PublishAddressListComponent } from '../onecar-publish/address-list/address-list.component';
|
||||
import { TranAgreementComponent } from '../tran-agreement/tran-agreement.component';
|
||||
@Component({
|
||||
selector: 'app-publish-goods-bulk-publish',
|
||||
templateUrl: './bulk-publish.component.html',
|
||||
@ -51,16 +52,15 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
private modalService: NzModalService,
|
||||
public service: SupplyManagementService,
|
||||
private amapService: AmapService,
|
||||
public shipperSrv: ShipperBaseService,) {
|
||||
public shipperSrv: ShipperBaseService
|
||||
) {
|
||||
this.validateForm1 = fb.group({
|
||||
createTime: [null, []],
|
||||
modifyTime: [null, []],
|
||||
loadAddress0: [null, [Validators.required]],
|
||||
loadName0: [null, [Validators.required]],
|
||||
loadPhone0: [null, [Validators.required]],
|
||||
loadPhone0: [null, [Validators.required, Validators.pattern('^[0-9]*$')]],
|
||||
unloadAddress0: [null, [Validators.required]],
|
||||
unloadName0: [null, [Validators.required]],
|
||||
unloadPhone0: [null, [Validators.required]]
|
||||
unloadPhone0: [null, [Validators.required, Validators.pattern('^[0-9]*$')]]
|
||||
});
|
||||
}
|
||||
@ViewChild('sf1', { static: false }) sf1!: SFComponent;
|
||||
@ -111,26 +111,26 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
if (!!q) {
|
||||
return this.service
|
||||
.request(this.service.$api_enterpriceList, { enterpriseName: q })
|
||||
.pipe(map((res) => (res as any[]).map((i) => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum))))
|
||||
.pipe(map(res => (res as any[]).map(i => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum))))
|
||||
.toPromise();
|
||||
} else {
|
||||
return of([]);
|
||||
}
|
||||
},
|
||||
change: (q: any) => {
|
||||
this.getRegionCode(q)
|
||||
this.getRegionCode(q);
|
||||
},
|
||||
visibleIf: {
|
||||
_$expand: (value: boolean) => value,
|
||||
},
|
||||
} as SFSelectWidgetSchema,
|
||||
_$expand: (value: boolean) => value
|
||||
}
|
||||
} as SFSelectWidgetSchema
|
||||
},
|
||||
enterpriseProjectId: {
|
||||
type: 'string',
|
||||
title: '项目',
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
placeholder: '请选择'
|
||||
} as SFSelectWidgetSchema
|
||||
},
|
||||
enterpriseInfoName: {
|
||||
@ -138,7 +138,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
title: '网络货运人',
|
||||
ui: {
|
||||
widget: 'text'
|
||||
},
|
||||
}
|
||||
},
|
||||
deadlineTime: {
|
||||
title: '截至日期',
|
||||
@ -176,7 +176,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
allowClear: true,
|
||||
change: (value: any, data: any) => {
|
||||
if (data.label) {
|
||||
const dat = data.label.split('/')
|
||||
const dat = data.label.split('/');
|
||||
this.sf1.setValue('/dispatchName', dat[0]);
|
||||
this.sf1.setValue('/dispatchPhone', dat[1]);
|
||||
}
|
||||
@ -186,7 +186,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
} as SFSelectWidgetSchema
|
||||
}
|
||||
},
|
||||
required: ['shipperAppUserId', 'enterpriseProjectId','enterpriseInfoId', 'deadlineTime', ]
|
||||
required: ['shipperAppUserId', 'enterpriseProjectId', 'enterpriseInfoId', 'deadlineTime']
|
||||
};
|
||||
this.ui1 = {
|
||||
'*': {
|
||||
@ -507,7 +507,12 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
};
|
||||
}
|
||||
changeValue() {
|
||||
this.totalFees = Number(this.sf7?.value?.appendFee) + Number(this.sf7?.value?.oilCardPay) + Number(this.sf7?.value?.prePay) + Number(this.sf7?.value?.receiptPay) + Number(this.sf7?.value?.toPay)
|
||||
this.totalFees =
|
||||
Number(this.sf7?.value?.appendFee) +
|
||||
Number(this.sf7?.value?.oilCardPay) +
|
||||
Number(this.sf7?.value?.prePay) +
|
||||
Number(this.sf7?.value?.receiptPay) +
|
||||
Number(this.sf7?.value?.toPay);
|
||||
}
|
||||
// 获取城市列表
|
||||
getRegionCode(regionCode: any) {
|
||||
@ -550,8 +555,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
}
|
||||
subStartInfo(event: any, index: number, id?: any) {
|
||||
if (id) {
|
||||
this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe((res) => {
|
||||
})
|
||||
this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe(res => {});
|
||||
}
|
||||
this.startInfo.splice(index, 1);
|
||||
this.validateForm1.removeControl(`loadAddress${index}`);
|
||||
@ -579,8 +583,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
}
|
||||
subEndInfo(event: any, index: number, id?: any) {
|
||||
if (id) {
|
||||
this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe((res) => {
|
||||
})
|
||||
this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe(res => {});
|
||||
}
|
||||
this.endInfo.splice(index, 1);
|
||||
this.validateForm1.removeControl(`unloadAddress${index}`);
|
||||
@ -596,7 +599,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
submitParams: item,
|
||||
submitUrl: this.service.$api_save_bulk_assign
|
||||
},
|
||||
nzWidth: 1300,
|
||||
nzWidth: 1300
|
||||
});
|
||||
modalRef.afterClose.subscribe(result => {
|
||||
if (result) {
|
||||
@ -614,8 +617,8 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
nzComponentParams: { type: 'bulk' }
|
||||
});
|
||||
}
|
||||
// 确认提交
|
||||
submit(submitType?: string): void {
|
||||
// 提交前确认,委托运输协议弹窗
|
||||
submitConfirm(submitType?: any) {
|
||||
// 校验规则
|
||||
Object.keys(this.validateForm1.controls).forEach(key => {
|
||||
this.validateForm1.controls[key].markAsDirty();
|
||||
@ -628,28 +631,46 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
if (this.validateForm1.invalid || !this.sf3.valid || !this.sf1.valid || !this.sf4.valid || !this.sf7.valid) {
|
||||
return;
|
||||
}
|
||||
if(typeof(this.validateForm1.value.modifyTime) !== 'string' ) {
|
||||
var c = new Date(this.validateForm1.value.modifyTime);
|
||||
this.validateForm1.value.modifyTime = c.getFullYear() + '-' + (c.getMonth() + 1) + '-' + c.getDate() + ' ' + c.getHours() + ':' + c.getMinutes() + ':' + c.getSeconds()
|
||||
|
||||
const modalRef = this.modalService.create({
|
||||
nzTitle: '运输协议',
|
||||
nzContent: TranAgreementComponent,
|
||||
nzWidth: 900,
|
||||
nzFooter: null
|
||||
});
|
||||
modalRef.afterClose.subscribe(result => {
|
||||
if (result) {
|
||||
this.submit(submitType);
|
||||
}
|
||||
if(typeof(this.validateForm1.value.createTime) !== 'string' ) {
|
||||
});
|
||||
}
|
||||
// 确认提交
|
||||
submit(submitType?: string): void {
|
||||
if (typeof this.validateForm1.value.modifyTime !== 'string') {
|
||||
var c = new Date(this.validateForm1.value.modifyTime);
|
||||
this.validateForm1.value.modifyTime =
|
||||
c.getFullYear() + '-' + (c.getMonth() + 1) + '-' + c.getDate() + ' ' + c.getHours() + ':' + c.getMinutes() + ':' + c.getSeconds();
|
||||
}
|
||||
if (typeof this.validateForm1.value.createTime !== 'string') {
|
||||
var c = new Date(this.validateForm1.value.createTime);
|
||||
this.validateForm1.value.createTime = c.getFullYear() + '-' + (c.getMonth() + 1) + '-' + c.getDate() + ' ' + c.getHours() + ':' + c.getMinutes() + ':' + c.getSeconds()
|
||||
this.validateForm1.value.createTime =
|
||||
c.getFullYear() + '-' + (c.getMonth() + 1) + '-' + c.getDate() + ' ' + c.getHours() + ':' + c.getMinutes() + ':' + c.getSeconds();
|
||||
}
|
||||
|
||||
const params: any = {
|
||||
...this.sf1.value,
|
||||
...this.sf7.value,
|
||||
unLoadingPlaceDTOList: [...this.startInfo, ...this.endInfo,],
|
||||
unLoadingPlaceDTOList: [...this.startInfo, ...this.endInfo],
|
||||
goodsInfoDTOList: [
|
||||
{
|
||||
...this.sf4.value, ...this.sf3.value,
|
||||
...this.sf4.value,
|
||||
...this.sf3.value,
|
||||
maxWeight: this.sf4.value.maxWeight.join(','),
|
||||
maxCube: this.sf4.value.maxCube.join(',')
|
||||
}
|
||||
]
|
||||
}
|
||||
params.freightPrice = this.totalFees
|
||||
};
|
||||
params.freightPrice = this.totalFees;
|
||||
if (submitType) {
|
||||
if (submitType == 'assign') {
|
||||
this.chooseFamifiar(params);
|
||||
@ -713,7 +734,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
this.sf7.setValue('/receiptAddressId', data.id);
|
||||
this.sf7.setValue('/receiptUserName', data.contactName);
|
||||
this.sf7.setValue('/phon', data.contactTelephone);
|
||||
this.sf7.setValue('/area', `${data.province}-${data.city}-${data.area}`)
|
||||
this.sf7.setValue('/area', `${data.province}-${data.city}-${data.area}`);
|
||||
this.sf7.setValue('/address', data.detailedAddress);
|
||||
}
|
||||
});
|
||||
@ -764,9 +785,9 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
}
|
||||
// 初始化信息
|
||||
initdata() {
|
||||
this.service.request(`${this.service.$api_get_getBulkDetail}`, {id:this.id}).subscribe((res) => {
|
||||
this.service.request(`${this.service.$api_get_getBulkDetail}`, { id: this.id }).subscribe(res => {
|
||||
this.dataR(res);
|
||||
})
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化信息
|
||||
@ -787,7 +808,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
if (res?.enterpriseProjectId) {
|
||||
this.enterpriseProjectIds = res.enterpriseProjectId
|
||||
this.enterpriseProjectIds = res.enterpriseProjectId;
|
||||
}
|
||||
this.sf1data = {
|
||||
dispatchPhone: res?.dispatchPhone,
|
||||
@ -797,8 +818,8 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
enterpriseInfoName: res?.enterpriseInfoName || '',
|
||||
externalResourceCode: res?.externalResourceCode || '',
|
||||
dispatchId: res?.dispatchId || '',
|
||||
deadlineTime: res?.deadlineTime || '',
|
||||
}
|
||||
deadlineTime: res?.deadlineTime || ''
|
||||
};
|
||||
if (this.PageStatus === '大宗修改') {
|
||||
this.sf1data.id = res?.id;
|
||||
}
|
||||
@ -817,7 +838,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
area: element.area,
|
||||
type: element.type,
|
||||
id: element.id
|
||||
})
|
||||
});
|
||||
} else {
|
||||
this.startInfo.push({
|
||||
detailedAddress: element.detailedAddress,
|
||||
@ -828,12 +849,12 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
province: element.province,
|
||||
city: element.city,
|
||||
area: element.area,
|
||||
type: element.type,
|
||||
})
|
||||
type: element.type
|
||||
});
|
||||
}
|
||||
if (element.createTime) {
|
||||
this.creatTime = element?.createTime
|
||||
this.modifyTime = element?.modifyTime
|
||||
this.creatTime = element?.createTime;
|
||||
this.modifyTime = element?.modifyTime;
|
||||
}
|
||||
this.validateForm1.addControl(`loadAddress${controlId}`, new FormControl(null, Validators.required));
|
||||
this.validateForm1.addControl(`loadName${controlId}`, new FormControl(null, Validators.required));
|
||||
@ -852,7 +873,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
area: element.area,
|
||||
type: element.type,
|
||||
id: element.id
|
||||
})
|
||||
});
|
||||
} else {
|
||||
this.endInfo.push({
|
||||
detailedAddress: element?.detailedAddress,
|
||||
@ -864,7 +885,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
city: element.city,
|
||||
area: element.area,
|
||||
type: element.type
|
||||
})
|
||||
});
|
||||
}
|
||||
this.validateForm1.addControl(`unloadAddress${controlId}`, new FormControl(null, Validators.required));
|
||||
this.validateForm1.addControl(`unloadName${controlId}`, new FormControl(null, Validators.required));
|
||||
@ -875,7 +896,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
goodsTypeId: res?.goodsInfoVOList[0]?.goodsTypeId || '',
|
||||
goodsTypeName: res?.goodsInfoVOList[0]?.goodsTypeName || '',
|
||||
goodsNameId: res?.goodsInfoVOList[0]?.goodsNameId || '',
|
||||
goodsName: res?.goodsInfoVOList[0]?.goodsName || '',
|
||||
goodsName: res?.goodsInfoVOList[0]?.goodsName || ''
|
||||
};
|
||||
if (this.sf3data.goodsTypeName === '其它') {
|
||||
this.sf3data.goodsName1 = res?.goodsInfoVOList[0]?.goodsName || '';
|
||||
@ -892,8 +913,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
|
||||
number: res?.goodsInfoVOList[0]?.number || '',
|
||||
maxWeight: res?.goodsInfoVOList[0]?.maxWeight?.split(',') || '',
|
||||
maxCube: res?.goodsInfoVOList[0]?.maxCube?.split(',') || ''
|
||||
|
||||
}
|
||||
};
|
||||
if (this.PageStatus === '大宗修改') {
|
||||
this.sf4data.id = res?.goodsInfoVOList[0]?.id;
|
||||
}
|
||||
|
||||
@ -17,7 +17,9 @@
|
||||
</nz-card>
|
||||
|
||||
<nz-card>
|
||||
<div class="card-title">装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km,预计行程耗时:{{ totalTime }}小时</span></div>
|
||||
<div class="card-title"
|
||||
>装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km,预计行程耗时:{{ totalTime }}小时</span></div
|
||||
>
|
||||
|
||||
<form #ngForm="ngForm" nz-form role="form">
|
||||
<div nz-row [nzGutter]="24">
|
||||
@ -28,24 +30,44 @@
|
||||
<nz-form-control [nzErrorTip]="'请输入装货地'">
|
||||
<div class="align-center">
|
||||
<nz-input-group [nzSuffix]="endInconTemp1">
|
||||
<input nz-input [(ngModel)]="data1.detailedAddress" (click)="openMap('start', idx)"
|
||||
name="startDetailedAddress{{ idx }}" placeholder="请输入装货地" required />
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data1.detailedAddress"
|
||||
(click)="openMap('start', idx)"
|
||||
name="startDetailedAddress{{ idx }}"
|
||||
placeholder="请输入装货地"
|
||||
required
|
||||
/>
|
||||
</nz-input-group>
|
||||
<span style="padding: 0 10px"><i nz-icon nzType="menu" nzTheme="outline" style="color: #1890ff"
|
||||
(click)="chooseAddress(idx, 'start')"></i></span>
|
||||
<span style="padding: 0 10px"
|
||||
><i nz-icon nzType="menu" nzTheme="outline" style="color: #1890ff" (click)="chooseAddress(idx, 'start')"></i
|
||||
></span>
|
||||
</div>
|
||||
</nz-form-control>
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input nz-input [(ngModel)]="data1.appUserName" name="startAppUserName{{ idx }}" maxlength="30"
|
||||
placeholder="请输入联系人姓名" required />
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data1.appUserName"
|
||||
name="startAppUserName{{ idx }}"
|
||||
maxlength="30"
|
||||
placeholder="请输入联系人姓名"
|
||||
required
|
||||
/>
|
||||
</nz-form-control>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人电话'">
|
||||
<input style="margin-left: 12px" nz-input [(ngModel)]="data1.contractTelephone" maxlength="11"
|
||||
name="startContractTelephone{{ idx }}" placeholder="请输入联系人电话" required/>
|
||||
<input
|
||||
style="margin-left: 12px"
|
||||
nz-input
|
||||
[(ngModel)]="data1.contractTelephone"
|
||||
maxlength="11"
|
||||
name="startContractTelephone{{ idx }}"
|
||||
placeholder="请输入联系人电话"
|
||||
required
|
||||
/>
|
||||
</nz-form-control>
|
||||
</div>
|
||||
</nz-form-item>
|
||||
@ -53,8 +75,7 @@
|
||||
</div>
|
||||
<div nz-col [nzSpan]="4">
|
||||
<div style="display: flex; justify-content: center">
|
||||
<span style="padding: 24 px; font-size: 30px; color: #7d7d7d"><i nz-icon nzType="swap"
|
||||
nzTheme="outline"></i></span>
|
||||
<span style="padding: 24 px; font-size: 30px; color: #7d7d7d"><i nz-icon nzType="swap" nzTheme="outline"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
<div nz-col [nzSpan]="10">
|
||||
@ -64,24 +85,44 @@
|
||||
<nz-form-control [nzErrorTip]="'请输入卸货地'">
|
||||
<div class="align-center">
|
||||
<nz-input-group [nzSuffix]="endInconTemp1">
|
||||
<input nz-input [(ngModel)]="data2.detailedAddress" (click)="openMap('end', idx)"
|
||||
name="endDetailedAddress{{ idx }}" placeholder="请输入卸货地" required/>
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data2.detailedAddress"
|
||||
(click)="openMap('end', idx)"
|
||||
name="endDetailedAddress{{ idx }}"
|
||||
placeholder="请输入卸货地"
|
||||
required
|
||||
/>
|
||||
</nz-input-group>
|
||||
<span style="padding: 0 10px"><i nz-icon nzType="menu" nzTheme="outline" style="color: #1890ff"
|
||||
(click)="chooseAddress(idx, 'end')"></i></span>
|
||||
<span style="padding: 0 10px"
|
||||
><i nz-icon nzType="menu" nzTheme="outline" style="color: #1890ff" (click)="chooseAddress(idx, 'end')"></i
|
||||
></span>
|
||||
</div>
|
||||
</nz-form-control>
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input nz-input [(ngModel)]="data2.appUserName" maxlength="30" name="endAppUserName{{ idx }}"
|
||||
placeholder="请输入联系人姓名" required/>
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data2.appUserName"
|
||||
maxlength="30"
|
||||
name="endAppUserName{{ idx }}"
|
||||
placeholder="请输入联系人姓名"
|
||||
required
|
||||
/>
|
||||
</nz-form-control>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人电话'">
|
||||
<input style="margin-left: 12px" nz-input [(ngModel)]="data2.contractTelephone"
|
||||
name="endUnloadPhone{{ idx }}" maxlength="11" placeholder="请输入联系人电话" required/>
|
||||
<input
|
||||
style="margin-left: 12px"
|
||||
nz-input
|
||||
[(ngModel)]="data2.contractTelephone"
|
||||
name="endUnloadPhone{{ idx }}"
|
||||
maxlength="11"
|
||||
placeholder="请输入联系人电话"
|
||||
required
|
||||
/>
|
||||
</nz-form-control>
|
||||
</div>
|
||||
</nz-form-item>
|
||||
@ -100,12 +141,20 @@
|
||||
<sf #sf4 [schema]="schema4" [button]="'none'" [ui]="ui4" [formData]="sf4data">
|
||||
<ng-template sf-template="freightPrice" let-i let-ui="ui">
|
||||
<nz-input-group [nzAddOnAfter]="addOnAfterTemplate">
|
||||
<input nz-input [ngModel]="i.value" (ngModelChange)="i.setValue($event)" placeholder="请输入" />
|
||||
<input
|
||||
nz-input
|
||||
type="number"
|
||||
min="0"
|
||||
step="0.01"
|
||||
[ngModel]="i.value"
|
||||
(ngModelChange)="i.setValue($event)"
|
||||
placeholder="请输入"
|
||||
oninput="if(value>99999)value=99999;if(value<0)value=0"
|
||||
/>
|
||||
</nz-input-group>
|
||||
<ng-template #addOnAfterTemplate>
|
||||
<nz-select [ngModel]="sf4.value.freightType" (ngModelChange)="sf4.setValue('/freightType', $event)">
|
||||
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of freightTypeOptions">
|
||||
</nz-option>
|
||||
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of freightTypeOptions"></nz-option>
|
||||
</nz-select>
|
||||
</ng-template>
|
||||
</ng-template>
|
||||
@ -116,8 +165,9 @@
|
||||
<nz-option nzLabel="抹除小数" nzValue="2"></nz-option>
|
||||
<nz-option nzLabel="抹除个数" nzValue="3"></nz-option>
|
||||
</nz-select>
|
||||
<span style="padding: 0 12px" nz-tooltip [nzTooltipTitle]="template2" nzTooltipPlacement="bottom"><i nz-icon
|
||||
nzType="exclamation-circle" nzTheme="outline" style="color: #1890ff"></i></span>
|
||||
<span style="padding: 0 12px" nz-tooltip [nzTooltipTitle]="template2" nzTooltipPlacement="bottom"
|
||||
><i nz-icon nzType="exclamation-circle" nzTheme="outline" style="color: #1890ff"></i
|
||||
></span>
|
||||
<ng-template #template2>
|
||||
<p>例如 付司机运费 = 重量*单价 = 999.99</p>
|
||||
<p>保留小数,即 999.99</p>
|
||||
@ -128,20 +178,41 @@
|
||||
</ng-template>
|
||||
<ng-template sf-template="weight" let-i let-ui="ui">
|
||||
<nz-input-group [nzAddOnAfter]="'吨'">
|
||||
<input nz-input type="number" [ngModel]="i.value" min="0" step="0.01" (ngModelChange)="i.setValue($event)"
|
||||
placeholder="总重量,必填" />
|
||||
<input
|
||||
nz-input
|
||||
type="number"
|
||||
[ngModel]="i.value"
|
||||
min="0"
|
||||
step="0.01"
|
||||
(ngModelChange)="i.setValue($event)"
|
||||
placeholder="总重量,必填"
|
||||
/>
|
||||
</nz-input-group>
|
||||
</ng-template>
|
||||
<ng-template sf-template="volume" let-i let-ui="ui">
|
||||
<nz-input-group [nzAddOnAfter]="'方'">
|
||||
<input nz-input type="number" [ngModel]="i.value" min="0" step="0.01" (ngModelChange)="i.setValue($event)"
|
||||
placeholder="总体积" />
|
||||
<input
|
||||
nz-input
|
||||
type="number"
|
||||
[ngModel]="i.value"
|
||||
min="0"
|
||||
step="0.01"
|
||||
(ngModelChange)="i.setValue($event)"
|
||||
placeholder="总体积"
|
||||
/>
|
||||
</nz-input-group>
|
||||
</ng-template>
|
||||
<ng-template sf-template="number" let-i let-ui="ui">
|
||||
<nz-input-group [nzAddOnAfter]="'车'">
|
||||
<input nz-input type="number" [ngModel]="i.value" min="0" step="0.01" (ngModelChange)="i.setValue($event)"
|
||||
placeholder="总车次" />
|
||||
<input
|
||||
nz-input
|
||||
type="number"
|
||||
[ngModel]="i.value"
|
||||
min="0"
|
||||
step="0.01"
|
||||
(ngModelChange)="i.setValue($event)"
|
||||
placeholder="总车次"
|
||||
/>
|
||||
</nz-input-group>
|
||||
</ng-template>
|
||||
</sf>
|
||||
@ -165,10 +236,16 @@
|
||||
</ng-template>
|
||||
<ng-template sf-template="paymentDays" let-i let-ui="ui">
|
||||
<div nz-row>
|
||||
<div class="align-center2" style="width: 350px;">
|
||||
<div class="align-center2" style="width: 350px">
|
||||
<div nz-col nzSpan="12">
|
||||
<nz-input-number [ngModel]="i.value" [nzMin]="1" [nzMax]="30" [nzStep]="1"
|
||||
(ngModelChange)="i.setValue($event)" nzPlaceHolder="请输入1-30"></nz-input-number>
|
||||
<nz-input-number
|
||||
[ngModel]="i.value"
|
||||
[nzMin]="1"
|
||||
[nzMax]="30"
|
||||
[nzStep]="1"
|
||||
(ngModelChange)="i.setValue($event)"
|
||||
nzPlaceHolder="请输入1-30"
|
||||
></nz-input-number>
|
||||
</div>
|
||||
<div>
|
||||
<span> 天内支付运费</span>
|
||||
@ -185,7 +262,7 @@
|
||||
<div class="align-center">
|
||||
<!-- <button nz-button nzType="primary" (click)="choose()">取消</button> -->
|
||||
<!-- <button nz-button nzType="primary" (click)="submit('assign')">生成二维码</button> -->
|
||||
<button nz-button nzType="primary" (click)="submit('assign')">指派熟车</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submit('publish')">司机抢单</button>
|
||||
<button nz-button nzType="primary" (click)="submitConfirm('assign')">指派熟车</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')">司机抢单</button>
|
||||
</div>
|
||||
</nz-card>
|
||||
@ -19,6 +19,7 @@ import { SupplyManagementService } from '../../services/supply-management.servic
|
||||
import { PublishGoodsChooseFamifiarComponent } from '../choose-famifiar/choose-famifiar.component';
|
||||
import { PublishAddressListComponent } from '../onecar-publish/address-list/address-list.component';
|
||||
import { PublishSuccessComponent } from '../onecar-publish/publish-success/publish-success.component';
|
||||
import { TranAgreementComponent } from '../tran-agreement/tran-agreement.component';
|
||||
@Component({
|
||||
selector: 'app-publish-goods-bulk-publish',
|
||||
templateUrl: './bulk-release-publish.component.html',
|
||||
@ -53,7 +54,9 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
private route: ActivatedRoute,
|
||||
private amapService: AmapService,
|
||||
public shipperSrv: ShipperBaseService
|
||||
) {}
|
||||
) {
|
||||
|
||||
}
|
||||
@ViewChild('sf1', { static: false }) sf1!: SFComponent;
|
||||
schema1: SFSchema = {};
|
||||
ui1!: SFUISchema;
|
||||
@ -114,6 +117,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
serverSearch: true,
|
||||
searchDebounceTime: 300,
|
||||
searchLoadingText: '搜索中...',
|
||||
allowClear: true,
|
||||
onSearch: (q: any) => {
|
||||
if (!!q) {
|
||||
return this.service
|
||||
@ -135,7 +139,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
ui: {
|
||||
widget: 'select',
|
||||
placeholder: '请选择',
|
||||
allowClear: true
|
||||
allowClear: true,
|
||||
} as SFSelectWidgetSchema
|
||||
},
|
||||
// enterpriseInfoName: {
|
||||
@ -161,6 +165,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
type: 'string',
|
||||
format: 'date-time',
|
||||
ui: {
|
||||
|
||||
placeholder: '请输入',
|
||||
format: 'yyyy-MM-dd HH:mm:ss'
|
||||
}
|
||||
@ -569,8 +574,9 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
nzComponentParams: { type: 'bulk' }
|
||||
});
|
||||
}
|
||||
// 确认提交(下单)
|
||||
submit(submitType: string): void {
|
||||
// 提交前确认,委托运输协议弹窗
|
||||
submitConfirm(submitType?: any) {
|
||||
// 校验规则
|
||||
Object.keys(this.ngForm.form.controls).forEach(key => {
|
||||
this.ngForm.form.controls[key].markAsDirty();
|
||||
this.ngForm.form.controls[key].updateValueAndValidity();
|
||||
@ -582,6 +588,21 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
|
||||
if (this.ngForm.form.invalid || !this.sf1.valid || !this.sf3.valid || !this.sf4.valid || !this.sf6.valid) {
|
||||
return;
|
||||
}
|
||||
|
||||
const modalRef = this.modalService.create({
|
||||
nzTitle: '运输协议',
|
||||
nzContent: TranAgreementComponent,
|
||||
nzWidth: 900,
|
||||
nzFooter: null
|
||||
});
|
||||
modalRef.afterClose.subscribe(result => {
|
||||
if (result) {
|
||||
this.submit(submitType);
|
||||
}
|
||||
});
|
||||
}
|
||||
// 确认提交(下单)
|
||||
submit(submitType: string): void {
|
||||
// //装卸货信息
|
||||
const LoadingList = this.startInfo.concat(this.endInfo);
|
||||
// 货物信息
|
||||
|
||||
@ -42,7 +42,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人信息'">
|
||||
<!-- <nz-form-control [nzErrorTip]="'请输入联系人信息'">
|
||||
<div class="align-center">
|
||||
<input nz-input [(ngModel)]="data.appUserName" formControlName="loadName{{ idx }}" maxlength="30" />
|
||||
<input
|
||||
@ -53,7 +53,30 @@
|
||||
maxlength="11"
|
||||
/>
|
||||
</div>
|
||||
</nz-form-control> -->
|
||||
<div style="display: flex">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data.appUserName"
|
||||
formControlName="loadName{{ idx }}"
|
||||
name="loadName{{ idx }}"
|
||||
maxlength="30"
|
||||
placeholder="请输入联系人姓名"
|
||||
/>
|
||||
</nz-form-control>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人电话'">
|
||||
<input
|
||||
style="margin-left: 12px"
|
||||
nz-input
|
||||
[(ngModel)]="data.contractTelephone"
|
||||
maxlength="11"
|
||||
formControlName="loadPhone{{ idx }}"
|
||||
name="loadPhone{{ idx }}"
|
||||
placeholder="请输入联系人电话"
|
||||
/>
|
||||
</nz-form-control>
|
||||
</div>
|
||||
</nz-form-item>
|
||||
</div>
|
||||
<button nz-button nzType="primary" (click)="addStartInfo($event)">
|
||||
@ -90,7 +113,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人信息'">
|
||||
<!-- <nz-form-control [nzErrorTip]="'请输入联系人信息'">
|
||||
<div class="align-center">
|
||||
<input nz-input [(ngModel)]="data.appUserName" formControlName="unloadName{{ idx }}" maxlength="30" />
|
||||
<input
|
||||
@ -101,7 +124,30 @@
|
||||
maxlength="11"
|
||||
/>
|
||||
</div>
|
||||
</nz-form-control> -->
|
||||
<div style="display: flex">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
[(ngModel)]="data.appUserName"
|
||||
maxlength="30"
|
||||
formControlName="unloadName{{ idx }}"
|
||||
name="unloadAddress{{ idx }}"
|
||||
placeholder="请输入联系人姓名"
|
||||
/>
|
||||
</nz-form-control>
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人电话'">
|
||||
<input
|
||||
style="margin-left: 12px"
|
||||
nz-input
|
||||
[(ngModel)]="data.contractTelephone"
|
||||
formControlName="unloadPhone{{ idx }}"
|
||||
name="unloadAddress{{ idx }}"
|
||||
maxlength="11"
|
||||
placeholder="请输入联系人电话"
|
||||
/>
|
||||
</nz-form-control>
|
||||
</div>
|
||||
</nz-form-item>
|
||||
</div>
|
||||
<button nz-button nzType="primary" (click)="addEndInfo($event)">
|
||||
@ -283,9 +329,9 @@
|
||||
<nz-card>
|
||||
<div class="align-center">
|
||||
<button nz-button nzType="primary" *ngIf="this.PageStatus == '整车修改'" (click)="goBack()">取消</button>
|
||||
<button *ngIf="this.PageStatus == '整车修改'" nz-button nzType="primary" style="margin-left: 48px" (click)="submit()">提交修改</button>
|
||||
<button *ngIf="this.PageStatus == '整车修改'" nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm()">提交修改</button>
|
||||
<button nz-button nzType="primary" *ngIf="this.PageStatus == '整车下一单'" (click)="submitConfirm('assign')">指派熟车</button>
|
||||
<button *ngIf="this.PageStatus == '整车下一单'" nz-button nzType="primary" style="margin-left: 48px" (click)="submit()"
|
||||
<button *ngIf="this.PageStatus == '整车下一单'" nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm()"
|
||||
>司机抢单</button
|
||||
>
|
||||
</div>
|
||||
|
||||
@ -57,6 +57,12 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
|
||||
public shipperSrv: ShipperBaseService
|
||||
) {
|
||||
this.validateForm1 = fb.group({
|
||||
loadAddress0: [null, [Validators.required]],
|
||||
loadName0: [null, [Validators.required]],
|
||||
loadPhone0: [null, [Validators.required,Validators.pattern('^[0-9]*$')]],
|
||||
unloadAddress0: [null, [Validators.required]],
|
||||
unloadName0: [null, [Validators.required]],
|
||||
unloadPhone0: [null, [Validators.required,Validators.pattern('^[0-9]*$')]],
|
||||
loadingTime: [null, []],
|
||||
unloadingTime: [null, []]
|
||||
});
|
||||
@ -738,6 +744,20 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
|
||||
}
|
||||
// 提交前确认,委托运输协议弹窗
|
||||
submitConfirm(submitType?: any) {
|
||||
Object.keys(this.validateForm1.controls).forEach(key => {
|
||||
this.validateForm1.controls[key].markAsDirty();
|
||||
this.validateForm1.controls[key].updateValueAndValidity();
|
||||
});
|
||||
this.sf1.validator({ emitError: true });
|
||||
this.sf3.validator({ emitError: true });
|
||||
this.sf4.validator({ emitError: true });
|
||||
this.sf6.validator({ emitError: true });
|
||||
this.sf7.validator({ emitError: true });
|
||||
console.log(this.sf1.valid);
|
||||
if (this.validateForm1.invalid || !this.sf3.valid || !this.sf1.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
|
||||
return;
|
||||
}
|
||||
|
||||
const modalRef = this.modalService.create({
|
||||
nzTitle: '运输协议',
|
||||
nzContent: TranAgreementComponent,
|
||||
@ -766,6 +786,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
|
||||
if (this.validateForm1.invalid || !this.sf3.valid || !this.sf1.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
|
||||
return;
|
||||
}
|
||||
console.log(this.validateForm1.value?.unloadingTime)
|
||||
if (typeof this.validateForm1.value.unloadingTime !== 'string') {
|
||||
var c = new Date(this.validateForm1.value.unloadingTime);
|
||||
this.validateForm1.value.unloadingTime =
|
||||
|
||||
@ -49,7 +49,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex;">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
@ -114,7 +114,7 @@
|
||||
</nz-form-item>
|
||||
<nz-form-item>
|
||||
<nz-form-label [nzSpan]="4" nzRequired>联系人</nz-form-label>
|
||||
<div class="align-center">
|
||||
<div style="display: flex;">
|
||||
<nz-form-control [nzErrorTip]="'请输入联系人姓名'">
|
||||
<input
|
||||
nz-input
|
||||
@ -310,17 +310,7 @@
|
||||
</nz-card>
|
||||
<nz-card>
|
||||
<div class="align-center">
|
||||
<button nz-button nzType="primary" (click)="submitConfirm('assign')" *ngIf="type === 'add'">指派熟车</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submit('publish')" *ngIf="type === 'add'">司机抢单</button>
|
||||
<button
|
||||
nz-button
|
||||
nzType="primary"
|
||||
style="margin-left: 48px"
|
||||
(click)="submit('publish')"
|
||||
*ngIf="type === 'edit'"
|
||||
[nzLoading]="service.http.loading"
|
||||
>保存</button
|
||||
>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="goBack()" *ngIf="type === 'edit'">取消</button>
|
||||
<button nz-button nzType="primary" (click)="submitConfirm('assign')" >指派熟车</button>
|
||||
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')" *ngIf="type === 'add'">司机抢单</button>
|
||||
</div>
|
||||
</nz-card>
|
||||
|
||||
@ -60,8 +60,14 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
|
||||
public shipperSrv: ShipperBaseService
|
||||
) {
|
||||
this.validateForm1 = fb.group({
|
||||
loadingTime: [null, [Validators.required]],
|
||||
unloadingTime: [null, [Validators.required]]
|
||||
loadAddress0: [null, [Validators.required]],
|
||||
loadName0: [null, [Validators.required]],
|
||||
loadPhone0: [null, [Validators.required,Validators.pattern('^[0-9]*$')]],
|
||||
unloadAddress0: [null, [Validators.required]],
|
||||
unloadName0: [null, [Validators.required]],
|
||||
unloadPhone0: [null, [Validators.required,Validators.pattern('^[0-9]*$')]],
|
||||
loadingTime: [null, []],
|
||||
unloadingTime: [null, []]
|
||||
});
|
||||
}
|
||||
|
||||
@ -684,6 +690,19 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
|
||||
}
|
||||
// 提交前确认,委托运输协议弹窗
|
||||
submitConfirm(submitType?: any) {
|
||||
Object.keys(this.validateForm1.controls).forEach(key => {
|
||||
this.validateForm1.controls[key].markAsDirty();
|
||||
this.validateForm1.controls[key].updateValueAndValidity();
|
||||
});
|
||||
this.sf1.validator({ emitError: true });
|
||||
this.sf3.validator({ emitError: true });
|
||||
this.sf4.validator({ emitError: true });
|
||||
this.sf6.validator({ emitError: true });
|
||||
this.sf7.validator({ emitError: true });
|
||||
if (this.validateForm1.invalid || !this.sf1.valid || !this.sf3.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
|
||||
return;
|
||||
}
|
||||
|
||||
const modalRef = this.modalService.create({
|
||||
nzTitle: '运输协议',
|
||||
nzContent: TranAgreementComponent,
|
||||
@ -698,19 +717,6 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
|
||||
}
|
||||
// 提交
|
||||
submit(submitType: string): void {
|
||||
Object.keys(this.validateForm1.controls).forEach(key => {
|
||||
this.validateForm1.controls[key].markAsDirty();
|
||||
this.validateForm1.controls[key].updateValueAndValidity();
|
||||
});
|
||||
this.sf1.validator({ emitError: true });
|
||||
this.sf3.validator({ emitError: true });
|
||||
this.sf4.validator({ emitError: true });
|
||||
this.sf6.validator({ emitError: true });
|
||||
this.sf7.validator({ emitError: true });
|
||||
if (this.validateForm1.invalid || !this.sf1.valid || !this.sf3.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
|
||||
return;
|
||||
}
|
||||
|
||||
//装卸货信息
|
||||
const LoadingList = this.startInfo.concat(this.endInfo);
|
||||
// 货物信息
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
<!--
|
||||
* @Author: your name
|
||||
* @Date: 2021-12-03 11:10:14
|
||||
* @LastEditTime: 2022-01-18 16:50:23
|
||||
* @LastEditors: Please set LastEditors
|
||||
* @LastEditTime : 2022-01-19 14:36:08
|
||||
* @LastEditors : Shiming
|
||||
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
* @FilePath: \tms-obc-web\src\app\routes\supply-management\components\vehicle\vehicle.component.html
|
||||
* @FilePath : \\tms-obc-web\\src\\app\\routes\\waybill-management\\components\\bulk\\bulk.component.html
|
||||
-->
|
||||
<!-- 搜索表单 -->
|
||||
<page-header-wrapper [title]="''">
|
||||
@ -43,7 +43,7 @@
|
||||
<nz-tab [nzTitle]="'运输中('+tabs?.cancelQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'待签收('+tabs?.signQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已完成('+tabs?.compolatelQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已取消'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已取消('+tabs?.deltQuantity+')'"></nz-tab>
|
||||
</nz-tabset>
|
||||
<div style="margin-top: 15px;">
|
||||
<st
|
||||
|
||||
@ -32,7 +32,8 @@ tabs = {
|
||||
cancelQuantity: 0,
|
||||
receivedQuantity: 0,
|
||||
totalQuantity: 0,
|
||||
compolatelQuantity: 0
|
||||
compolatelQuantity: 0,
|
||||
deltQuantity: 0
|
||||
};
|
||||
constructor(
|
||||
public service: WaybillManagementServe,
|
||||
@ -390,6 +391,14 @@ tabs = {
|
||||
this.isVisibleEvaluate = true
|
||||
}
|
||||
getGoodsSourceStatistical() {
|
||||
this.tabs = {
|
||||
signQuantity: 0,
|
||||
cancelQuantity: 0,
|
||||
receivedQuantity: 0,
|
||||
totalQuantity: 0,
|
||||
compolatelQuantity: 0,
|
||||
deltQuantity: 0
|
||||
};
|
||||
this.service.request(this.service.$api_get_getBulkStatistics, this.reqParams).subscribe(res => {
|
||||
if (res) {
|
||||
let totalCount = 0;
|
||||
@ -407,6 +416,9 @@ tabs = {
|
||||
case '5':
|
||||
this.tabs.compolatelQuantity = ele?.count;
|
||||
break;
|
||||
case '6':
|
||||
this.tabs.deltQuantity = ele?.count;
|
||||
break;
|
||||
}
|
||||
totalCount += ele.count
|
||||
});
|
||||
|
||||
@ -44,7 +44,7 @@
|
||||
<nz-tab [nzTitle]="'运输中('+tabs?.cancelQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'待签收('+tabs?.signQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已完成('+tabs?.compolatelQuantity+')'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已取消'"></nz-tab>
|
||||
<nz-tab [nzTitle]="'已取消('+tabs?.deltQuantity+')'"></nz-tab>
|
||||
</nz-tabset>
|
||||
<div style="margin-top: 15px;">
|
||||
<st #st [bordered]="true" [scroll]="{ x: '2000px' }" [data]="service.$api_get_wholePage" [columns]="columns"
|
||||
|
||||
@ -32,7 +32,8 @@ export class WaybillManagementVehicleComponent implements OnInit {
|
||||
receivedQuantity: 0,
|
||||
stayQuantity: 0,
|
||||
totalQuantity: 0,
|
||||
compolatelQuantity: 0
|
||||
compolatelQuantity: 0,
|
||||
deltQuantity: 0
|
||||
};
|
||||
constructor(
|
||||
public service: WaybillManagementServe,
|
||||
@ -378,6 +379,15 @@ export class WaybillManagementVehicleComponent implements OnInit {
|
||||
this.isVisibleEvaluate = true;
|
||||
}
|
||||
getGoodsSourceStatistical() {
|
||||
this.tabs = {
|
||||
signQuantity: 0,
|
||||
cancelQuantity: 0,
|
||||
receivedQuantity: 0,
|
||||
stayQuantity: 0,
|
||||
totalQuantity: 0,
|
||||
compolatelQuantity: 0,
|
||||
deltQuantity: 0
|
||||
};
|
||||
this.service.request(this.service.$api_get_getWholeStatistics, this.reqParams).subscribe(res => {
|
||||
if (res) {
|
||||
let totalCount = 0;
|
||||
@ -398,6 +408,9 @@ export class WaybillManagementVehicleComponent implements OnInit {
|
||||
case '5':
|
||||
this.tabs.compolatelQuantity = ele?.count;
|
||||
break;
|
||||
case '6':
|
||||
this.tabs.deltQuantity = ele?.count;
|
||||
break;
|
||||
}
|
||||
totalCount += ele.count
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user