车辆对接

This commit is contained in:
wangshiming
2022-01-13 13:53:47 +08:00
parent b8a8526d54
commit 948165710b
16 changed files with 207 additions and 138 deletions

View File

@ -1,7 +1,7 @@
/*
* @Author: your name
* @Date: 2021-12-07 19:42:53
* @LastEditTime: 2022-01-13 10:20:45
* @LastEditTime: 2022-01-13 11:05:48
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\proxy.conf.js
@ -24,7 +24,7 @@ module.exports = {
// }
'//api': {
target: {
host: 'tms-api-dev.eascs.com',
host: 'tms-api-test.eascs.com',
protocol: 'https:',
port: 443
},

View File

@ -1,7 +1,7 @@
<!--
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2022-01-13 10:01:50
* @LastEditTime: 2022-01-13 13:30:01
* @LastEditors: Please set LastEditors
* @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
@ -24,7 +24,7 @@
</div>
<div nz-col [nzSpan]="_$expand ? 24 : 6" [class.text-right]="_$expand">
<button nz-button nzType="primary" [nzLoading]="service.http.loading"
(click)="st?.load(1)">查询</button>
(click)="search()">查询</button>
<button nz-button nzType="primary" [disabled]="service.http.loading"
>导出</button>
<button nz-button [disabled]="service.http.loading" (click)="resetSF()">重置</button>
@ -40,7 +40,7 @@
<nz-card>
<nz-tabset (nzSelectedIndexChange)="selectChange($event)"
[nzTabBarExtraContent]="extraTemplate">
<nz-tab [nzTitle]="'全部'"></nz-tab>
<nz-tab [nzTitle]="'全部('+tabs?.totalCount+')'"></nz-tab>
<nz-tab [nzTitle]="'待接单('+tabs?.receivedQuantity+')'"></nz-tab>
<nz-tab [nzTitle]="'待发车('+tabs?.stayQuantity+')'"></nz-tab>
<nz-tab [nzTitle]="'运输中('+tabs?.GoingQuantity+')'"></nz-tab>

View File

@ -1,7 +1,13 @@
.left_btn {
width: 50px;
height: 32px;
padding-left: 8px;
line-height:32px;
background-color: #d7d7d7;
}
:host {
p{
margin-bottom: 0
}
.left_btn {
width: 50px;
height: 32px;
padding-left: 8px;
line-height:32px;
background-color: #d7d7d7;
}
}

View File

@ -62,7 +62,8 @@ tabs = {
stayQuantity: 0,
signQuantity: 0,
compolatelQuantity: 0,
GoingQuantity: 0
GoingQuantity: 0,
totalCount: 0
};
constructor(
public service: OrderManagementService,
@ -93,9 +94,14 @@ tabs = {
id: this.changeId
};
}
search() {
this.st?.load(1);
this.getGoodsSourceStatistical()
}
getGoodsSourceStatistical() {
this.service.request(this.service.$api_getBulkStatistical).subscribe(res => {
if (res) {
let totalCount = 0;
res.forEach((element: any) => {
if(element.billStatusLabel === '待发车') {
this.tabs.stayQuantity = element.quantity
@ -110,7 +116,9 @@ tabs = {
} else if (element.billStatusLabel === '运输中') {
this.tabs.GoingQuantity = element.quantity
}
totalCount += element.quantity
});
this.tabs.totalCount = totalCount
}
})
}
@ -120,6 +128,8 @@ tabs = {
this.initST();
setTimeout(() => {
this.st.load();
this.getGoodsSourceStatistical()
}, 500);
}
ngOnInit(): void {
@ -398,7 +408,7 @@ tabs = {
},
{
title: '运费明细',
width: '200px',
width: '250px',
className: 'text-center',
render: 'mybidDetailInfo',
},
@ -517,7 +527,7 @@ tabs = {
className: 'text-center',
index: 'applyUserName'
},
{ title: '状态', index: 'handleStatus', className: 'text-center' },
{ title: '状态', index: 'handleStatusLabel', className: 'text-center' },
{
title: '操作',
fixed: 'right',
@ -670,7 +680,12 @@ tabs = {
nzComponentParams: { data: { ...data, billId: item.id } },
});
modal.afterClose.subscribe(_ => this.st.reload(1));
modal.afterClose.subscribe(_ =>
{
this.st.reload(1);
this.getGoodsSourceStatistical();
}
);
}
});
}
@ -690,6 +705,7 @@ tabs = {
});
modalRef.afterClose.subscribe((result: any) => {
this.st.load(1);
this.getGoodsSourceStatistical()
});
}
userAction() {
@ -702,7 +718,7 @@ tabs = {
this.service.request(this.service.$api_get_batchSignBulkOrder, params).subscribe(res => {
if (res) {
this.st.load(1);
console.log(res);
this.getGoodsSourceStatistical()
} else {
this.service.msgSrv.error(res.msg);
}
@ -719,9 +735,11 @@ tabs = {
if (res === true) {
this.service.msgSrv.success('操作成功!');
this.st?.reload(1);
this.getGoodsSourceStatistical()
this.initST();
}
this.st?.reload(1);
this.getGoodsSourceStatistical()
}),
})
}
@ -735,6 +753,7 @@ tabs = {
this.service.msgSrv.success('撤销成功!')
this.stFloat.reload()
this.st?.reload(1);
this.getGoodsSourceStatistical()
} else {
this.service.msgSrv.error(res.msg)
}

View File

@ -1,7 +1,7 @@
<!--
* @Author: your name
* @Date: 2021-12-03 11:10:14
* @LastEditTime: 2022-01-13 10:03:16
* @LastEditTime: 2022-01-13 13:45:24
* @LastEditors: Please set LastEditors
* @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
@ -24,7 +24,7 @@
</div>
<div nz-col [nzSpan]="_$expand ? 24 : 6" class="text-right">
<button nz-button nzType="primary" [nzLoading]="service.http.loading"
(click)="st?.load(1)">查询</button>
(click)="search()">查询</button>
<button nz-button nzType="primary" [disabled]="service.http.loading"
>导出</button>
<button nz-button [disabled]="service.http.loading" (click)="resetSF()">重置</button>
@ -40,7 +40,7 @@
<nz-card>
<nz-tabset (nzSelectedIndexChange)="selectChange($event)"
[nzTabBarExtraContent]="extraTemplate">
<nz-tab [nzTitle]="'全部'"></nz-tab>
<nz-tab [nzTitle]="'全部('+tabs?.totalCount+')'"></nz-tab>
<nz-tab [nzTitle]="'待接单('+tabs?.receivedQuantity+')'"></nz-tab>
<nz-tab [nzTitle]="'待发车('+tabs?.stayQuantity+')'"></nz-tab>
<nz-tab [nzTitle]="'运输中('+tabs?.GoingQuantity+')'"></nz-tab>
@ -52,7 +52,8 @@
<st
#st
[bordered]="true"
[scroll]="{ x: '2000px' }"
multiSort
[scroll]="{ x: '1200px' }"
[data]="service.$api_get_listWholePage"
[columns]="columns"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
@ -74,20 +75,23 @@
<span>{{item?.goodsNumber ? item?.goodsNumber + '吨' : '' }}</span>
</div>
</ng-template>
<!-- 我的出价 -->
<ng-template st-row="mybidInfo" let-item let-index="index" class="temp_p">
<div *ngIf="item.mybidInfo?.length > 0">
<p *ngFor="let data of item?.mybidInfo"> {{ data?.expenseName }}:¥{{ data?.price | number:'0.2-2' }} </p>
<!-- 我的出价 -->
<ng-template st-row="mybidInfo" let-item let-index="index" class="temp_p">
<div *ngIf="item.mybidInfo.length > 0">
<p *ngFor="let data of item.mybidInfo"> {{ data.expenseName }}:¥{{ data.price | number:'0.2-2' }} </p>
</div>
</ng-template>
<ng-template st-row="mybidDetailInfo" let-item let-index="index">
<div *ngIf="item.mybidDetailInfo.length > 0">
<p *ngFor="let data of item.mybidDetailInfo">
{{ data.expenseName }}:¥{{ data.price | number:'0.2-2' }}
<span *ngIf="data.paymentStatus && data.paymentStatus === '1'" style="color: #f59a63">待申请</span>
<span *ngIf="data.paymentStatus && data.paymentStatus === '2'" style="color: #f59a63">已拒绝</span>
<span *ngIf="data.paymentStatus && data.paymentStatus === '3'" style="color: #f59a63">已支付</span>
<span *ngIf="data.paymentStatus && data.paymentStatus === '4'" style="color: #f59a63">申请中</span>
</p>
</div>
</ng-template>
<ng-template st-row="mybidDetailInfo" let-item let-index="index">
<div *ngIf="item.mybidDetailInfo?.length > 0">
<p *ngFor="let data of item.mybidDetailInfo">
{{ data.expenseName }}{{ data.price }}
<span style="color: #f59a63">{{ data.paymentStatusLabel }}</span>
</p>
</div>
</ng-template>
<ng-template st-row="billExpenseDetailVOList" let-item let-index="index">
<div *ngFor="let i of item?.billExpenseDetailVOList; let ii = index">
<span >{{i?.costName}}{{i?.price}}</span>

View File

@ -1,2 +1,5 @@
:host {
p{
margin-bottom: 0
}
}

View File

@ -63,7 +63,8 @@ tabs = {
stayQuantity: 0,
signQuantity: 0,
compolatelQuantity: 0,
GoingQuantity: 0
GoingQuantity: 0,
totalCount: 0
};
resourceStatus: any;
constructor(
@ -106,10 +107,14 @@ resourceStatus: any;
this.initSTFloat();
this.initSTFloatView();
}
search() {
this.st?.load(1);
this.getGoodsSourceStatistical()
}
getGoodsSourceStatistical() {
this.service.request(this.service.$api_statisticalStatus).subscribe(res => {
if (res) {
let totalCount = 0;
res.forEach((element: any) => {
if(element.billStatusLabel === '待发车') {
this.tabs.stayQuantity = element.quantity
@ -124,7 +129,9 @@ resourceStatus: any;
} else if (element.billStatusLabel === '已取消') {
this.tabs.cancelQuantity = element.quantity
}
totalCount += element.quantity
});
this.tabs.totalCount = totalCount
}
})
}
@ -347,36 +354,37 @@ resourceStatus: any;
{ title: '', type: 'checkbox', width: '50px', className: 'text-center' },
{
title: '订单号',
width: '100px',
width: '200px',
className: 'text-center',
render: 'billCode'
},
{
title: '我的出价',
width: '150px',
width: '200px',
className: 'text-center',
render: 'mybidInfo'
},
{
title: '运费明细',
width: '200px',
width: '250px',
className: 'text-center',
render: 'mybidDetailInfo',
},
{ title: '网络货运人', index: 'enterpriseInfoName', width: '120px', className: 'text-center' },
{ title: '货主', index: 'shipperAppUserName', width: '120px', className: 'text-center' },
{ title: '关联运单号', index: 'wayBillCode', width: '120px', className: 'text-center' },
{ title: '货源编号', index: 'resourceCode', width: '120px', className: 'text-center' },
{ title: '装货地', index: 'loadingAddressArr', width: '120px', className: 'text-center' },
{ title: '网络货运人', index: 'enterpriseInfoName', width: '170px', className: 'text-center' },
{ title: '货主', index: 'shipperAppUserName', width: '170px', className: 'text-center' },
{ title: '关联运单号', index: 'wayBillCode', width: '170px', className: 'text-center' },
{ title: '货源编号', index: 'resourceCode', width: '170px', className: 'text-center' },
{ title: '装货地', index: 'loadingAddressArr', width: '170px', className: 'text-center' },
{
title: '卸货地',
className: 'text-center',
width: '120px',
width: '170px',
index: 'unloadingAddressArr'
},
{
title: '货物信息',
className: 'text-center',
width: '120px',
width: '170px',
render: 'goodsName'
}, {
title: '承运司机',
@ -400,6 +408,7 @@ resourceStatus: any;
title: '创建时间',
className: 'text-center',
index: 'creationTime',
width: '170px',
},
{
title: '操作',
@ -464,7 +473,7 @@ resourceStatus: any;
className: 'text-center',
index: 'applyUserName'
},
{ title: '状态', index: 'handleStatus', className: 'text-center' },
{ title: '状态', index: 'handleStatusLabel', className: 'text-center' },
{
title: '操作',
fixed: 'right',

View File

@ -1,7 +1,7 @@
/*
* @Author: your name
* @Date: 2021-12-14 14:03:07
* @LastEditTime: 2021-12-24 17:58:45
* @LastEditTime: 2022-01-13 13:33:14
* @LastEditors: Please set LastEditors
* @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
@ -179,19 +179,23 @@ export class UpdateFreightComponent implements OnInit {
}
changeNumVal() {
if (this.calculateSub) {
this.calculateSub.unsubscribe();
console.log(this.sf.valid)
if(this.sf.valid) {
console.log(this.sf.valid)
}
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
});
}
});
// 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
// });
// }
// });
}
}

View File

@ -1,8 +1,8 @@
<!--
* @Author: your name
* @Date: 2021-12-15 13:17:42
* @LastEditTime: 2021-12-29 14:48:31
* @LastEditors: Please set LastEditors
* @LastEditTime: 2022-01-13 13:35:08
* @LastEditors: your name
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\order-management\modal\vehicle\update-freight\update-freight.component.html
-->

View File

@ -2,7 +2,7 @@ import { preloaderFinished } from '@delon/theme';
/*
* @Author: your name
* @Date: 2021-12-14 14:03:07
* @LastEditTime: 2021-12-21 14:56:26
* @LastEditTime: 2022-01-13 13:38:13
* @LastEditors: Please set LastEditors
* @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
@ -22,6 +22,7 @@ import { _HttpClient } from '@delon/theme';
import { NzMessageService } from 'ng-zorro-antd/message';
import { NzModalRef } from 'ng-zorro-antd/modal';
import { OrderManagementService } from '../../../services/order-management.service';
import { Subscription } from 'rxjs';
@Component({
selector: 'app-order-management-vehicle-update-freight',
@ -38,6 +39,8 @@ export class VehicleUpdateFreightComponent implements OnInit {
@Input()
data: any;
calculateSub!: Subscription;
constructor(private modal: NzModalRef, private msgSrv: NzMessageService, public service: OrderManagementService) {}
ngOnInit(): void {
@ -55,6 +58,7 @@ export class VehicleUpdateFreightComponent implements OnInit {
type: 'number',
title: '预付',
default: info.prePay?.price || 0,
minimum:0,
readOnly: info.prePay?.paymentStatus === '2' || info.prePay?.paymentStatus === '4',
ui: {
prefix: '¥',
@ -67,6 +71,7 @@ export class VehicleUpdateFreightComponent implements OnInit {
type: 'number',
title: '到付',
default: info.toPay?.price || 0,
minimum:0,
readOnly: info.toPay?.paymentStatus === '2' || info.toPay?.paymentStatus === '4',
ui: {
prefix: '¥',
@ -79,6 +84,7 @@ export class VehicleUpdateFreightComponent implements OnInit {
// type: 'number',
// title: '油卡',
// default: 0.0,
// minimum:0,
// readOnly: this.i.oilCardPayStatus === '1' || this.i.oilCardPayStatus === '3',
// ui: {
// prefix: '¥',
@ -91,6 +97,7 @@ export class VehicleUpdateFreightComponent implements OnInit {
type: 'number',
title: '回单付',
default: info.receiptPay?.price || 0,
minimum:0,
readOnly: info.receiptPay?.paymentStatus === '2' || info.receiptPay?.paymentStatus === '4',
ui: {
prefix: '¥',
@ -120,6 +127,39 @@ export class VehicleUpdateFreightComponent implements OnInit {
}
save(value: any): void {
this.service.request(this.service.$api_get_insertFreightChangeWhole, this.getParams()).subscribe(res => {
if (res) {
this.modal.destroy();
this.service.msgSrv.success('变更运费成功');
}
});
}
close(): void {
this.modal.destroy();
}
/**
* 更新数字框
*
*/
changeNumVal() {
if (this.calculateSub) {
this.calculateSub.unsubscribe();
}
this.calculateSub = this.service.request(this.service.$api_getWholeSurchargeDetail, this.getParams()).subscribe((res: any) => {
if (res) {
Object.assign(this.data, {
totalFreight: res.totalFreight,
freight: res.freight,
surcharge: res.surcharge
});
}
});
// this.tranPrice = this.sf.value.prePay + this.sf.value.toPay + this.sf.value.oilCardPay + this.sf.value.receiptPay;
// this.totalPrice = this.sf.value.prePay + this.sf.value.toPay + this.sf.value.oilCardPay + this.sf.value.receiptPay + this.otherPrice;
}
getParams() {
const editItems = this.data.list?.filter((info: any) => info.toPay?.paymentStatus !== '2' && info.toPay?.paymentStatus !== '4');
editItems.forEach((item: any) => {
switch (item.costName) {
@ -142,24 +182,6 @@ export class VehicleUpdateFreightComponent implements OnInit {
dtos: editItems,
changeCause: this.sf.value.changeCause
};
this.service.request(this.service.$api_get_insertFreightChangeWhole, params).subscribe((res: any) => {
if (res) {
this.modal.destroy();
this.service.msgSrv.success('变更运费成功');
}
});
}
close(): void {
this.modal.destroy();
}
/**
* 更新数字框
*
*/
changeNumVal() {
// this.tranPrice = this.sf.value.prePay + this.sf.value.toPay + this.sf.value.oilCardPay + this.sf.value.receiptPay;
// this.totalPrice = this.sf.value.prePay + this.sf.value.toPay + this.sf.value.oilCardPay + this.sf.value.receiptPay + this.otherPrice;
return params;
}
}

View File

@ -193,30 +193,30 @@ export class SupplyManagementBulkComponent implements OnInit {
{ title: '', type: 'checkbox', width: '50px', className: 'text-center' },
{
title: '货源编号',
width: '100px',
width: '200px',
className: 'text-center',
render: 'resourceCode'
},
{ title: '服务类型', index: 'serviceTypeLabel', width: '120px', className: 'text-center' },
{ title: '货主', index: 'shipperAppUserName', width: '120px', className: 'text-center' },
{ title: '项目名称', index: 'enterpriseProjectName', width: '120px', className: 'text-center' },
{ title: '关联订单', render: 'orderSn', width: '120px', className: 'text-center' },
{ title: '货物信息', render: 'goodsInfos', width: '180px', className: 'text-center' },
{ title: '服务类型', index: 'serviceTypeLabel', width: '150px', className: 'text-center' },
{ title: '货主', index: 'shipperAppUserName', width: '200px', className: 'text-center' },
{ title: '项目名称', index: 'enterpriseProjectName', width: '200px', className: 'text-center' },
{ title: '关联订单', render: 'orderSn', width: '200px', className: 'text-center' },
{ title: '货物信息', render: 'goodsInfos', width: '200px', className: 'text-center' },
{
title: '装货地',
className: 'text-center',
index: 'loadingAddressArr',
width: '120px',
width: '200px',
}, {
title: '卸货地',
className: 'text-center',
index: 'unloadingAddressArr',
width: '120px',
width: '200px',
},
{
title: '用车需求',
className: 'text-center',
width: '150px',
width: '200px',
render: 'useCarDemand'
},
{
@ -228,7 +228,7 @@ export class SupplyManagementBulkComponent implements OnInit {
{
title: '结算依据',
className: 'text-center',
width: '120px',
width: '200px',
index: 'settlementBasis',
},
{

View File

@ -6,8 +6,7 @@ import { ModalHelper, _HttpClient } from '@delon/theme';
import { NzModalService } from 'ng-zorro-antd/modal';
import { map } from 'rxjs/operators';
import { SupplyManagementService } from '../../services/supply-management.service';
import { SupplyManagementVehicleAssignedCarComponent,
} from '../assigned-car/assigned-car.component';
import { SupplyManagementVehicleAssignedCarComponent } from '../assigned-car/assigned-car.component';
import { SupplyManagementUpdateExternalSnComponent } from '../update-external-sn/update-external-sn.component';
import { SupplyManagementUpdateFreightComponent } from '../update-freight/update-freight.component';
import { of } from 'rxjs';
@ -38,12 +37,12 @@ export class SupplyManagementVehicleComponent implements OnInit {
};
resourceStatus: any;
constructor(
public service: SupplyManagementService,
private modal: NzModalService,
private router: Router,
public service: SupplyManagementService,
private modal: NzModalService,
private router: Router,
private ar: ActivatedRoute,
public shipperSrv: ShipperBaseService
) {}
) {}
/**
* 查询参数
@ -58,7 +57,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
a.resourceStatus = this.resourceStatus;
}
return {
...a,
...a
};
}
get selectedRows() {
@ -158,9 +157,9 @@ export class SupplyManagementVehicleComponent implements OnInit {
* 重新指派
*/
/**
* 重新指派
*/
assignedCar(item: any) {
* 重新指派
*/
assignedCar(item: any) {
const { id } = item;
const modalRef = this.modal.create({
nzTitle: '指派熟车',
@ -170,12 +169,11 @@ export class SupplyManagementVehicleComponent implements OnInit {
i: item,
status: 'anew',
params: { id },
url: this.service.$api_save_assign_vehicle,
url: this.service.$api_save_assign_vehicle
},
nzFooter: null,
nzFooter: null
});
modalRef.afterClose.subscribe((result) => {
modalRef.afterClose.subscribe(result => {
if (result) {
this.st.reload();
}
@ -222,7 +220,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
}
});
}
/**
/**
* 代发货源
*/
releaseGoods() {
@ -236,7 +234,7 @@ export class SupplyManagementVehicleComponent implements OnInit {
nzTitle: '<b>确定取消货源吗?</b>',
nzContent: `<b>取消后不可恢复,谨慎操作</b>`,
nzOnOk: () =>
this.service.request(this.service.$api_cancle_goods_source, {id: record.id}).subscribe(res => {
this.service.request(this.service.$api_cancle_goods_source, { id: record.id }).subscribe(res => {
if (res === true) {
this.service.msgSrv.success('操作成功!');
this.st?.reload();
@ -288,17 +286,17 @@ export class SupplyManagementVehicleComponent implements OnInit {
_$expand: (value: boolean) => value
},
onSearch: (q: any) => {
console.log(q)
console.log(q);
if (!!q) {
return this.service
.request(this.service.$api_enterpriceList, { enterpriseName: q})
.pipe(map((res: any) => (res as any[]).map((i) => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum))))
.request(this.service.$api_enterpriceList, { enterpriseName: q })
.pipe(map((res: any) => (res as any[]).map(i => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum))))
.toPromise();
} else {
return of([]);
}
},
} as SFSelectWidgetSchema,
}
} as SFSelectWidgetSchema
},
enterpriseProjectId: {
type: 'string',
@ -306,11 +304,10 @@ export class SupplyManagementVehicleComponent implements OnInit {
ui: {
widget: 'select',
visibleIf: {
_$expand: (value: boolean) => value,
_$expand: (value: boolean) => value
},
asyncData: () =>
this.shipperSrv.getEnterpriseProject()
} as SFSelectWidgetSchema,
asyncData: () => this.shipperSrv.getEnterpriseProject()
} as SFSelectWidgetSchema
},
serviceType: {
title: '服务类型',
@ -364,39 +361,40 @@ export class SupplyManagementVehicleComponent implements OnInit {
className: 'text-center',
render: 'resourceCode'
},
// {
// title: '服务类型',
// index: 'serviceType',
// width: '120px',
// className: 'text-center',
// type: 'enum',
// enum: { '1': '抢单', '2': '指派' }
// },
{ title: '货主', index: 'shipperAppUserName', width: '120px' },
{
title: '货主',
index: 'shipperAppUserName',
width: '180px',
className: 'text-center' },
{
title: '项目名称',
index: 'enterpriseProjectName',
width: '120px'
width: '180px',
className: 'text-center'
},
{
title: '装货地',
index: 'loadingAddressArr',
width: '200px'
width: '200px',
className: 'text-center'
},
{
title: '卸货地',
index: 'unloadingAddressArr',
width: '200px'
width: '200px',
className: 'text-center'
},
{
title: '货物名称',
index: 'goodsName',
width: '150px'
width: '150px',
className: 'text-center'
},
{
title: '货物数量',
width: '130px',
width: '200px',
index: 'goodsNumber',
className: 'text-center',
format: item => item.goodsNumber.join('/')
},
{

View File

@ -233,13 +233,15 @@ export class VehicleComponentsAuditDetailComponent implements OnInit {
return value;
}
viewEvaluate(item: any) {
this.modal.createStatic(VehicleImgViewComponent, { i: item } ).subscribe(() => {
this.modal.createStatic(VehicleImgViewComponent, { i: item } ).subscribe((i) => {
this.st.reload();
this.getDetailList()
});
}
updateEvaluate(item: any) {
this.modal.createStatic(VehicleComponentsListEditComponent, { i: item }).subscribe(() => {
this.modal.createStatic(VehicleComponentsListEditComponent, { i: item }).subscribe((i) => {
this.st.reload();
this.getDetailList()
});
}
}

View File

@ -200,6 +200,7 @@ export class VehicleComponentsListDetailComponent implements OnInit {
viewEvaluate(item: any) {
this.modal.createStatic(VehicleImgViewComponent, { i: item } ).subscribe(() => {
this.st.reload();
this.getDetailList();
});
}
/**
@ -208,6 +209,7 @@ export class VehicleComponentsListDetailComponent implements OnInit {
updateEvaluate(item: any) {
this.modal.createStatic(VehicleComponentsListEditComponent, { i: item }).subscribe(() => {
this.st.reload();
this.getDetailList();
});
}
handleOK() {

View File

@ -116,7 +116,7 @@ export class VehicleComponentsListEditComponent implements OnInit {
}
this.service.request(this.service.$api_get_upLoadCarProtocal, params).subscribe((res) => {
if(res) {
this.modal.destroy();
this.modal.destroy(true);
this.service.msgSrv.success('上传协议成功!')
} else {
this.service.msgSrv.error(res.msg)

View File

@ -1,7 +1,7 @@
/*
* @Author: your name
* @Date: 2021-12-07 17:30:18
* @LastEditTime: 2021-12-16 15:31:13
* @LastEditTime: 2022-01-13 11:27:12
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: \tms-obc-web\src\app\routes\vehicle\components\list\img-view\img-view.component.ts
@ -27,7 +27,7 @@ export class VehicleImgViewComponent implements OnInit {
}
cancel() {
this.modal.destroy();
this.modal.destroy(true);
}
// 驳回
reject() {
@ -37,7 +37,7 @@ export class VehicleImgViewComponent implements OnInit {
}
this.service.request(this.service.$api_get_auditCarProtocal_audit, params).subscribe((res) => {
if(res) {
this.modal.destroy();
this.modal.destroy(true);
this.service.msgSrv.success('已驳回')
} else {
this.service.msgSrv.error(res.msg)
@ -52,7 +52,7 @@ export class VehicleImgViewComponent implements OnInit {
}
this.service.request(this.service.$api_get_auditCarProtocal_audit, params).subscribe((res) => {
if(res) {
this.modal.destroy();
this.modal.destroy(true);
this.service.msgSrv.success('已通过')
} else {
this.service.msgSrv.error(res.msg)