This commit is contained in:
xiaoxing.liu
2022-04-13 19:07:10 +08:00
69 changed files with 1273 additions and 1038 deletions

View File

@ -1,3 +1,4 @@
<span class="mr-md">客服电话0755-88393483</span>
<!--Search--> <!--Search-->
<layout-pro-search class="hidden-xs"></layout-pro-search> <layout-pro-search class="hidden-xs"></layout-pro-search>
<!--Link--> <!--Link-->

View File

@ -33,37 +33,37 @@ export class ContractManagementFrameComponent implements OnInit {
private router: Router, private router: Router,
public shipperservice: ShipperBaseService, public shipperservice: ShipperBaseService,
private datePipe: DatePipe, private datePipe: DatePipe,
) {} ) { }
ngOnInit(): void { ngOnInit(): void {
this.initST(); this.initST();
this.initSF(); this.initSF();
} }
/** /**
* 查询参数 * 查询参数
*/ */
get reqParams() { get reqParams() {
const params = { const params = {
...this.sf?.value, ...this.sf?.value,
}
delete params.signTime;
delete params._$expand;
if(this.datePipe.transform(this.sf?.value?.signTime?.[0], 'yyyy-MM-dd HH:mm:ss') && this.datePipe.transform(this.sf?.value?.signTime?.[1], 'yyyy-MM-dd HH:mm:ss')) {
params.signTime = {
start: this.datePipe.transform(this.sf?.value?.signTime?.[0], 'yyyy-MM-dd HH:mm:ss'),
end: this.datePipe.transform(this.sf?.value?.signTime?.[1], 'yyyy-MM-dd HH:mm:ss'),
}
}
if(this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[0], 'yyyy-MM-dd HH:mm:ss') && this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[1], 'yyyy-MM-dd HH:mm:ss')) {
params.effectiveEndTime = {
start: this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[0], 'yyyy-MM-dd HH:mm:ss'),
end: this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[1], 'yyyy-MM-dd HH:mm:ss'),
}
}
return {
...params
};
} }
delete params.signTime;
delete params._$expand;
if (this.datePipe.transform(this.sf?.value?.signTime?.[0], 'yyyy-MM-dd HH:mm:ss') && this.datePipe.transform(this.sf?.value?.signTime?.[1], 'yyyy-MM-dd HH:mm:ss')) {
params.signTime = {
start: this.datePipe.transform(this.sf?.value?.signTime?.[0], 'yyyy-MM-dd HH:mm:ss'),
end: this.datePipe.transform(this.sf?.value?.signTime?.[1], 'yyyy-MM-dd HH:mm:ss'),
}
}
if (this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[0], 'yyyy-MM-dd HH:mm:ss') && this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[1], 'yyyy-MM-dd HH:mm:ss')) {
params.effectiveEndTime = {
start: this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[0], 'yyyy-MM-dd HH:mm:ss'),
end: this.datePipe.transform(this.sf?.value?.effectiveEndTime?.[1], 'yyyy-MM-dd HH:mm:ss'),
}
}
return {
...params
};
}
/** /**
* 初始化数据列表 * 初始化数据列表
*/ */
@ -91,7 +91,7 @@ export class ContractManagementFrameComponent implements OnInit {
title: '合同名称', title: '合同名称',
width: '100px', width: '100px',
className: 'text-center', className: 'text-center',
index: 'templateName' index: 'contractName'
}, },
{ title: '网络货运人', index: 'enterpriseInfoName', width: '120px', className: 'text-center' }, { title: '网络货运人', index: 'enterpriseInfoName', width: '120px', className: 'text-center' },
{ title: '合同对象', index: 'contractObjectName', width: '120px', className: 'text-center' }, { title: '合同对象', index: 'contractObjectName', width: '120px', className: 'text-center' },
@ -157,7 +157,7 @@ export class ContractManagementFrameComponent implements OnInit {
widget: 'dict-select', widget: 'dict-select',
containsAllLable: true, containsAllLable: true,
params: { dictKey: 'contract:type' }, params: { dictKey: 'contract:type' },
containAllLable:true, containAllLable: true,
} as SFSelectWidgetSchema, } as SFSelectWidgetSchema,
}, },
enterpriseInfoId: { enterpriseInfoId: {
@ -210,7 +210,7 @@ export class ContractManagementFrameComponent implements OnInit {
widget: 'dict-select', widget: 'dict-select',
containsAllLable: true, containsAllLable: true,
params: { dictKey: 'esign:flow:status' }, params: { dictKey: 'esign:flow:status' },
containAllLable:true, containAllLable: true,
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value, _$expand: (value: boolean) => value,
}, },
@ -238,9 +238,9 @@ export class ContractManagementFrameComponent implements OnInit {
} }
} }
approval(): void {} approval(): void { }
add(): void {} add(): void { }
routeTo(item: any) { routeTo(item: any) {
this.router.navigate(['/ticket/invoice-requested-detail/1']); this.router.navigate(['/ticket/invoice-requested-detail/1']);

View File

@ -30,7 +30,7 @@
</div> </div>
<div nz-col [nzSpan]="_$expand ? 24 : 6" [class.text-right]="_$expand"> <div nz-col [nzSpan]="_$expand ? 24 : 6" [class.text-right]="_$expand">
<button nz-button nzType="primary" [disabled]="!sf.valid" [nzLoading]="isLoading && st.loading" <button nz-button nzType="primary" [disabled]="!sf.valid" [nzLoading]="isLoading && st.loading"
(click)="st?.load(1)" acl [acl-ability]="['CONTRACT-INDEX-searchDetail']">查询</button> (click)="st?.load(1)" acl [acl-ability]="['CONTRACT-INDEX-searchDetail']">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
<button nz-button nzType="link" (click)="expandToggle()"> <button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }} {{ !_$expand ? '展开' : '收起' }}
@ -48,14 +48,15 @@
</nz-alert> </nz-alert>
</div> </div>
<st #st [data]="service.$api_listDetailed_page" [columns]="columns" [req]="{ params: reqParams }" <st #st [data]="service.$api_listDetailed_page" [columns]="columns" [req]="{ params: reqParams }" [loading]="false"
[loading]="false" [scroll]="{ x: '1200px', y: '370px' }" (change)="stChange($event)"> [scroll]="{ x: '1200px', y: '370px' }" (change)="stChange($event)">
<ng-template st-row="contractCode" let-item let-index="index"> <ng-template st-row="contractCode" let-item let-index="index">
<a [routerLink]="'/contract-management/index/detail/' + item.id">{{ item?.contractCode }}</a> <a (click)="service.openURL(item?.contractFilePath)">{{ item?.contractCode }}</a>
<!-- <a [routerLink]="'/contract-management/index/detail/' + item.id">{{ item?.contractCode }}</a> -->
</ng-template> </ng-template>
<ng-template st-row="signingObject" let-item let-index="index"> <ng-template st-row="signingObject" let-item let-index="index">
<span *ngIf="item.signingObject == 0"></span> <span *ngIf="item.signingObject == 0"></span>
<span></span> <span></span>
</ng-template> </ng-template>
</st> </st>
</nz-card> </nz-card>

View File

@ -75,7 +75,8 @@
[loading]="false" [loading]="false"
> >
<ng-template st-row="templateName" let-item let-index="index"> <ng-template st-row="templateName" let-item let-index="index">
<a (click)="view(item)">{{ item.templateName }}</a> <a (click)="service.openURL(item?.contractFilePath)">{{ item.templateName }}</a>
<!-- <a (click)="view(item)">{{ item.templateName }}</a> -->
</ng-template> </ng-template>
<ng-template st-row="signingObject" let-item let-index="index"> <ng-template st-row="signingObject" let-item let-index="index">
<span *ngIf="item?.signingObject == 1">货主</span> <span *ngIf="item?.signingObject == 1">货主</span>

View File

@ -75,7 +75,8 @@
[loading]="false" [loading]="false"
> >
<ng-template st-row="templateName" let-item let-index="index"> <ng-template st-row="templateName" let-item let-index="index">
<a (click)="view(item)">{{ item.templateName }}</a> <a (click)="service.openURL(item?.contractFilePath)">{{ item.templateName }}</a>
<!-- <a (click)="view(item)">{{ item.templateName }}</a> -->
</ng-template> </ng-template>
</st> </st>
</div> </div>

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-04-07 17:57:23 * @Date : 2022-04-07 17:57:23
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-07 19:28:24 * @LastEditTime : 2022-04-13 10:22:35
* @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\curve\\curve.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\curve\\curve.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -75,7 +75,7 @@ export class DatatableCustomindexCurveMinComponent implements OnInit,OnChanges {
this.chart = new Chart({ this.chart = new Chart({
container: el, container: el,
autoFit: true, autoFit: true,
height: 200, height: 320,
}); });
let value: any = [] let value: any = []
this.service.request(this.service.$api_getTradingTrend).subscribe((res: any) => { this.service.request(this.service.$api_getTradingTrend).subscribe((res: any) => {

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-04-06 10:57:56 * @Date : 2022-04-06 10:57:56
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-07 19:51:32 * @LastEditTime : 2022-04-13 15:20:32
* @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\datascreen.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\datascreen.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -23,7 +23,7 @@
</div> </div>
<div nz-row [nzGutter]="24"> <div nz-row [nzGutter]="24">
<div nz-col class="gutter-row" [nzSpan]="8"> <div nz-col class="gutter-row" nzXs="12" nzSm="12" nzMd="12" nzLg="12" nzXl="8" nzXXl="8">
<nz-card nzTitle="2022全年交易情况"> <nz-card nzTitle="2022全年交易情况">
<nz-row [nzGutter]="16"> <nz-row [nzGutter]="16">
<nz-col [nzSpan]="12"> <nz-col [nzSpan]="12">
@ -47,11 +47,11 @@
</nz-card> </nz-card>
<nz-card nzTitle="实时货源"> <nz-card nzTitle="实时货源">
<st <st
[scroll]="{ y: '300px' }"
#st #st
multiSort multiSort
bordered bordered
[columns]="columns" [columns]="columns"
[scroll]="{ y: '320px' }"
[data]="service.$api_getRealTimeSupply" [data]="service.$api_getRealTimeSupply"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data' } }" [res]="{ reName: { list: 'data' } }"
@ -59,7 +59,7 @@
[loading]="service.http.loading" [loading]="service.http.loading"
> >
<ng-template st-row="index" let-item let-index="index"> <ng-template st-row="index" let-item let-index="index">
{{ index }} {{ index + 1 }}
</ng-template> </ng-template>
<ng-template st-row="weight" let-item let-index="index"> <ng-template st-row="weight" let-item let-index="index">
{{ item.weight ? item.weight + '吨' : '' }} {{ item.weight ? item.weight + '吨' : '' }}
@ -72,7 +72,7 @@
</st> </st>
</nz-card> </nz-card>
</div> </div>
<div nz-col class="gutter-row" [nzSpan]="8"> <div nz-col class="gutter-row" nzXs="12" nzSm="12" nzMd="12" nzLg="12" nzXl="8" nzXXl="8">
<nz-card> <nz-card>
<nz-row [nzGutter]="24"> <nz-row [nzGutter]="24">
<nz-col [nzSpan]="8"> <nz-col [nzSpan]="8">
@ -86,14 +86,14 @@
</nz-col> </nz-col>
</nz-row> </nz-row>
</nz-card> </nz-card>
<app-datatable-customindex-map style="max-height: 600px" #map [chartData]="chartData"></app-datatable-customindex-map> <app-datatable-customindex-map style="max-height: 680px" #map [chartData]="chartData"></app-datatable-customindex-map>
<nz-card> <nz-card>
<nz-row [nzGutter]="24"> <nz-row [nzGutter]="24">
<g2-bar #bar height="200" [delay]='500' repaint='true' [title]="'本月发货量排名'" [data]="salesData2" (ready)='genData()'></g2-bar> <g2-bar #bar height="310" [delay]='500' repaint='true' [title]="'本月发货量排名'" [data]="salesData2" (ready)='genData()'></g2-bar>
</nz-row> </nz-row>
</nz-card> </nz-card>
</div> </div>
<div nz-col class="gutter-row" [nzSpan]="8"> <div nz-col class="gutter-row" nzXs="12" nzSm="12" nzMd="12" nzLg="12" nzXl="8" nzXXl="8">
<nz-card> <nz-card>
<nz-row [nzGutter]="24"> <nz-row [nzGutter]="24">
<nz-col [nzSpan]="6"> <nz-col [nzSpan]="6">
@ -157,7 +157,7 @@
#st #st
multiSort multiSort
bordered bordered
[scroll]="{y: '300px'}" [scroll]="{y: '290px'}"
[columns]="orderColumns" [columns]="orderColumns"
[data]="service.$api_getRealTimeWaybillRiskControl" [data]="service.$api_getRealTimeWaybillRiskControl"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqOrderParams }" [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqOrderParams }"

View File

@ -5,7 +5,7 @@ import { map } from 'rxjs/operators';
* @Author : Shiming * @Author : Shiming
* @Date : 2022-04-06 10:57:56 * @Date : 2022-04-06 10:57:56
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-07 19:48:19 * @LastEditTime : 2022-04-13 10:25:50
* @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\datascreen.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\datascreen.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -127,7 +127,7 @@ export class DatatableDatascreenComponent implements OnInit {
*/ */
initST() { initST() {
this.columns = [ this.columns = [
{ title: '序号', render: 'index', className: 'text-center', width: '70px' }, { title: '序号', render: 'index', className: 'text-center', width: '70px', },
{ title: '发货地', index: 'loadAddress', className: 'text-center', width: '90px' }, { title: '发货地', index: 'loadAddress', className: 'text-center', width: '90px' },
{ title: '卸货地', index: 'dischargeAddress', className: 'text-center', width: '90px' }, { title: '卸货地', index: 'dischargeAddress', className: 'text-center', width: '90px' },
{ title: '货物', index: 'goodsName', className: 'text-center', width: '90px' }, { title: '货物', index: 'goodsName', className: 'text-center', width: '90px' },
@ -138,7 +138,7 @@ export class DatatableDatascreenComponent implements OnInit {
this.orderColumns = [ this.orderColumns = [
{ title: '运单号', index: 'wayCode', className: 'text-center', width: '150px' }, { title: '运单号', index: 'wayCode', className: 'text-center', width: '150px' },
{ title: '司机/车辆', index: 'carNo', className: 'text-center', width: '120px' }, { title: '司机/车辆', index: 'carNo', className: 'text-center', width: '120px' },
{ title: '货主', index: 'shipperName', className: 'text-center', width: '70px' }, { title: '货主', index: 'shipperName', className: 'text-center', width: '200px' },
{ title: '时间', index: 'createTime', className: 'text-center', width: '200px' }, { title: '时间', index: 'createTime', className: 'text-center', width: '200px' },
{ title: '异常预警', index: 'warningTypeLabel', className: 'text-center', width: '120px' } { title: '异常预警', index: 'warningTypeLabel', className: 'text-center', width: '120px' }
]; ];

View File

@ -4,8 +4,9 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-04-06 17:57:07 * @Date : 2022-04-06 17:57:07
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-07 19:44:32 * @LastEditTime : 2022-04-13 15:20:33
* @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\map\\map.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\datatable\\components\\datascreen\\map\\map.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
<g2-custom delay="200" (render)="render($event)" ></g2-custom> <g2-custom #map div style="height: 680px; " delay="200" (render)="render($event)" ></g2-custom>
<!-- <nz-col nzXs="0" nzSm="0" nzMd="0" nzLg="14" nzXl="14" nzXXl="14" style="z-index: 9999;"></nz-col> -->

View File

@ -1,4 +1,4 @@
import { Component, ElementRef, Input, NgZone, OnChanges, OnInit, SimpleChanges, ViewChild } from '@angular/core'; import { Component, ElementRef, Input, NgZone, OnChanges, OnInit, SimpleChanges, ViewChild, AfterViewInit } from '@angular/core';
import { Chart } from '@antv/g2'; import { Chart } from '@antv/g2';
import DataSet from '@antv/data-set'; import DataSet from '@antv/data-set';
import { DataService } from 'src/app/routes/datatable/services/data.service'; import { DataService } from 'src/app/routes/datatable/services/data.service';
@ -7,9 +7,11 @@ import { DataService } from 'src/app/routes/datatable/services/data.service';
templateUrl: './map.component.html', templateUrl: './map.component.html',
styleUrls: ['./map.component.less'] styleUrls: ['./map.component.less']
}) })
export class DatatableCustomindexMapComponent implements OnInit, OnChanges { export class DatatableCustomindexMapComponent implements OnInit, OnChanges, AfterViewInit {
el: any; el: any;
@Input() chartData: any; @Input() chartData: any;
@ViewChild('auditModal', { static: false }) auditModal!: any;
@ViewChild('map',{static: false}) map!: any;
chart: any; chart: any;
mapData: any; mapData: any;
ds!: DataSet ; ds!: DataSet ;
@ -18,6 +20,10 @@ export class DatatableCustomindexMapComponent implements OnInit, OnChanges {
userDv: any; userDv: any;
userData: any = []; userData: any = [];
constructor(private service: DataService, private ngZone: NgZone) {} constructor(private service: DataService, private ngZone: NgZone) {}
ngAfterViewInit(): void {
this.map.el.nativeElement.style.height = this.map.el.nativeElement.clientWidth + 'px'
this.chart.render();
}
ngOnChanges(changes: SimpleChanges): void { ngOnChanges(changes: SimpleChanges): void {
if (this.chartData) { if (this.chartData) {
@ -26,7 +32,7 @@ export class DatatableCustomindexMapComponent implements OnInit, OnChanges {
// }, 1000) // }, 1000)
} }
} }
ngOnInit(): void {} ngOnInit(): void {}
reRender() { reRender() {
console.log('5454545'); console.log('5454545');
@ -49,7 +55,6 @@ export class DatatableCustomindexMapComponent implements OnInit, OnChanges {
this.chart = new Chart({ this.chart = new Chart({
container: el, container: el,
autoFit: true, autoFit: true,
height: 680,
padding: [0, 0] padding: [0, 0]
}); });
this.chart.tooltip({ this.chart.tooltip({
@ -85,18 +90,6 @@ export class DatatableCustomindexMapComponent implements OnInit, OnChanges {
stroke: '#ccc', stroke: '#ccc',
lineWidth: 1 lineWidth: 1
}); });
// 可视化用户数据
// this.userData = [
// { name: '山东', value: 21 },
// { name: '山东', value: 22},
// { name: '广东', value: 20, },
// { name: '广东', value: 20 },
// { name: '四川', value: 120 },
// { name: '湖南', value: 200 },
// { name: '河北', value: 30 },
// ];
let value: any = [] let value: any = []
this.service.request(this.service.$api_getTransactionDistribution).subscribe((res: any) => { this.service.request(this.service.$api_getTransactionDistribution).subscribe((res: any) => {
if(res) { if(res) {
@ -108,6 +101,10 @@ export class DatatableCustomindexMapComponent implements OnInit, OnChanges {
}); });
console.log(value); console.log(value);
this.userData = value this.userData = value
if (!(this.userData instanceof Array) || this.userData.length === 0) {
return;
}
this.userDv = this.ds.createView().source(this.userData).transform({ this.userDv = this.ds.createView().source(this.userData).transform({
geoDataView: this.worldMap, geoDataView: this.worldMap,
field: 'name', field: 'name',

View File

@ -34,13 +34,13 @@
</ng-template> </ng-template>
<ng-template st-row="verifyStatus" let-item> <ng-template st-row="verifyStatus" let-item>
<a (click)="viewResult(item)" *ngIf="item?.verifyStatus === '2'">{{item?.verifyStatusLabel}}</a> <a (click)="viewResult(item)" *ngIf="item?.verifyStatus === '2'">{{item?.verifyStatusLabel}}</a>
<span *ngIf="item?.verifyStatus === '1'">{{item?.verifyStatusLabel}}</span> <span *ngIf="item?.verifyStatus !== '2'">{{item?.verifyStatusLabel}}</span>
</ng-template> </ng-template>
<ng-template st-row="orderCode" let-item> <ng-template st-row="orderCode" let-item>
<span class="text-blue-dark">{{item?.orderCode}}</span> <a (click)="routeToOrder(item)">{{item?.orderCode}}</a>
</ng-template> </ng-template>
<ng-template st-row="wayBillCode" let-item> <ng-template st-row="wayBillCode" let-item>
<span class="text-blue-dark">{{item?.wayBillCode}}</span> <a (click)="routeTowaybill(item)">{{item?.wayBillCode}}</a>
</ng-template> </ng-template>
<ng-template st-row="tolalAmount" let-item let-index="index"> <ng-template st-row="tolalAmount" let-item let-index="index">
<div class="text-right">{{item?.tolalAmount | currency }}</div> <div class="text-right">{{item?.tolalAmount | currency }}</div>

View File

@ -163,9 +163,9 @@ export class DatatableFundReportingComponent implements OnInit {
title: '本地校验', title: '本地校验',
type: 'string', type: 'string',
enum: [ enum: [
{ label: '校验中', value: 0 }, { label: '检测中', value: '0' },
{ label: '通过', value: 1 }, { label: '通过', value: '1' },
{ label: '不通过', value: 2 } { label: '不通过', value: '2' }
], ],
ui: { ui: {
placeholder: '请选择', placeholder: '请选择',
@ -465,6 +465,23 @@ export class DatatableFundReportingComponent implements OnInit {
} }
} }
routeToOrder(item: any) {
if (item.orderType === '1') {
window.open(location.origin + `/#/order-management/vehicle/vehicle-detail/${item.orderId}`);
} else {
window.open(location.origin + `/#/order-management/bulk/bulk-detail/${item.orderId}`);
}
}
routeTowaybill(item: any) {
if (item.orderType === '1') {
window.open(location.origin + `/#/waybill-management/vehicle/vehicle-detail/${item.wayBillId}`);
} else {
window.open(location.origin + `/#/waybill-management/bulk/bulk-detail/${item.wayBillId}`);
}
}
} }

View File

@ -49,10 +49,10 @@
</ng-template> </ng-template>
<ng-template st-row="billCode" let-item> <ng-template st-row="billCode" let-item>
<span class="text-red-dark">{{item?.billCode}}</span> <a class="text-red-dark" (click)="routeToOrder(item)">{{item?.billCode}}</a>
</ng-template> </ng-template>
<ng-template st-row="wayBillCode" let-item> <ng-template st-row="wayBillCode" let-item>
<span class="text-red-dark">{{item?.wayBillCode}}</span> <a class="text-red-dark" (click)="routeTowaybill(item)">{{item?.wayBillCode}}</a>
</ng-template> </ng-template>
<ng-template st-row="freightAmount" let-item let-index="index"> <ng-template st-row="freightAmount" let-item let-index="index">

View File

@ -23,13 +23,13 @@ export class DatatableOrderReportingComponent implements OnInit {
@ViewChild('sf', { static: false }) sf!: SFComponent; @ViewChild('sf', { static: false }) sf!: SFComponent;
tabType!: string; tabType!: string;
tabs: any[] = [ tabs: any[] = [
{ name: '待上传', value: '1' }, { name: '待上传', value: '0' },
{ name: '上传中', value: '2' }, { name: '上传中', value: '3' },
{ name: '已上传', value: '3' }, { name: '已上传', value: '1' },
{ name: '异常', value: '4' }, { name: '异常', value: '2' },
{ name: '全部', value: '' } { name: '全部', value: '' }
]; ];
selectedIndex = '1'; selectedIndex = '0';
isLoading: boolean = false; isLoading: boolean = false;
selectedRows: any[] = []; selectedRows: any[] = [];
constructor( constructor(
@ -53,7 +53,7 @@ export class DatatableOrderReportingComponent implements OnInit {
*/ */
get reqParams() { get reqParams() {
const params = Object.assign({}, this.sf?.value || {}, { const params = Object.assign({}, this.sf?.value || {}, {
putStatus: this.selectedIndex, billPutStatus: this.selectedIndex,
}); });
delete params._$expand; delete params._$expand;
return { ...params }; return { ...params };
@ -169,7 +169,7 @@ export class DatatableOrderReportingComponent implements OnInit {
title: '本地校验', title: '本地校验',
type: 'string', type: 'string',
enum: [ enum: [
{ label: '校验中', value: 0 }, { label: '检测中', value: 0 },
{ label: '通过', value: 1 }, { label: '通过', value: 1 },
{ label: '不通过', value: 2 } { label: '不通过', value: 2 }
], ],
@ -583,7 +583,7 @@ export class DatatableOrderReportingComponent implements OnInit {
filterCheckStatus(status: number) { filterCheckStatus(status: number) {
switch (status) { switch (status) {
case 0: case 0:
return '校验中'; return '检测中';
case 1: case 1:
return '通过'; return '通过';
case 2: case 2:
@ -594,4 +594,22 @@ export class DatatableOrderReportingComponent implements OnInit {
} }
} }
routeToOrder(item: any) {
if (item.billType === '1') {
window.open(location.origin + `/#/order-management/vehicle/vehicle-detail/${item.orderId}`);
} else {
window.open(location.origin + `/#/order-management/bulk/bulk-detail/${item.orderId}`);
}
}
routeTowaybill(item: any) {
if (item.billType === '1') {
window.open(location.origin + `/#/waybill-management/vehicle/vehicle-detail/${item.waybillId}`);
} else {
window.open(location.origin + `/#/waybill-management/bulk/bulk-detail/${item.waybillId}`);
}
}
} }

View File

@ -50,10 +50,10 @@ export class DatatableReportingvViewTrackComponent implements OnInit {
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = [...res.cityArray]; this.addressItems = [...res.parkArray];
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -78,7 +78,7 @@ export class DatatableReportingvViewTrackComponent implements OnInit {
this.addressItems = [...res.enclosureDataAppTrack]; this.addressItems = [...res.enclosureDataAppTrack];
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = item.vinOutTime ? this.getLocalTime(item.gtm) : ''; item.parkBte = item.parkBte ? this.getLocalTime(item.parkBte) : '';
item.cityName = item.appAdress; item.cityName = item.appAdress;
}); });
} }

View File

@ -137,8 +137,6 @@ export class FreightAccountService extends ShipperBaseService {
// 根据预收款ID获取核销信息明细 // 根据预收款ID获取核销信息明细
$api_get_advance_collection_hrxiao = '/api/fcc/ficoAhxH/getAhxHByYskblaId'; $api_get_advance_collection_hrxiao = '/api/fcc/ficoAhxH/getAhxHByYskblaId';
// 运营导出充值信息 充值记录导出 // 运营导出充值信息 充值记录导出
$api_get_exportPageByOperator = '/api/fcc/rechargeInfo/exportPageByOperator'; $api_get_exportPageByOperator = '/api/fcc/rechargeInfo/exportPageByOperator';
// 运营端导出交易流水明细 // 运营端导出交易流水明细
@ -205,21 +203,22 @@ export class FreightAccountService extends ShipperBaseService {
if (!url) { if (!url) {
return; return;
} }
const uA = window.navigator.userAgent; // 判断浏览器内核 this.openURL(url);
const isIE = // const uA = window.navigator.userAgent; // 判断浏览器内核
/msie\s|trident\/|edge\//i.test(uA) && // const isIE =
!!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window); // /msie\s|trident\/|edge\//i.test(uA) &&
const objectUrl = url; // !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
const a = document.createElement('a'); // const objectUrl = url;
document.body.appendChild(a); // const a = document.createElement('a');
a.href = objectUrl; // document.body.appendChild(a);
a.download = `回单.pdf`; // a.href = objectUrl;
if (isIE) { // a.download = `回单.pdf`;
// 兼容IE11无法触发下载的问题 // if (isIE) {
(navigator as any).msSaveBlob(url, a.download); // // 兼容IE11无法触发下载的问题
} else { // (navigator as any).msSaveBlob(url, a.download);
a.click(); // } else {
} // a.click();
a.remove(); // }
// a.remove();
} }
} }

View File

@ -19,12 +19,11 @@ import { map } from 'rxjs/operators';
export class InsuranceManagementService extends ShipperBaseService { export class InsuranceManagementService extends ShipperBaseService {
// 获取货主企业列表 // 获取货主企业列表
public $api_enterpriceList = '/api/mdc/cuc/enterpriseInfo/operate/enterpriceList'; public $api_enterpriceList = '/api/mdc/cuc/enterpriseInfo/operate/enterpriceList';
// 查询保险费信息表 // 查询保险费信息表
public $api_premiumInfo_list = '/api/sdc/premiumInfo/list/page'; public $api_premiumInfo_list = '/api/sdc/premiumInfo/list/page';
// 统计保险单状态数量 // 统计保险单状态数量
public $api_listStatisticalStatus = '/api/sdc/premiumInfo/listStatisticalStatus'; public $api_listStatisticalStatus = '/api/sdc/premiumInfo/listStatisticalStatus';
// 保险费公司认证 // 保险费公司认证
$api_get_submitAuthInfo = `/api/sdc/premiumInfo/submitAuthInfo`; $api_get_submitAuthInfo = `/api/sdc/premiumInfo/submitAuthInfo`;
// 退保费 // 退保费
@ -36,24 +35,25 @@ export class InsuranceManagementService extends ShipperBaseService {
if (!url) { if (!url) {
return; return;
} }
const uA = window.navigator.userAgent; // 判断浏览器内核 this.openURL(url);
const isIE = // const uA = window.navigator.userAgent; // 判断浏览器内核
/msie\s|trident\/|edge\//i.test(uA) && // const isIE =
!!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window); // /msie\s|trident\/|edge\//i.test(uA) &&
const objectUrl = url; // !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
const a = document.createElement('a'); // const objectUrl = url;
document.body.appendChild(a); // const a = document.createElement('a');
console.log('5555'); // document.body.appendChild(a);
// console.log('5555');
a.href = objectUrl;
a.download = '保单.pdf'; // a.href = objectUrl;
if (isIE) { // a.download = '保单.pdf';
// 兼容IE11无法触发下载的问题 // if (isIE) {
(navigator as any).msSaveBlob(url, a.download); // // 兼容IE11无法触发下载的问题
} else { // (navigator as any).msSaveBlob(url, a.download);
a.click(); // } else {
} // a.click();
a.remove(); // }
// a.remove();
} }
constructor(public injector: Injector) { constructor(public injector: Injector) {

View File

@ -180,7 +180,7 @@ export class OrderManagementAbnormalWarningComponent implements OnInit {
} }
} }
}, },
carNos: { carNo: {
title: '车牌号', title: '车牌号',
type: 'string', type: 'string',
ui: { ui: {

View File

@ -76,8 +76,8 @@ export class OrderManagementBulkDetailChangeComponent implements OnInit {
schema: SFSchema = {}; schema: SFSchema = {};
ui: SFUISchema = {}; ui: SFUISchema = {};
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' } { title: '地点', index: 'parkAdr' }
]; ];
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '款项', index: 'expenseCodeLabel' }, { title: '款项', index: 'expenseCodeLabel' },
@ -968,14 +968,15 @@ export class OrderManagementBulkDetailChangeComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res?.cityArray; this.addressItems = res?.parkArray;
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -991,7 +992,8 @@ export class OrderManagementBulkDetailChangeComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-06 20:20:26 * @Date : 2021-12-06 20:20:26
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-08 14:06:21 * @LastEditTime : 2022-04-13 19:02:35
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -15,26 +15,18 @@
</button> </button>
</ng-template> </ng-template>
<ng-template #headerContent> <ng-template #headerContent>
<div nz-row> <div nz-row>
<button nz-button nzType="primary" nzSize="small" nzDanger>{{ i?.billStatusLabel }}</button> <button nz-button nzType="primary" nzSize="small" nzDanger>{{ i?.billStatusLabel }}</button>
<h4 class="ml-md" style="font-size: 18px">订单号: {{ i?.billCode }}</h4> <h4 class="ml-md" style="font-size: 18px">订单号: {{ i?.billCode }}</h4>
</div> </div>
<div nz-row style="display: flex; justify-content: end" class="mb-xs"> <div nz-row style="display: flex; justify-content: end" class="mb-xs">
<div nz-col > <div nz-col>
<button <button (click)="cancellation()" nz-button
(click)="cancellation()"
nz-button
*ngIf="i?.billStatus !== '1' && i?.billStatus !== '5' && i?.billStatus !== '6' && i?.overallPaymentStatus != '2'" *ngIf="i?.billStatus !== '1' && i?.billStatus !== '5' && i?.billStatus !== '6' && i?.overallPaymentStatus != '2'"
acl [acl-ability]="['ORDER-BULK-DETAIL-cancelAnOrder']" acl [acl-ability]="['ORDER-BULK-DETAIL-cancelAnOrder']">取消订单</button>
>取消订单</button <button nz-button
> *ngIf="i?.billStatus == '4' || i?.billStatus == '5' || i?.billStatus == '2' || i?.billStatus == '3'" acl
<button [acl-ability]="['ORDER-BULK-DETAIL-modifyOrder']" (click)="changeOrder()">修改订单</button>
nz-button
*ngIf="i?.billStatus == '4' || i?.billStatus == '5' || i?.billStatus == '2' || i?.billStatus == '3'"
acl [acl-ability]="['ORDER-BULK-DETAIL-modifyOrder']"
(click)="changeOrder()"
>修改订单</button
>
</div> </div>
</div> </div>
<div> <div>
@ -43,8 +35,9 @@
<sv label="货主">{{ i?.goodsResource?.shipperAppUserName }} </sv> <sv label="货主">{{ i?.goodsResource?.shipperAppUserName }} </sv>
<sv label="所属项目">{{ i?.goodsResource?.enterpriseProjectName }}</sv> <sv label="所属项目">{{ i?.goodsResource?.enterpriseProjectName }}</sv>
<sv label="服务类型">{{ i?.goodsResource?.serviceTypeLabel }}</sv> <sv label="服务类型">{{ i?.goodsResource?.serviceTypeLabel }}</sv>
<sv label="录单员">{{ i?.createUserName }} {{ i?.createUserPhone ? "/" + i?.createUserPhone : ''}} </sv> <sv label="录单员">{{ i?.createUserName }} {{ i?.createUserPhone ? "/" + i?.createUserPhone : ''}} </sv>
<sv label="调度员">{{ i?.goodsResource?.dispatchName }}{{ i?.goodsResource?.dispatchPhone ? "/" + i?.goodsResource?.dispatchPhone : ''}} </sv> <sv label="调度员">{{ i?.goodsResource?.dispatchName }}{{ i?.goodsResource?.dispatchPhone ? "/" +
i?.goodsResource?.dispatchPhone : ''}} </sv>
<sv label="货源编号">{{ i?.goodsResource?.resourceCode }} </sv> <sv label="货源编号">{{ i?.goodsResource?.resourceCode }} </sv>
<sv label="运单号">{{ i?.wayBill?.wayBillCode }}</sv> <sv label="运单号">{{ i?.wayBill?.wayBillCode }}</sv>
<sv label="承诺付款天数">{{ i?.goodsResource?.paymentDays }}</sv> <sv label="承诺付款天数">{{ i?.goodsResource?.paymentDays }}</sv>
@ -64,12 +57,8 @@
<div style="width: 60%; margin: 0 auto"> <div style="width: 60%; margin: 0 auto">
   
<nz-steps [nzCurrent]="i?.scheduleVOList?.length + 1" nzLabelPlacement="vertical"> <nz-steps [nzCurrent]="i?.scheduleVOList?.length + 1" nzLabelPlacement="vertical">
<nz-step <nz-step *ngFor="let item of i?.scheduleVOList" [nzTitle]="item.state" [nzSubtitle]="item.stateTime"
*ngFor="let item of i?.scheduleVOList" [nzStatus]="item.displayStatus === 'SHOW' ? 'finish' : 'wait'"></nz-step>
[nzTitle]="item.state"
[nzSubtitle]="item.stateTime"
[nzStatus]="item.displayStatus === 'SHOW' ? 'finish' : 'wait'"
></nz-step>
</nz-steps> </nz-steps>
</div> </div>
</div> </div>
@ -82,9 +71,11 @@
</sv> </sv>
</sv-container> </sv-container>
<sv-container col="2"> <sv-container col="2">
<sv label="货物数量"> {{i?.goodsInfoList?.[0]?.weight}}吨,{{i?.goodsInfoList?.[0]?.volume}}方,{{i?.goodsInfoList?.[0]?.number}}件 </sv> <sv label="货物数量">
{{i?.goodsInfoList?.[0]?.weight}}吨,{{i?.goodsInfoList?.[0]?.volume}}方,{{i?.goodsInfoList?.[0]?.number}}件 </sv>
<sv label="用车需求">{{ i?.carModel }}{{ i?.carLength ? "/" + i?.carLength : ''}} </sv> <sv label="用车需求">{{ i?.carModel }}{{ i?.carLength ? "/" + i?.carLength : ''}} </sv>
<sv label="承运司机"> {{ i?.driverName }}{{i?.driverPhone ? "/" + i?.driverPhone : ''}}{{ i?.carNo ? "/" + i?.carNo : ''}} </sv> <sv label="承运司机"> {{ i?.driverName }}{{i?.driverPhone ? "/" + i?.driverPhone : ''}}{{ i?.carNo ? "/" + i?.carNo :
''}} </sv>
<sv label="车型车长载重"> {{ i?.driverCarModelLabel }},{{ i?.driverCarLengthLabel }}米,{{ i?.driverCarWeight }}吨 </sv> <sv label="车型车长载重"> {{ i?.driverCarModelLabel }},{{ i?.driverCarLengthLabel }}米,{{ i?.driverCarWeight }}吨 </sv>
<!-- <sv label="计划装货时间"> <!-- <sv label="计划装货时间">
{{ i?.loadPlanTime }} {{ i?.loadPlanTime }}
@ -93,14 +84,14 @@
{{ i?.unloadPlanTime }} {{ i?.unloadPlanTime }}
</sv> --> </sv> -->
<sv label="接单数量"> {{ i?.acceptWeight }}吨,{{ i?.acceptVolume }}方 </sv> <sv label="接单数量"> {{ i?.acceptWeight }}吨,{{ i?.acceptVolume }}方 </sv>
<sv *ngIf="i?.billStatus =='3' || i?.billStatus =='4' || i?.billStatus =='5'" label="装货数量"> {{ i?.loadWeight }}吨,{{ i?.loadVolume }}方</sv> <sv *ngIf="i?.billStatus =='3' || i?.billStatus =='4' || i?.billStatus =='5'" label="装货数量"> {{ i?.loadWeight }}吨,{{
<sv *ngIf="i?.billStatus =='4' || i?.billStatus =='5'" label="卸货数量"> {{ i?.settlementWeight }}吨,{{ i?.settlementVolume }}方</sv> i?.loadVolume }}方</sv>
<sv *ngIf="i?.billStatus =='4' || i?.billStatus =='5'" label="卸货数量"> {{ i?.settlementWeight }}吨,{{
i?.settlementVolume }}方</sv>
</sv-container> </sv-container>
<div class="mt-md"> <div class="mt-md">
<h4 class="text-md" <h4 class="text-md">装货卸货信息
>装货卸货信息 <span class="ml-sm text-sm">(
<span class="ml-sm text-sm"
>(
<label>{{ i?.loadingCount || '一' }}装</label> <label>{{ i?.loadingCount || '一' }}装</label>
<label>{{ i?.unloadingCount || '一' }}卸</label> <label>{{ i?.unloadingCount || '一' }}卸</label>
</span> </span>
@ -114,7 +105,7 @@
<div class="handling-info-icon loading-bg"></div> <div class="handling-info-icon loading-bg"></div>
<div class="info"> <div class="info">
<h4>装货地:{{ item?.province }}{{ item.city }}{{ item.area }}{{ item.detailedAddress }}</h4> <h4>装货地:{{ item?.province }}{{ item.city }}{{ item.area }}{{ item.detailedAddress }}</h4>
<p>联系人:{{ item.appUserName }}{{ item.contractTelephone ? "/" + item.contractTelephone : '' }}</p> <p>联系人:{{ item.appUserName }}{{ item.contractTelephone ? "/" + item.contractTelephone : '' }}</p>
</div> </div>
</div> </div>
</div> </div>
@ -127,7 +118,7 @@
<div class="handling-info-icon unloaing-bg"></div> <div class="handling-info-icon unloaing-bg"></div>
<div class="info"> <div class="info">
<h4>卸货地:{{ item?.province }}{{ item.city }}{{ item.area }}{{ item.detailedAddress }}</h4> <h4>卸货地:{{ item?.province }}{{ item.city }}{{ item.area }}{{ item.detailedAddress }}</h4>
<p>联系人:{{ item.appUserName }}{{ item.contractTelephone ? "/" + item.contractTelephone : ''}}</p> <p>联系人:{{ item.appUserName }}{{ item.contractTelephone ? "/" + item.contractTelephone : ''}}</p>
</div> </div>
</div> </div>
</div> </div>
@ -137,11 +128,12 @@
</div> </div>
</nz-card> </nz-card>
<nz-card nzTitle="运费信息" #distannce3> <nz-card nzTitle="运费信息" #distannce3>
<h2>{{i?.freightPrice}}{{i?.freightTypeLabel}}{{ i?.settlementBasisLabel ? i?.settlementBasisLabel + '' :' ' }}{{i?.ruleLabel}}</h2> <h2>{{i?.freightPrice}}{{i?.freightTypeLabel}}{{ i?.settlementBasisLabel ? i?.settlementBasisLabel + '' :' '
}}{{i?.ruleLabel}}</h2>
<st #st [data]="billExpenses" [columns]="logColumns" [ps]="0" [page]="{ show: false, showSize: false }"> <st #st [data]="billExpenses" [columns]="logColumns" [ps]="0" [page]="{ show: false, showSize: false }">
<ng-template st-row="PriceType" let-item let-index="index"> 到付 </ng-template> <ng-template st-row="PriceType" let-item let-index="index"> 到付 </ng-template>
<ng-template st-row="prices" let-item let-index="index"> <ng-template st-row="prices" let-item let-index="index">
{{ item.price + item.surcharge | currency }} {{ item.price + item.surcharge | currency }}
</ng-template> </ng-template>
<ng-template st-row="price" let-item let-index="index"> <ng-template st-row="price" let-item let-index="index">
{{ item.price | currency }} {{ item.price | currency }}
@ -152,26 +144,30 @@
</st> </st>
<div> <div>
<div> <div>
总计:<span style="color: #da001b; font-size: 18px">{{ i?.totalAmount | currency }}</span> (运费{{ i?.totalFreight | currency }} 总计:<span style="color: #da001b; font-size: 18px">{{ i?.totalAmount | currency }}</span> (运费{{ i?.totalFreight |
currency }}
附加费{{ i?.totalSurcharge | currency }},附加费率{{ (i?.totalRate * 100).toFixed(2)}}% 附加费{{ i?.totalSurcharge | currency }},附加费率{{ (i?.totalRate * 100).toFixed(2)}}%
</div> </div>
</div> </div>
<div *ngIf ="i?.payeePhone && i?.payeePhone !== i?.driverPhone">车队长:{{ i?.payeeName }}{{ i?.payeePhone ? "/" + i?.payeePhone : ''}}</div> <div *ngIf="i?.payeePhone && i?.payeePhone !== i?.driverPhone">车队长:{{ i?.payeeName }}{{ i?.payeePhone ? "/" +
i?.payeePhone : ''}}</div>
</nz-card> </nz-card>
<nz-card nzTitle="附件信息" #distannce4> <nz-card nzTitle="附件信息" #distannce4>
<sv-container> <sv-container>
<sv label="协议附件"> <sv label="协议附件">
<a *ngIf = "i?.contractContent?.contractContent" (click)="agreement('1')">查看附件</a> &nbsp;&nbsp;&nbsp;&nbsp; <a *ngIf="i?.contractContent?.contractContent" (click)="agreement('1')">查看附件</a> &nbsp;&nbsp;&nbsp;&nbsp;
<a *ngIf = "i?.supplementContent?.contractContent" (click)="agreement('2')">补充协议</a> <a *ngIf="i?.supplementContent?.contractContent" (click)="agreement('2')">补充协议</a>
</sv> </sv>
</sv-container> </sv-container>
<sv-container col="2" class="mt-md"> <sv-container col="2" class="mt-md">
<sv label="装货凭证"> <sv label="装货凭证">
<app-imagelist *ngIf="i?.loadingLadingBillFilePath || i?.loadingPeopleVehiclesGoodsFilePath" [imgList]="[i?.loadingLadingBillFilePath, i?.loadingPeopleVehiclesGoodsFilePath]"> </app-imagelist> <app-imagelist *ngIf="i?.loadingLadingBillFilePath || i?.loadingPeopleVehiclesGoodsFilePath"
[imgList]="[i?.loadingLadingBillFilePath, i?.loadingPeopleVehiclesGoodsFilePath]"> </app-imagelist>
</sv> </sv>
<sv label="卸货凭证"> <sv label="卸货凭证">
<app-imagelist *ngIf="i?.unloadingLadingBillFilePath || i?.unloadingPeopleVehiclesGoodsFilePath " [imgList]="[i?.unloadingLadingBillFilePath, i?.unloadingPeopleVehiclesGoodsFilePath]"> </app-imagelist> <app-imagelist *ngIf="i?.unloadingLadingBillFilePath || i?.unloadingPeopleVehiclesGoodsFilePath "
[imgList]="[i?.unloadingLadingBillFilePath, i?.unloadingPeopleVehiclesGoodsFilePath]"> </app-imagelist>
</sv> </sv>
</sv-container> </sv-container>
</nz-card> </nz-card>
@ -183,7 +179,8 @@
<sv label="回单类型" *ngIf="i?.supplementaryInformationVO?.stateReceipt"> <sv label="回单类型" *ngIf="i?.supplementaryInformationVO?.stateReceipt">
{{ i?.supplementaryInformationVO?.receiptType === '1' ? '电子回单' : '纸质回单' }} {{ i?.supplementaryInformationVO?.receiptType === '1' ? '电子回单' : '纸质回单' }}
</sv> </sv>
<sv label="联系人" *ngIf="i?.supplementaryInformationVO?.stateReceipt"> {{ i?.supplementaryInformationVO?.receiptUserName }} / {{ i?.supplementaryInformationVO?.phon }} </sv> <sv label="联系人" *ngIf="i?.supplementaryInformationVO?.stateReceipt"> {{
i?.supplementaryInformationVO?.receiptUserName }} / {{ i?.supplementaryInformationVO?.phon }} </sv>
<sv label="所在地区" *ngIf="i?.supplementaryInformationVO?.stateReceipt"> <sv label="所在地区" *ngIf="i?.supplementaryInformationVO?.stateReceipt">
{{ i?.supplementaryInformationVO?.area }} {{ i?.supplementaryInformationVO?.area }}
</sv> </sv>
@ -206,11 +203,13 @@
<nz-card nzTitle="轨迹信息" style="width: 100%" [nzExtra]="extraTemplate" #distannce5> <nz-card nzTitle="轨迹信息" style="width: 100%" [nzExtra]="extraTemplate" #distannce5>
<div nz-row> <div nz-row>
<div nz-col [nzSpan]="12"> <div nz-col [nzSpan]="12">
<st [scroll]="{y: '500px'}" style="min-height: 600px;" #st [data]="addressItems" [columns]="logColumns2" [ps]="0" [page]="{ show: false, showSize: false }"> <st [scroll]="{y: '500px'}" style="min-height: 600px;" #st [data]="addressItems" [columns]="logColumns2"
[ps]="0" [page]="{ show: false, showSize: false }">
</st> </st>
</div> </div>
<div nz-col [nzSpan]="12"> <div nz-col [nzSpan]="12">
<amap-path-simplifier [mapWidth]="'100%'" [pois]="pois" [mapHeight]="'600px'" [mapList]="mapList"></amap-path-simplifier> <amap-path-simplifier [mapWidth]="'100%'" [pois]="pois" [mapHeight]="'600px'" [mapList]="mapList">
</amap-path-simplifier>
</div> </div>
</div> </div>
</nz-card> </nz-card>
@ -222,9 +221,10 @@
</ng-template> </ng-template>
</div> </div>
</nz-card> </nz-card>
<nz-card *ngIf="!route?.snapshot?.queryParams?.sts && abnormalList.length > 0"> <nz-card>
<nz-tabset > <nz-tabset>
<nz-tab nzTitle="风险异常检测"> <nz-tab nzTitle="风险异常检测">
<div *ngIf="abnormalList.length > 0">
<div> <div>
您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您! 您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您!
</div> </div>
@ -232,21 +232,28 @@
<ul *ngFor="let item of abnormalList"> <ul *ngFor="let item of abnormalList">
<li>系统识别:{{item?.complianceTypeName}}</li> <li>系统识别:{{item?.complianceTypeName}}</li>
<li>{{item?.determineDetails}},您可在企业端提交申诉材料或联系客服。</li> <li>{{item?.determineDetails}},您可在企业端提交申诉材料或联系客服。</li>
<li>2021-11-07 03:20:15</li>
</ul> </ul>
</div>
</nz-tab> </nz-tab>
<nz-tab nzTitle="异常预警"> <nz-tab nzTitle="异常预警">
<st #st [data]="addressItems" [columns]="logColumns2" [ps]="0" [page]="{ show: false, showSize: false }"> <st #st [data]="service.$api_get_order_abnormalWarning" [columns]="logColumns3"
</st> [res]="{ reName: { list: 'data' } }" [req]="{params:{id:route.snapshot.params.id}}"
[page]="{ show: false, showSize: false }"> </st>
</nz-tab> </nz-tab>
<nz-tab nzTitle="操作日志"> <nz-tab nzTitle="操作日志">
<st #st [data]="addressItems" [columns]="logColumns2" [ps]="0" [page]="{ show: false, showSize: false }"> <st #logSt [data]="service.$api_get_log_list" [columns]="operateLogColums"
</st> [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: logParams ,lazyLoad:true}"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }">
<ng-template st-row="operator" let-item>
{{item?.operator}}/{{item.telephone}}
</ng-template>
</st>
</nz-tab> </nz-tab>
</nz-tabset> </nz-tabset>
</nz-card> </nz-card>
<nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" [nzTitle]="modalTitle" (nzOnOk)="handleOK()" nzWidth="1000px" (nzOnCancel)="handleCancel()"> <nz-modal [(nzVisible)]="isVisible" [nzFooter]="nzModalFooter" [nzTitle]="modalTitle" (nzOnOk)="handleOK()"
nzWidth="1000px" (nzOnCancel)="handleCancel()">
<ng-container *nzModalContent> <ng-container *nzModalContent>
<div *ngIf="!modalcontent">暂无附件信息</div> <div *ngIf="!modalcontent">暂无附件信息</div>
<div [innerHTML]="modalcontent"></div> <div [innerHTML]="modalcontent"></div>
@ -255,4 +262,4 @@
<button nz-button nzType="primary" (click)="handleOK()" [disabled]="">取消</button> <button nz-button nzType="primary" (click)="handleOK()" [disabled]="">取消</button>
<button nz-button nzType="default" (click)="handleCancel()">确定 </button> <button nz-button nzType="default" (click)="handleCancel()">确定 </button>
</ng-template> </ng-template>
</nz-modal> </nz-modal>

View File

@ -4,14 +4,14 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-06 20:20:26 * @Date : 2021-12-06 20:20:26
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-11 22:31:18 * @LastEditTime : 2022-04-13 19:00:19
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\bulk-detail\\bulk-detail.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
import { Router } from '@angular/router'; import { Router } from '@angular/router';
import { Component, OnInit } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute } from '@angular/router'; import { ActivatedRoute } from '@angular/router';
import { STColumn } from '@delon/abc/st'; import { STColumn, STComponent } from '@delon/abc/st';
import { _HttpClient } from '@delon/theme'; import { _HttpClient } from '@delon/theme';
import { NzMessageService } from 'ng-zorro-antd/message'; import { NzMessageService } from 'ng-zorro-antd/message';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
@ -25,7 +25,8 @@ import format from 'date-fns/format';
styleUrls: ['./bulk-detail.component.less'] styleUrls: ['./bulk-detail.component.less']
}) })
export class OrderManagementBulkeDetailComponent implements OnInit { export class OrderManagementBulkeDetailComponent implements OnInit {
MapList: any[]=[]; MapList: any[] = [];
@ViewChild('logSt') logSt!: STComponent;
id = this.route.snapshot.params.id; id = this.route.snapshot.params.id;
billExpenses: any[] = []; //运费信息表格信息 billExpenses: any[] = []; //运费信息表格信息
pois: any[] = []; pois: any[] = [];
@ -35,11 +36,20 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
totalObj: any; totalObj: any;
attObj: any; attObj: any;
modalcontent: any; modalcontent: any;
modalTitle:string = ''; modalTitle: string = '';
isVisible = false; isVisible = false;
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' }, { title: '地点', index: 'parkAdr' }
];
logColumns3: STColumn[] = [
{ title: '时间', index: 'warningTime' },
{ title: '异常预警类型', index: 'warningTypeLabel' }
];
operateLogColums: STColumn[] = [
{ title: '内容', index: 'operationContent' },
{ title: '操作人', render: 'operator' },
{ title: '操作时间', index: 'operatorTimestamp' },
]; ];
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '款项', index: 'expenseCodeLabel' }, { title: '款项', index: 'expenseCodeLabel' },
@ -61,21 +71,23 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
} }
} }
]; ];
get logParams() {
return { operateObject: this.i?.billCode, operateTypeList: ['3','8'] }
}
trajectory = 'car'; trajectory = 'car';
mapList:any[] = []; //地图点位数据组 mapList: any[] = []; //地图点位数据组
addressItems:any[] = []; //打点地址数据组 addressItems: any[] = []; //打点地址数据组
warringList: any[] = []; //打点地址数据组
constructor( constructor(
public route: ActivatedRoute, public route: ActivatedRoute,
private msgSrv: NzMessageService, private msgSrv: NzMessageService,
private service: OrderManagementService, public service: OrderManagementService,
private router: Router, private router: Router,
private modal: NzModalService private modal: NzModalService
) { ) {}
}
ngOnInit(): void { ngOnInit(): void {
console.log(this.route?.snapshot?.queryParams?.sts); console.log(this.route?.snapshot?.queryParams?.sts);
this.initData(); this.initData();
this.getTrajectory(); this.getTrajectory();
} }
@ -85,36 +97,45 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
if (res) { if (res) {
this.i = res; this.i = res;
this.billExpenses = this.i?.billExpenseDetails?.filter((data: any) => data.expenseCode === 'TRA'); this.billExpenses = this.i?.billExpenseDetails?.filter((data: any) => data.expenseCode === 'TRA');
this.i.scheduleVOList = this.i?.scheduleVOList?.filter((data:any)=>data.displayStatus !=="HIDE"); this.i.scheduleVOList = this.i?.scheduleVOList?.filter((data: any) => data.displayStatus !== 'HIDE');
this.pois = [ this.pois = [
{ {
markerLabel: '', markerLabel: '',
color: 'blue', color: 'blue',
position: [res.startingPoint.longitude, res.startingPoint.latitude], position: [res.startingPoint.longitude, res.startingPoint.latitude],
title: res.startingPoint.detailedAddress title: `发货地:${res.startingPoint.province}${res.startingPoint.city}${res.startingPoint.area || ''}${
res.startingPoint.detailedAddress
}`,
time: '计划出发时间:' + res.loadPlanTime
}, },
{ {
markerLabel: '卸', markerLabel: '卸',
color: 'red', color: 'red',
position: [res.endPoint.longitude, res.endPoint.latitude], position: [res.endPoint.longitude, res.endPoint.latitude],
title: res.endPoint.detailedAddress title: `卸货地:${res.endPoint.province}${res.endPoint.city}${res.endPoint.area}${res.endPoint.detailedAddress}`,
time: '计划卸货时间:' + res.unloadPlanTime
} }
]; ];
} }
}); });
this.service.request(this.service.$api_listBillComplianceAbnormalByBillId, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_listBillComplianceAbnormalByBillId, { id: this.id }).subscribe(res => {
if (res) { if (res) {
console.log('风险详情') console.log('风险详情');
console.log(res) console.log(res);
this.abnormalList = res this.abnormalList = res;
} }
}); });
this.service.request(this.service.$api_getAbnormalWarningByBillId, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_getAbnormalWarningByBillId, { id: this.id }).subscribe(res => {
if (res) { if (res) {
console.log('异常预警') console.log('异常预警');
console.log(res) console.log(res);
this.warringList = res
} }
}); });
setTimeout(() => {
this.logSt.load(1);
});
} }
goBack() { goBack() {
@ -125,11 +146,12 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
this.router.navigate(['order-management/bulk-detailChange', this.id]); this.router.navigate(['order-management/bulk-detailChange', this.id]);
} }
agreement(value: any) { agreement(value: any) {
if(value ==='1'){ if (value === '1') {
this.modalTitle = '附件信息'; this.modalTitle = '附件信息';
// this.modalcontent = this.i?.contractContent?.contractContent; // this.modalcontent = this.i?.contractContent?.contractContent;
this.service.reviewPDF(this.i?.contractContent?.contractFilePath) // this.service.reviewPDF(this.i?.contractContent?.contractFilePath)
}else if(value === '2'){ this.service.openURL(this.i?.contractContent?.contractFilePath);
} else if (value === '2') {
this.modalTitle = '补充协议'; this.modalTitle = '补充协议';
this.modalcontent = this.i?.supplementContent?.contractContent; this.modalcontent = this.i?.supplementContent?.contractContent;
this.isVisible = true; this.isVisible = true;
@ -163,43 +185,45 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
} }
// 获取车辆轨迹 // 获取车辆轨迹
getTrajectory(){ getTrajectory() {
this.service.request(this.service.$api_get_getTrajectory, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_get_getTrajectory, { id: this.id }).subscribe(res => {
if (res) { if (res) {
const points = res.trackArray; const points = res.trackArray;
let list :any[] = []; let list: any[] = [];
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res.cityArray; this.addressItems = res.parkArray;
if(this.addressItems && this.addressItems.length > 0){ if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
}); });
} }
// 获取司机轨迹 // 获取司机轨迹
getDriverTrajectory(){ getDriverTrajectory() {
this.service.request(this.service.$api_get_getAppDriverPosition, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_get_getAppDriverPosition, { id: this.id }).subscribe(res => {
if (res) { if (res) {
const points = res.tracks; const points = res.tracks;
let list :any[] = []; let list: any[] = [];
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = [...res.enclosureDataAppTrack]; this.addressItems = [...res.enclosureDataAppTrack];
if(this.addressItems && this.addressItems.length > 0){ if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.gtm); item.vinOutTime = this.getLocalTime(item.gtm);
item.cityName = item.appAdress; item.cityName = item.appAdress;
@ -207,14 +231,14 @@ export class OrderManagementBulkeDetailComponent implements OnInit {
} }
} }
}); });
} }
trajectoryChange(event:any){ trajectoryChange(event: any) {
if(event ==='car'){ if (event === 'car') {
this.getTrajectory() this.getTrajectory();
}else if(event ==='driver'){ } else if (event === 'driver') {
this.getDriverTrajectory(); this.getDriverTrajectory();
} }
} }
getLocalTime(time: any) { getLocalTime(time: any) {
return format(new Date(parseInt(time)), 'yyyy-MM-dd HH:mm:ss'); return format(new Date(parseInt(time)), 'yyyy-MM-dd HH:mm:ss');
} }

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-01-04 17:29:18 * @Date : 2022-01-04 17:29:18
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-29 16:26:09 * @LastEditTime : 2022-04-13 10:50:02
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\complaint-detail\\complaint-detail.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\complaint-detail\\complaint-detail.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -24,8 +24,12 @@
<h2>投诉单号:{{datailList?.complaintCode}}</h2> <h2>投诉单号:{{datailList?.complaintCode}}</h2>
<sf #sf [compact]="true" [ui]="ui" [schema]="schema" [button]="'none'" *ngIf="schema" [formData]="datailList"> <sf #sf [compact]="true" [ui]="ui" [schema]="schema" [button]="'none'" *ngIf="schema" [formData]="datailList">
<ng-template sf-template="imgUrls" let-schema="schema" let-item let-ui="ui"> <ng-template sf-template="imgUrls" let-schema="schema" let-item let-ui="ui">
<app-imagelist [imgList]="datailList?.imgUrls"></app-imagelist> <!-- <app-imagelist [imgList]="datailList?.imgUrls"></app-imagelist> -->
<img nz-image width="100px" height="100%" *ngFor="let item of datailList?.imgUrls" [nzSrc]="item"
style="margin:0 10px 0 0" alt="" />
</ng-template> </ng-template>
</sf> </sf>
</nz-card> </nz-card>

View File

@ -88,7 +88,7 @@ export class OrderManagementRiskComponent implements OnInit {
this.loading = false this.loading = false
return data.map(item => ({ return data.map(item => ({
...item, ...item,
disabled: item.auditStatus !== '1' disabled: item.representationsStatus !== '2'
})); }));
}; };
search() { search() {
@ -202,15 +202,28 @@ export class OrderManagementRiskComponent implements OnInit {
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
shipperId: { shipperId: {
title: '托运人',
type: 'string', type: 'string',
title: '托运人',
ui: { ui: {
widget: 'dict-select', widget: 'select',
params: { dictKey: 'BulkFreightUnitPriceType' }, serverSearch: true,
containsAllLabel: true, searchDebounceTime: 300,
searchLoadingText: '搜索中...',
allowClear: true,
visibleIf: { visibleIf: {
_$expand: (value: boolean) => value _$expand: (value: boolean) => value
} },
onSearch: (q: any) => {
let str =q.replace(/^\s+|\s+$/g,"");
if (str) {
return this.service
.request(this.service.$api_enterpriceList, { enterpriseName: str })
.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
}, },
enterpriseInfoId: { enterpriseInfoId: {

View File

@ -90,8 +90,8 @@ export class OrderManagementVehicleDetailChangeComponent implements OnInit {
mapList: any[] = []; //地图点位数据组 mapList: any[] = []; //地图点位数据组
addressItems: any[] = []; //打点地址数据组 addressItems: any[] = []; //打点地址数据组
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' } { title: '地点', index: 'parkAdr' }
]; ];
constructor( constructor(
private route: ActivatedRoute, private route: ActivatedRoute,
@ -923,14 +923,15 @@ export class OrderManagementVehicleDetailChangeComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res?.cityArray; this.addressItems = res?.parkArray;
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -946,7 +947,8 @@ export class OrderManagementVehicleDetailChangeComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-28 14:42:03 * @Date : 2021-12-28 14:42:03
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-08 14:06:27 * @LastEditTime : 2022-04-13 19:04:48
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle-detail\\vehicle-detail.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle-detail\\vehicle-detail.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -21,22 +21,12 @@
</div> </div>
<div nz-row style="display: flex; justify-content: end" class="mb-xs"> <div nz-row style="display: flex; justify-content: end" class="mb-xs">
<div nz-col> <div nz-col>
<button <button (click)="cancellation()" nz-button
(click)="cancellation()"
nz-button
*ngIf="i.billStatus == '4' || i.billStatus == '5' || i.billStatus == '2' || i.billStatus == '3' || i.billStatus == '1'" *ngIf="i.billStatus == '4' || i.billStatus == '5' || i.billStatus == '2' || i.billStatus == '3' || i.billStatus == '1'"
acl acl [acl-ability]="['ORDER-VEHICLE-DETAIL-cancelAnOrder']">取消订单</button>
[acl-ability]="['ORDER-VEHICLE-DETAIL-cancelAnOrder']" <button nz-button (click)="changeOrder()"
>取消订单</button *ngIf="i.billStatus == '4' || i.billStatus == '5' || i.billStatus == '2' || i.billStatus == '3'" acl
> [acl-ability]="['ORDER-VEHICLE-DETAIL-modifyOrder']">修改订单</button>
<button
nz-button
(click)="changeOrder()"
*ngIf="i.billStatus == '4' || i.billStatus == '5' || i.billStatus == '2' || i.billStatus == '3'"
acl
[acl-ability]="['ORDER-VEHICLE-DETAIL-modifyOrder']"
>修改订单</button
>
</div> </div>
</div> </div>
<div> <div>
@ -46,8 +36,8 @@
<sv label="所属项目">{{ i?.goodsResource?.enterpriseProjectName }}</sv> <sv label="所属项目">{{ i?.goodsResource?.enterpriseProjectName }}</sv>
<sv label="服务类型">{{ i?.goodsResource?.serviceTypeLabel }}</sv> <sv label="服务类型">{{ i?.goodsResource?.serviceTypeLabel }}</sv>
<sv label="录单员">{{ i?.createUserName }} {{ i?.createUserPhone ? '/' + i?.createUserPhone : '' }} </sv> <sv label="录单员">{{ i?.createUserName }} {{ i?.createUserPhone ? '/' + i?.createUserPhone : '' }} </sv>
<sv label="调度员" <sv label="调度员">{{ i?.goodsResource?.dispatchName }}{{ i?.goodsResource?.dispatchPhone ? '/' +
>{{ i?.goodsResource?.dispatchName }}{{ i?.goodsResource?.dispatchPhone ? '/' + i?.goodsResource?.dispatchPhone : '' }} i?.goodsResource?.dispatchPhone : '' }}
</sv> </sv>
<sv label="外部订单号">{{ i?.externalBillCode }}</sv> <sv label="外部订单号">{{ i?.externalBillCode }}</sv>
<sv label="货源编号">{{ i?.goodsResource?.resourceCode }} </sv> <sv label="货源编号">{{ i?.goodsResource?.resourceCode }} </sv>
@ -70,13 +60,9 @@
<div style="width: 60%; margin: 0 auto"> <div style="width: 60%; margin: 0 auto">
   
<nz-steps [nzCurrent]="i?.scheduleVOList?.length + 1" nzLabelPlacement="vertical"> <nz-steps [nzCurrent]="i?.scheduleVOList?.length + 1" nzLabelPlacement="vertical">
<nz-step <nz-step *ngFor="let item of i?.scheduleVOList" [nzTitle]="item.state" [nzSubtitle]="item.stateTime"
*ngFor="let item of i?.scheduleVOList"
[nzTitle]="item.state"
[nzSubtitle]="item.stateTime"
[nzDescription]="item.cancelReason ? '取消原因' + item.cancelReason : ''" [nzDescription]="item.cancelReason ? '取消原因' + item.cancelReason : ''"
[nzStatus]="item.displayStatus === 'SHOW' ? 'finish' : 'wait'" [nzStatus]="item.displayStatus === 'SHOW' ? 'finish' : 'wait'"></nz-step>
></nz-step>
</nz-steps> </nz-steps>
</div> </div>
</div> </div>
@ -93,16 +79,16 @@
</sv> </sv>
</sv-container> </sv-container>
<sv-container col="2"> <sv-container col="2">
<sv label="货物数量"> {{i?.goodsInfoList?.[0]?.weight}}吨,{{i?.goodsInfoList?.[0]?.volume}}方,{{i?.goodsInfoList?.[0]?.number}}件 </sv> <sv label="货物数量">
{{i?.goodsInfoList?.[0]?.weight}}吨,{{i?.goodsInfoList?.[0]?.volume}}方,{{i?.goodsInfoList?.[0]?.number}}件 </sv>
<sv label="用车需求">{{ i?.carModel }}{{ i?.carLength ? '/' + i?.carLength : '' }}</sv> <sv label="用车需求">{{ i?.carModel }}{{ i?.carLength ? '/' + i?.carLength : '' }}</sv>
<sv label="承运司机"> {{ i?.driverName }}{{ i?.driverPhone ? '/' + i?.driverPhone : '' }}{{ i?.carNo ? '/' + i?.carNo : '' }} </sv> <sv label="承运司机"> {{ i?.driverName }}{{ i?.driverPhone ? '/' + i?.driverPhone : '' }}{{ i?.carNo ? '/' + i?.carNo :
'' }} </sv>
<sv label="车型车长载重"> {{ i?.driverCarModelLabel }},{{ i?.driverCarLengthLabel }}米,{{ i?.driverCarWeight }}吨 </sv> <sv label="车型车长载重"> {{ i?.driverCarModelLabel }},{{ i?.driverCarLengthLabel }}米,{{ i?.driverCarWeight }}吨 </sv>
</sv-container> </sv-container>
<div class="mt-md"> <div class="mt-md">
<h4 class="text-md" <h4 class="text-md">装货卸货信息
>装货卸货信息 <span class="ml-sm text-sm">(
<span class="ml-sm text-sm"
>(
<label>{{ i?.loadingCount }}装</label> <label>{{ i?.loadingCount }}装</label>
<label>{{ i?.unloadingCount }}卸</label> <label>{{ i?.unloadingCount }}卸</label>
) )
@ -167,10 +153,12 @@
</ng-template> </ng-template>
</st> </st>
<div> <div>
总计:<span style="color: #da001b; font-size: 18px">{{ i?.totalAmount | currency }}</span> (运费{{ i?.totalFreight | currency }} 总计:<span style="color: #da001b; font-size: 18px">{{ i?.totalAmount | currency }}</span> (运费{{ i?.totalFreight |
currency }}
附加费{{ i?.totalSurcharge | currency }},附加费率{{ (i?.totalRate * 100).toFixed(2) }}% 附加费{{ i?.totalSurcharge | currency }},附加费率{{ (i?.totalRate * 100).toFixed(2) }}%
</div> </div>
<div *ngIf ="i?.payeePhone && i?.payeePhone !== i?.driverPhone">车队长:{{ i?.payeeName }}{{ i?.payeePhone ? '/' + i?.payeePhone : '' }}</div> <div *ngIf="i?.payeePhone && i?.payeePhone !== i?.driverPhone">车队长:{{ i?.payeeName }}{{ i?.payeePhone ? '/' +
i?.payeePhone : '' }}</div>
</nz-card> </nz-card>
<nz-card nzTitle="附件信息" #distannce4> <nz-card nzTitle="附件信息" #distannce4>
@ -185,7 +173,8 @@
<app-imagelist [imgList]="[i?.loadingLadingBillFilePath, i?.loadingPeopleVehiclesGoodsFilePath]"> </app-imagelist> <app-imagelist [imgList]="[i?.loadingLadingBillFilePath, i?.loadingPeopleVehiclesGoodsFilePath]"> </app-imagelist>
</sv> </sv>
<sv label="卸货凭证"> <sv label="卸货凭证">
<app-imagelist [imgList]="[i?.unloadingLadingBillFilePath, i?.unloadingPeopleVehiclesGoodsFilePath]"> </app-imagelist> <app-imagelist [imgList]="[i?.unloadingLadingBillFilePath, i?.unloadingPeopleVehiclesGoodsFilePath]">
</app-imagelist>
</sv> </sv>
</sv-container> </sv-container>
</nz-card> </nz-card>
@ -222,19 +211,13 @@
<nz-card nzTitle="轨迹信息" style="width: 100%" [nzExtra]="extraTemplate" #distannce5> <nz-card nzTitle="轨迹信息" style="width: 100%" [nzExtra]="extraTemplate" #distannce5>
<div nz-row> <div nz-row>
<div nz-col [nzSpan]="12"> <div nz-col [nzSpan]="12">
<st <st [scroll]="{ y: '500px' }" style="min-height: 600px" #st [data]="addressItems" [columns]="logColumns2"
[scroll]="{ y: '500px' }" [ps]="0" [page]="{ show: false, showSize: false }">
style="min-height: 600px"
#st
[data]="addressItems"
[columns]="logColumns2"
[ps]="0"
[page]="{ show: false, showSize: false }"
>
</st> </st>
</div> </div>
<div nz-col [nzSpan]="12"> <div nz-col [nzSpan]="12">
<amap-path-simplifier [mapWidth]="'100%'" [mapHeight]="'600px'" [mapList]="mapList" [pois]="pois"></amap-path-simplifier> <amap-path-simplifier [mapWidth]="'100%'" [mapHeight]="'600px'" [mapList]="mapList" [pois]="pois">
</amap-path-simplifier>
</div> </div>
</div> </div>
</nz-card> </nz-card>
@ -246,33 +229,36 @@
</ng-template> </ng-template>
</div> </div>
</nz-card> </nz-card>
<nz-card *ngIf="!route?.snapshot?.queryParams?.sts && abnormalList.length > 0"> <nz-card >
<nz-tabset> <nz-tabset>
<nz-tab nzTitle="风险异常检测"> <nz-tab nzTitle="风险异常检测">
<div *ngIf="abnormalList.length > 0">
<div> 您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您! </div> <div> 您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您! </div>
<div>如果您的运单没有问题可以提出申诉并提供相关资料我们将24小时内审核反馈</div> <div>如果您的运单没有问题可以提出申诉并提供相关资料我们将24小时内审核反馈</div>
<ul *ngFor="let item of abnormalList"> <ul *ngFor="let item of abnormalList">
<li>系统识别:{{ item?.complianceTypeName }}</li> <li>系统识别:{{ item?.complianceTypeName }}</li>
<li>{{ item?.determineDetails }},您可在企业端提交申诉材料或联系客服。</li> <li>{{ item?.determineDetails }},您可在企业端提交申诉材料或联系客服。</li>
<li>2021-11-07 03:20:15</li>
</ul> </ul>
</div>
</nz-tab> </nz-tab>
<nz-tab nzTitle="异常预警"> <nz-tab nzTitle="异常预警">
<st #st [data]="addressItems" [columns]="logColumns2" [ps]="0" [page]="{ show: false, showSize: false }"> </st> <st #st [data]="service.$api_get_order_abnormalWarning" [columns]="logColumns3"
[res]="{ reName: { list: 'data' } }" [req]="{params:{id:route.snapshot.params.id}}"
[page]="{ show: false, showSize: false }"> </st>
</nz-tab> </nz-tab>
<nz-tab nzTitle="操作日志"> <nz-tab nzTitle="操作日志">
<st #st [data]="addressItems" [columns]="logColumns2" [ps]="0" [page]="{ show: false, showSize: false }"> </st> <st #logSt [data]="service.$api_get_log_list" [columns]="operateLogColums"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: logParams ,lazyLoad:true}"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }">
<ng-template st-row="operator" let-item>
{{item?.operator}}/{{item.telephone}}
</ng-template>
</st>
</nz-tab> </nz-tab>
</nz-tabset> </nz-tabset>
</nz-card> </nz-card>
<nz-modal <nz-modal [(nzVisible)]="isVisible" nzWidth="1000px" [nzFooter]="nzModalFooter" [nzTitle]="modalTitle"
[(nzVisible)]="isVisible" (nzOnOk)="handleOK()" (nzOnCancel)="handleCancel()">
nzWidth="1000px"
[nzFooter]="nzModalFooter"
[nzTitle]="modalTitle"
(nzOnOk)="handleOK()"
(nzOnCancel)="handleCancel()"
>
<ng-container *nzModalContent> <ng-container *nzModalContent>
<div *ngIf="!modalcontent">暂无附件信息</div> <div *ngIf="!modalcontent">暂无附件信息</div>
<div [innerHTML]="modalcontent"></div> <div [innerHTML]="modalcontent"></div>
@ -281,4 +267,4 @@
<button nz-button nzType="primary" (click)="handleOK()" [disabled]="">取消</button> <button nz-button nzType="primary" (click)="handleOK()" [disabled]="">取消</button>
<button nz-button nzType="default" (click)="handleCancel()">确定 </button> <button nz-button nzType="default" (click)="handleCancel()">确定 </button>
</ng-template> </ng-template>
</nz-modal> </nz-modal>

View File

@ -4,13 +4,13 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-28 14:42:03 * @Date : 2021-12-28 14:42:03
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-06 15:12:10 * @LastEditTime : 2022-04-13 19:06:44
* @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle-detail\\vehicle-detail.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\components\\vehicle-detail\\vehicle-detail.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
import { Component, OnInit } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { STColumn } from '@delon/abc/st'; import { STColumn, STComponent } from '@delon/abc/st';
import { NzCardComponent } from 'ng-zorro-antd/card'; import { NzCardComponent } from 'ng-zorro-antd/card';
import { NzMessageService } from 'ng-zorro-antd/message'; import { NzMessageService } from 'ng-zorro-antd/message';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
@ -23,12 +23,14 @@ import { OrderManagementService } from '../../services/order-management.service'
}) })
export class OrderManagementVehicleDetailComponent implements OnInit { export class OrderManagementVehicleDetailComponent implements OnInit {
id = this.route.snapshot.params.id; id = this.route.snapshot.params.id;
@ViewChild('logSt') logSt!: STComponent;
modalcontent: any; modalcontent: any;
modalTitle:string = ''; modalTitle: string = '';
trajectory = 'car'; trajectory = 'car';
mapList: any[] = []; //地图点位数据组 mapList: any[] = []; //地图点位数据组
pois: any[] = []; pois: any[] = [];
addressItems: any[] = []; //打点地址数据组 addressItems: any[] = []; //打点地址数据组
warringList: any[] = []; //打点地址数据组
abnormalList: any[] = []; abnormalList: any[] = [];
i: any = { i: any = {
unLoadingPlaceList: [], unLoadingPlaceList: [],
@ -43,8 +45,17 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
approvalLsit: any; approvalLsit: any;
isVisible = false; isVisible = false;
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' } { title: '地点', index: 'parkAdr' }
];
logColumns3: STColumn[] = [
{ title: '时间', index: 'warningTime' },
{ title: '异常预警类型', index: 'warningTypeLabel' }
];
operateLogColums: STColumn[] = [
{ title: '内容', index: 'operationContent' },
{ title: '操作人', render: 'operator' },
{ title: '操作时间', index: 'operatorTimestamp' },
]; ];
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '款项', index: 'expenseCodeLabel' }, { title: '款项', index: 'expenseCodeLabel' },
@ -55,13 +66,14 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
{ {
title: '支付状态', title: '支付状态',
className: 'text-center', className: 'text-center',
index: 'paymentStatusLabel', index: 'paymentStatusLabel'
} }
]; ];
constructor( constructor(
public route: ActivatedRoute, public route: ActivatedRoute,
private msgSrv: NzMessageService, private msgSrv: NzMessageService,
private service: OrderManagementService, public service: OrderManagementService,
private router: Router, private router: Router,
private modal: NzModalService private modal: NzModalService
) {} ) {}
@ -70,23 +82,29 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
this.initData(); this.initData();
this.getTrajectory(); this.getTrajectory();
} }
get logParams() {
return { operateObject: this.i?.billCode, operateTypeList: ['3','8'] }
}
initData() { initData() {
this.service.request(this.service.$api_get_getWholeBillDetail, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_get_getWholeBillDetail, { id: this.id }).subscribe(res => {
if (res) { if (res) {
this.i = res; this.i = res;
this.pois = [ this.pois = [
{ {
markerLabel: '', markerLabel: '',
color: 'blue', color: 'blue',
position: [res.startingPoint.longitude, res.startingPoint.latitude], position: [res.startingPoint.longitude, res.startingPoint.latitude],
title: res.startingPoint.detailedAddress title: `发货地:${res.startingPoint.province}${res.startingPoint.city}${res.startingPoint.area || ''}${
res.startingPoint.detailedAddress
}`,
time: '计划出发时间:' + res.loadPlanTime
}, },
{ {
markerLabel: '卸', markerLabel: '卸',
color: 'red', color: 'red',
position: [res.endPoint.longitude, res.endPoint.latitude], position: [res.endPoint.longitude, res.endPoint.latitude],
title: res.endPoint.detailedAddress title: `卸货地:${res.endPoint.province}${res.endPoint.city}${res.endPoint.area}${res.endPoint.detailedAddress}`,
time: '计划卸货时间:' + res.unloadPlanTime
} }
]; ];
this.billExpenses = this.i?.billExpenseDetails?.filter( this.billExpenses = this.i?.billExpenseDetails?.filter(
@ -97,17 +115,21 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
}); });
this.service.request(this.service.$api_listBillComplianceAbnormalByBillId, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_listBillComplianceAbnormalByBillId, { id: this.id }).subscribe(res => {
if (res) { if (res) {
console.log('风险详情') console.log('风险详情');
console.log(res) console.log(res);
this.abnormalList = res this.abnormalList = res;
} }
}); });
this.service.request(this.service.$api_getAbnormalWarningByBillId, { id: this.id }).subscribe(res => { this.service.request(this.service.$api_getAbnormalWarningByBillId, { id: this.id }).subscribe(res => {
if (res) { if (res) {
console.log('异常预警') console.log('异常预警');
console.log(res) console.log(res);
this.warringList = res
} }
}); });
setTimeout(() => {
this.logSt.load(1);
});
} }
// 取消订单 // 取消订单
cancellation() { cancellation() {
@ -132,15 +154,15 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
this.router.navigate(['order-management/vehicle-detailChange', this.id]); this.router.navigate(['order-management/vehicle-detailChange', this.id]);
} }
agreement(value: any) { agreement(value: any) {
if(value ==='1'){ if (value === '1') {
this.modalTitle = '附件信息'; // this.modalTitle = '附件信息';
this.modalcontent = this.i?.contractContent?.contractContent; // this.modalcontent = this.i?.contractContent?.contractContent;
this.service.openURL(this.i?.contractContent?.contractFilePath);
}else if(value === '2'){ } else if (value === '2') {
this.modalTitle = '补充协议'; this.modalTitle = '补充协议';
this.modalcontent = this.i?.supplementContent?.contractContent; this.modalcontent = this.i?.supplementContent?.contractContent;
this.isVisible = true;
} }
this.isVisible = true;
} }
handleCancel() { handleCancel() {
this.isVisible = false; this.isVisible = false;
@ -163,16 +185,16 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
let list: any[] = []; let list: any[] = [];
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: `${item.spd}km/h`, name: `${item.spd}`,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))], lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res.cityArray; this.addressItems = res.parkArray;
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -188,7 +210,8 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
@ -210,6 +233,9 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
} }
} }
getLocalTime(time: any) { getLocalTime(time: any) {
if (!time) {
return '';
}
return format(new Date(parseInt(time)), 'yyyy-MM-dd HH:mm:ss'); return format(new Date(parseInt(time)), 'yyyy-MM-dd HH:mm:ss');
} }
} }

View File

@ -38,8 +38,8 @@ export class OneCarOrderViewtrackComponent implements OnInit {
mapList:any[] = []; //地图点位数据组 mapList:any[] = []; //地图点位数据组
addressItems: any[] = []; //打点地址数据组 addressItems: any[] = []; //打点地址数据组
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' }, { title: '地点', index: 'parkAdr' },
]; ];
constructor( constructor(
private modalRef: NzModalRef, private modalRef: NzModalRef,
@ -65,14 +65,15 @@ export class OneCarOrderViewtrackComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res.cityArray; this.addressItems = res.parkAdr;
if(this.addressItems && this.addressItems.length > 0){ if(this.addressItems && this.addressItems.length > 0){
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -88,7 +89,8 @@ export class OneCarOrderViewtrackComponent implements OnInit {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-03 15:31:52 * @Date : 2021-12-03 15:31:52
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-04-11 22:29:34 * @LastEditTime : 2022-04-13 18:52:24
* @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
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -52,7 +52,7 @@ export class OrderManagementService extends ShipperBaseService {
// 订单申请撤销 // 订单申请撤销
$api_get_revokeChangeRecord = `/api/sdc/billFreightChangeApplication/revokeChangeRecord`; $api_get_revokeChangeRecord = `/api/sdc/billFreightChangeApplication/revokeChangeRecord`;
// 运费变更申请-整车 // 运费变更申请-整车
$api_get_insertFreightChangeWhole = `/api/sdc/billFreightChangeApplication/insertFreightChangeWhole`; $api_get_insertFreightChangeWhole = `/api/sdc/billFreightChangeApplication/insertOperateFreightChangeWhole`;
// 取消订单 // 取消订单
$api_get_cancelAnOrder = `/api/sdc/billOperate/cancelAnOrder`; $api_get_cancelAnOrder = `/api/sdc/billOperate/cancelAnOrder`;
// 批量签收整车订单 // 批量签收整车订单
@ -92,7 +92,7 @@ export class OrderManagementService extends ShipperBaseService {
//运费变更申请计算费用-整车 //运费变更申请计算费用-整车
$api_getWholeSurchargeDetail = `/api/sdc/billFreightChangeApplication/getWholeSurchargeDetail`; $api_getWholeSurchargeDetail = `/api/sdc/billFreightChangeApplication/getWholeSurchargeDetail`;
//运费变更申请-大宗 //运费变更申请-大宗
$api_change_bulk = `/api/sdc/billFreightChangeApplication/insertFreightChangeBulk`; $api_change_bulk = `/api/sdc/billFreightChangeApplication/insertOperateFreightChangeBulk`;
// 删除装卸货信息 // 删除装卸货信息
$api_delete_Wholedeletebatch = `/api/sdc/unLoadingPlace/deletebatch`; $api_delete_Wholedeletebatch = `/api/sdc/unLoadingPlace/deletebatch`;
// 修改-大宗订单 // 修改-大宗订单
@ -188,7 +188,7 @@ export class OrderManagementService extends ShipperBaseService {
// 查询异常预警表 // 查询异常预警表
$api_get_abnormalWarning = `/api/sdc/abnormalWarning/list/page`; $api_get_abnormalWarning = `/api/sdc/abnormalWarning/list/page`;
$api_get_order_abnormalWarning = `/api/sdc/abnormalWarning/getAbnormalWarningByBillId`;
// 异步导出运营后台大宗订单列表 // 异步导出运营后台大宗订单列表
$api_get_asyncExportBulkList = `/api/sdc/billOperate/asyncExportBulkList`; $api_get_asyncExportBulkList = `/api/sdc/billOperate/asyncExportBulkList`;
@ -197,13 +197,15 @@ export class OrderManagementService extends ShipperBaseService {
// 异步导出风险单导出 // 异步导出风险单导出
$api_get_asyncExportRiskBillList = `/api/sdc/billRiskOperate/asyncExportRiskBillList`; $api_get_asyncExportRiskBillList = `/api/sdc/billRiskOperate/asyncExportRiskBillList`;
// 异步导出合规抽查导出 // 异步导出合规抽查导出
$api_get_asyncExportSpotCheckList= `/api/sdc/BillComplianceSpotCheck/asyncExportSpotCheckList`; $api_get_asyncExportSpotCheckList = `/api/sdc/BillComplianceSpotCheck/asyncExportSpotCheckList`;
// 异步导出单据审核导出 // 异步导出单据审核导出
$api_get_asyncExportExamineBillList= `/api/sdc/billExamine/asyncExportExamineBillList`; $api_get_asyncExportExamineBillList = `/api/sdc/billExamine/asyncExportExamineBillList`;
// 异步导出单据审核导出 // 异步导出单据审核导出
$api_abnormalWarning_asyncExport= `/api/sdc/abnormalWarning/asyncExport`; $api_abnormalWarning_asyncExport = `/api/sdc/abnormalWarning/asyncExport`;
// 异步导出投诉管理导出 // 异步导出投诉管理导出
$api_asyncExportComplaintListDrv= `/api/sdc/complaint/operate/asyncExportComplaintListDrv`; $api_asyncExportComplaintListDrv = `/api/sdc/complaint/operate/asyncExportComplaintListDrv`;
//操作日志
public $api_get_log_list = `/api/mdc/pbc/operationLogRecords/getOperationLogRecordsList`;
/** /**
* 根据企业ID获取企业历史网络货运人 * 根据企业ID获取企业历史网络货运人
* @returns * @returns
@ -248,21 +250,22 @@ export class OrderManagementService extends ShipperBaseService {
if (!url) { if (!url) {
return; return;
} }
const uA = window.navigator.userAgent; // 判断浏览器内核 this.openURL(url);
const isIE = // const uA = window.navigator.userAgent; // 判断浏览器内核
/msie\s|trident\/|edge\//i.test(uA) && // const isIE =
!!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window); // /msie\s|trident\/|edge\//i.test(uA) &&
const objectUrl = url; // !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
const a = document.createElement('a'); // const objectUrl = url;
document.body.appendChild(a); // const a = document.createElement('a');
a.href = objectUrl; // document.body.appendChild(a);
a.download = '附件.pdf'; // a.href = objectUrl;
if (isIE) { // a.download = '附件.pdf';
// 兼容IE11无法触发下载的问题 // if (isIE) {
(navigator as any).msSaveBlob(url, a.download); // // 兼容IE11无法触发下载的问题
} else { // (navigator as any).msSaveBlob(url, a.download);
a.click(); // } else {
} // a.click();
a.remove(); // }
// a.remove();
} }
} }

View File

@ -124,7 +124,7 @@
<div nz-row> <div nz-row>
<div *ngFor="let item of i?.goodsInfoVOList" nz-col nzSpan="24"> <div *ngFor="let item of i?.goodsInfoVOList" nz-col nzSpan="24">
<div> <div>
<p class="text-warning-light mb-xs text-right">货后{{ i?.paymentDays }}天内支付运费</p> <p class="text-warning-light mb-xs text-right">货后{{ i?.paymentDays }}天内支付运费</p>
<p class="mb-xs text-right"> {{ settlementBasis[item?.settlementBasis] }}{{ rule[item?.rule] }}</p> <p class="mb-xs text-right"> {{ settlementBasis[item?.settlementBasis] }}{{ rule[item?.rule] }}</p>
</div> </div>
<nz-divider class="mb-xs mt-xs"></nz-divider> <nz-divider class="mb-xs mt-xs"></nz-divider>

View File

@ -11,52 +11,33 @@
</nz-card> </nz-card>
<nz-card> <nz-card>
<div class="card-title" <div class="card-title">装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div>
>装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div
>
<form nz-form [formGroup]="validateForm1" role="form"> <form nz-form [formGroup]="validateForm1" role="form">
<div nz-row [nzGutter]="24"> <div nz-row [nzGutter]="24">
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<div *ngFor="let data1 of startInfo; let idx = index"> <div *ngFor="let data1 of startInfo; let idx = index">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>装货地</nz-form-label> <nz-form-label nzRequired>装货地</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入装货地'"> <nz-form-control [nzErrorTip]="'请输入装货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data1.detailedAddress" (click)="openMap('start', idx)"
nz-input formControlName="loadAddress{{ idx }}" placeholder="请输入装货地" readonly="true" />
[(ngModel)]="data1.detailedAddress"
(click)="openMap('start', idx)"
formControlName="loadAddress{{ idx }}"
placeholder="请输入装货地"
readonly="true"
/>
</nz-input-group> </nz-input-group>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex ;width: 86%"> <div style="display: flex ;width: 86%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data1.appUserName" formControlName="loadName{{ idx }}" maxlength="30"
nz-input placeholder="请输入联系人姓名" />
[(ngModel)]="data1.appUserName"
formControlName="loadName{{ idx }}"
maxlength="30"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data1.contractTelephone" maxlength="11"
style="margin-left: 12px" formControlName="loadPhone{{ idx }}" placeholder="请输入联系人电话" />
nz-input
[(ngModel)]="data1.contractTelephone"
maxlength="11"
formControlName="loadPhone{{ idx }}"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -64,50 +45,32 @@
</div> </div>
<div nz-col [nzSpan]="4"> <div nz-col [nzSpan]="4">
<div style="display: flex; justify-content: center"> <div style="display: flex; justify-content: center">
<span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" <span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" nzTheme="outline"></i></span>
nzTheme="outline"></i></span>
</div> </div>
</div> </div>
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<div *ngFor="let data2 of endInfo; let idx = index"> <div *ngFor="let data2 of endInfo; let idx = index">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>卸货地</nz-form-label> <nz-form-label nzRequired>卸货地</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入卸货地'"> <nz-form-control [nzErrorTip]="'请输入卸货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data2.detailedAddress" (click)="openMap('end', idx)"
nz-input formControlName="unloadAddress{{ idx }}" placeholder="请输入卸货地" readonly="true" />
[(ngModel)]="data2.detailedAddress"
(click)="openMap('end', idx)"
formControlName="unloadAddress{{ idx }}"
placeholder="请输入卸货地"
readonly="true"
/>
</nz-input-group> </nz-input-group>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex;width: 86%"> <div style="display: flex;width: 86%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data2.appUserName" maxlength="30" formControlName="unloadName{{ idx }}"
nz-input placeholder="请输入联系人姓名" />
[(ngModel)]="data2.appUserName"
maxlength="30"
formControlName="unloadName{{ idx }}"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data2.contractTelephone"
style="margin-left: 12px" formControlName="unloadPhone{{ idx }}" maxlength="11" placeholder="请输入联系人电话" />
nz-input
[(ngModel)]="data2.contractTelephone"
formControlName="unloadPhone{{ idx }}"
maxlength="11"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -122,16 +85,26 @@
<div class="card-title">货物信息</div> <div class="card-title">货物信息</div>
<div nz-row> <div nz-row>
<div nz-col nzSpan="24"> <div nz-col nzSpan="24">
<sf #sf3 [schema]="schema3" [formData]="sf3data" [button]="'none'" [ui]="ui3"></sf> <sf #sf3 [schema]="schema3" class="sf3" [formData]="sf3data" [button]="'none'" [ui]="ui3">
<ng-template class="1" sf-template="goodsTips" let-i let-ui="ui">
<nz-alert class="goods_tips" nzType="warning" [nzMessage]="tpl" nzShowIcon></nz-alert>
</ng-template>
<ng-template #tpl>
<span style="font-size: 12px;"> 国家法规及行政命令禁限运货物不能托运
<a target="_blank" [queryParams]="{ type: 15 }" [routerLink]="['/agreement']">《禁运物品说明》</a>
</span>
</ng-template>
</sf>
<sf #sf4 [schema]="schema4" [formData]="sf4data" [button]="'none'" [ui]="ui4"> <sf #sf4 [schema]="schema4" [formData]="sf4data" [button]="'none'" [ui]="ui4">
<ng-template sf-template="freightPrice" let-i let-ui="ui"> <ng-template sf-template="freightPrice" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="addOnAfterTemplate"> <nz-input-group [nzAddOnAfter]="addOnAfterTemplate">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="请输入" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="请输入" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
<ng-template #addOnAfterTemplate> <ng-template #addOnAfterTemplate>
<nz-select [ngModel]="sf4.value.freightType" (ngModelChange)="sf4.setValue('/freightType', $event)"> <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> </nz-select>
</ng-template> </ng-template>
</ng-template> </ng-template>
@ -142,9 +115,8 @@
<nz-option nzLabel="抹除小数" nzValue="2"></nz-option> <nz-option nzLabel="抹除小数" nzValue="2"></nz-option>
<nz-option nzLabel="抹除个数" nzValue="3"></nz-option> <nz-option nzLabel="抹除个数" nzValue="3"></nz-option>
</nz-select> </nz-select>
<span style="padding: 0 12px" nz-tooltip [nzTooltipTitle]="template2" nzTooltipPlacement="bottom" <span style="padding: 0 12px" nz-tooltip [nzTooltipTitle]="template2" nzTooltipPlacement="bottom"><i nz-icon
><i nz-icon nzType="exclamation-circle" nzTheme="outline" style="color: #1890ff"></i nzType="exclamation-circle" nzTheme="outline" style="color: #1890ff"></i></span>
></span>
<ng-template #template2> <ng-template #template2>
<p>例如 付司机运费 = 重量*单价 = 999.99</p> <p>例如 付司机运费 = 重量*单价 = 999.99</p>
<p>保留小数,即 999.99</p> <p>保留小数,即 999.99</p>
@ -155,35 +127,20 @@
</ng-template> </ng-template>
<ng-template sf-template="weight" let-i let-ui="ui"> <ng-template sf-template="weight" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number <nz-input-number placeholder="总重量,必填" [ngModel]="i.value" (ngModelChange)="i.setValue($event)" [nzMin]="1"
placeholder="总重量,必填" style="width: 100%"></nz-input-number>
[ngModel]="i.value"
(ngModelChange)="i.setValue($event)"
[nzMin]="1"
style="width: 100%"
></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="volume" let-i let-ui="ui"> <ng-template sf-template="volume" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number <nz-input-number placeholder="总体积" [ngModel]="i.value" (ngModelChange)="i.setValue($event)" [nzMin]="1"
placeholder="总体积" style="width: 100%"></nz-input-number>
[ngModel]="i.value"
(ngModelChange)="i.setValue($event)"
[nzMin]="1"
style="width: 100%"
></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="number" let-i let-ui="ui"> <ng-template sf-template="number" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number <nz-input-number placeholder="总车次" [ngModel]="i.value" (ngModelChange)="i.setValue($event)" [nzMin]="1"
placeholder="总车次" style="width: 100%"></nz-input-number>
[ngModel]="i.value"
(ngModelChange)="i.setValue($event)"
[nzMin]="1"
style="width: 100%"
></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
</sf> </sf>
@ -198,15 +155,10 @@
<sf #sf7 [schema]="schema7" [formData]="sf7data" [button]="'none'" [ui]="ui7"> <sf #sf7 [schema]="schema7" [formData]="sf7data" [button]="'none'" [ui]="ui7">
<ng-template sf-template="paymentDays" let-i let-ui="ui"> <ng-template sf-template="paymentDays" let-i let-ui="ui">
<div nz-row> <div nz-row>
<div class="align-center" > <div class="align-center">
<div nz-col nzSpan="12"> <div nz-col nzSpan="12">
<nz-input-number <nz-input-number [(ngModel)]="i.value" (ngModelChange)="i.setValue($event)" [nzMin]="1" [nzMax]="30"
[(ngModel)]="i.value" [nzStep]="1"></nz-input-number>
(ngModelChange)="i.setValue($event)"
[nzMin]="1"
[nzMax]="30"
[nzStep]="1"
></nz-input-number>
</div> </div>
<div nz-col nzSpan="12"> <div nz-col nzSpan="12">
<span>&nbsp;天内支付运费</span> <span>&nbsp;天内支付运费</span>
@ -220,9 +172,12 @@
</nz-card> </nz-card>
<nz-card> <nz-card>
<div class="align-center"> <div class="align-center">
<button nz-button nzType="primary" (click)="submitConfirm('qrcode')" acl [acl-ability]="['SUPPLY-VEHICLE-PLACEORDER- QRCode']">生成二维码</button> <button nz-button nzType="primary" (click)="submitConfirm('qrcode')" acl
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('assign')" acl [acl-ability]="['SUPPLY-VEHICLE-PLACEORDER-bulkDesignate']">指派熟车</button> [acl-ability]="['SUPPLY-VEHICLE-PLACEORDER- QRCode']">生成二维码</button>
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('assign')" acl
[acl-ability]="['SUPPLY-VEHICLE-PLACEORDER-bulkDesignate']">指派熟车</button>
<!-- <button nz-button nzType="primary" (click)="choose()">取消</button> --> <!-- <button nz-button nzType="primary" (click)="choose()">取消</button> -->
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')" acl [acl-ability]="['SUPPLY-VEHICLE-PLACEORDER-bulkAnotherOrder']">司机抢单</button> <button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')" acl
[acl-ability]="['SUPPLY-VEHICLE-PLACEORDER-bulkAnotherOrder']">司机抢单</button>
</div> </div>
</nz-card> </nz-card>

View File

@ -3,10 +3,35 @@
nz-input-number { nz-input-number {
width: 100%; width: 100%;
} }
nz-date-picker { nz-date-picker {
width: 100%; width: 100%;
} }
.sf3 {
.goods_Tips_item {
.goods_tips {
width: calc(50% - 45px);
.ant-alert {
padding: 0 0 0 2px;
}
}
nz-form-item {
margin-bottom: 8px;
}
// .ant-form-item-control-input-content {
// display: flex;
// justify-content: end;
// }
}
}
} }
i { i {
cursor: pointer; cursor: pointer;
} }
@ -34,7 +59,10 @@
padding: 24px; padding: 24px;
color: #7d7d7d; color: #7d7d7d;
font-size: 30px; font-size: 30px;
:hover{color: #52acff;}
:hover {
color: #52acff;
}
} }
#container { #container {
@ -45,6 +73,7 @@
input[type='number'] { input[type='number'] {
-moz-appearance: textfield; -moz-appearance: textfield;
} }
input[type='number']::-webkit-inner-spin-button, input[type='number']::-webkit-inner-spin-button,
input[type='number']::-webkit-outer-spin-button { input[type='number']::-webkit-outer-spin-button {
margin: 0; margin: 0;

View File

@ -210,6 +210,17 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
initSF3() { initSF3() {
this.schema3 = { this.schema3 = {
properties: { properties: {
goodsTips: {
type: 'string',
title: '',
ui: {
widget: 'custom',
class: 'goods_Tips_item',
// visibleIf: {
// goodsTypeName: (value: any) => value && value === '其它'
// }
}
},
goodsTypeId: { goodsTypeId: {
type: 'string', type: 'string',
title: '货物名称', title: '货物名称',
@ -271,6 +282,9 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
errors: { required: '请填写货物名称' }, errors: { required: '请填写货物名称' },
visibleIf: { visibleIf: {
goodsTypeName: (value: any) => value && value === '其它' goodsTypeName: (value: any) => value && value === '其它'
},
blur: (value: any) => {
this.checkGoodsName();
} }
} }
} }
@ -281,6 +295,9 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
'*': { '*': {
spanLabelFixed: 90, spanLabelFixed: 90,
grid: { span: 12 } grid: { span: 12 }
},
$goodsTips: {
grid: { span: 24 }
} }
}; };
} }
@ -583,7 +600,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
} }
subStartInfo(event: any, index: number, id?: any) { subStartInfo(event: any, index: number, id?: any) {
if (id) { 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.startInfo.splice(index, 1);
this.validateForm1.removeControl(`loadAddress${index}`); this.validateForm1.removeControl(`loadAddress${index}`);
@ -611,7 +628,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
} }
subEndInfo(event: any, index: number, id?: any) { subEndInfo(event: any, index: number, id?: any) {
if (id) { 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.endInfo.splice(index, 1);
this.validateForm1.removeControl(`unloadAddress${index}`); this.validateForm1.removeControl(`unloadAddress${index}`);
@ -838,43 +855,43 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
nzContent: AmapPoiPickerComponent, nzContent: AmapPoiPickerComponent,
nzWidth: 900, nzWidth: 900,
nzOnOk: item => { nzOnOk: item => {
if(item?.poi) { if (item?.poi) {
const poi = item.poi; const poi = item.poi;
const locList = poi.location.toString().split(','); const locList = poi.location.toString().split(',');
switch (type) { switch (type) {
case 'start': case 'start':
this.startInfo[index].detailedAddress = poi.district + poi.name; this.startInfo[index].detailedAddress = poi.district + poi.name;
this.startInfo[index].longitude = locList[0]; this.startInfo[index].longitude = locList[0];
this.startInfo[index].latitude = locList[1]; this.startInfo[index].latitude = locList[1];
this.startInfo[index].province = poi.cityInfo.province; this.startInfo[index].province = poi.cityInfo.province;
this.startInfo[index].city = poi.cityInfo.city; this.startInfo[index].city = poi.cityInfo.city;
this.startInfo[index].area = poi.cityInfo.district; this.startInfo[index].area = poi.cityInfo.district;
this.startInfo[index].address = poi.name; this.startInfo[index].address = poi.name;
break; break;
case 'end': case 'end':
this.endInfo[index].detailedAddress = poi.district + poi.name; this.endInfo[index].detailedAddress = poi.district + poi.name;
this.endInfo[index].longitude = locList[0]; this.endInfo[index].longitude = locList[0];
this.endInfo[index].latitude = locList[1]; this.endInfo[index].latitude = locList[1];
this.endInfo[index].province = poi.cityInfo.province; this.endInfo[index].province = poi.cityInfo.province;
this.endInfo[index].city = poi.cityInfo.city; this.endInfo[index].city = poi.cityInfo.city;
this.endInfo[index].area = poi.cityInfo.district; this.endInfo[index].area = poi.cityInfo.district;
this.endInfo[index].address = poi.name; this.endInfo[index].address = poi.name;
break; break;
default: default:
break; break;
} }
if (this.startInfo[0]?.area && this.endInfo[0]?.area) { if (this.startInfo[0]?.area && this.endInfo[0]?.area) {
this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe((res: any) => { this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe((res: any) => {
this.totalDistance = res.distance; this.totalDistance = res.distance;
this.totalTime = res.time; this.totalTime = res.time;
}); });
}
return true
} else {
this.service.msgSrv.warning('请重新手动选择地址!')
return false
} }
return true
} else {
this.service.msgSrv.warning('请重新手动选择地址!')
return false
}
} }
}); });
} }
@ -1127,4 +1144,20 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
}; };
}); });
} }
checkGoodsName() {
const name = this.sf3.getValue('/goodsName1');
if (!name || name.trim().length === 0) {
return;
}
this.service.request(this.service.$api_checkGoodsName, name).subscribe(res => {
if (res === false) {
const modalRef = this.modalService.error({
nzTitle: '货物名称含有违禁词,请重新输入!',
});
modalRef.afterClose.subscribe(result => {
// this.sf3.setValue('/goodsName1', null);
});
}
});
}
} }

View File

@ -11,60 +11,37 @@
</nz-card> </nz-card>
<nz-card> <nz-card>
<div class="card-title" <div class="card-title">装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div>
>装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div
>
<form nz-form [formGroup]="validateForm1" role="form"> <form nz-form [formGroup]="validateForm1" role="form">
<div nz-row [nzGutter]="24"> <div nz-row [nzGutter]="24">
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<div *ngFor="let data1 of startInfo; let idx = index"> <div *ngFor="let data1 of startInfo; let idx = index">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>装货地</nz-form-label> <nz-form-label nzRequired>装货地</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入装货地'"> <nz-form-control [nzErrorTip]="'请输入装货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data1.detailedAddress" (click)="openMap('start', idx)"
nz-input formControlName="loadAddress{{ idx }}" placeholder="请输入装货地" readonly="true" />
[(ngModel)]="data1.detailedAddress"
(click)="openMap('start', idx)"
formControlName="loadAddress{{ idx }}"
placeholder="请输入装货地"
readonly="true"
/>
</nz-input-group> </nz-input-group>
<span *ngIf="idx !== 0" style="padding: 0 10px" <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline"
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
></span> <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"><i nz-icon nzType="minus-circle"
<span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
></span>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex; width: 80.7%"> <div style="display: flex; width: 80.7%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data1.appUserName" formControlName="loadName{{ idx }}"
nz-input name="loadName{{ idx }}" maxlength="30" placeholder="请输入联系人姓名" />
[(ngModel)]="data1.appUserName"
formControlName="loadName{{ idx }}"
name="loadName{{ idx }}"
maxlength="30"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data1.contractTelephone" maxlength="11"
style="margin-left: 12px" formControlName="loadPhone{{ idx }}" name="loadPhone{{ idx }}" placeholder="请输入联系人电话" />
nz-input
[(ngModel)]="data1.contractTelephone"
maxlength="11"
formControlName="loadPhone{{ idx }}"
name="loadPhone{{ idx }}"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -81,59 +58,38 @@
</div> </div>
<div nz-col [nzSpan]="4"> <div nz-col [nzSpan]="4">
<div style="display: flex; justify-content: center"> <div style="display: flex; justify-content: center">
<span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" <span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" nzTheme="outline"></i></span>
nzTheme="outline"></i></span>
</div> </div>
</div> </div>
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<div *ngFor="let data2 of endInfo; let idx = index"> <div *ngFor="let data2 of endInfo; let idx = index">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>卸货地</nz-form-label> <nz-form-label nzRequired>卸货地</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入卸货地'"> <nz-form-control [nzErrorTip]="'请输入卸货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data2.detailedAddress" (click)="openMap('end', idx)"
nz-input formControlName="unloadAddress{{ idx }}" placeholder="请输入卸货地" name="unloadAddress{{ idx }}"
[(ngModel)]="data2.detailedAddress" readonly="true" />
(click)="openMap('end', idx)"
formControlName="unloadAddress{{ idx }}"
placeholder="请输入卸货地"
name="unloadAddress{{ idx }}"
readonly="true"
/>
</nz-input-group> </nz-input-group>
<span *ngIf="idx !== 0" style="padding: 0 10px" <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline"
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subEndInfo($event, idx)"></i style="color: #d9001b" (click)="subEndInfo($event, idx)"></i></span>
></span> <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"><i nz-icon nzType="minus-circle"
<span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
></span>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex; width: 80.7%"> <div style="display: flex; width: 80.7%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data2.appUserName" maxlength="30" formControlName="unloadName{{ idx }}"
nz-input name="unloadAddress{{ idx }}" placeholder="请输入联系人姓名" />
[(ngModel)]="data2.appUserName"
maxlength="30"
formControlName="unloadName{{ idx }}"
name="unloadAddress{{ idx }}"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data2.contractTelephone"
style="margin-left: 12px" formControlName="unloadPhone{{ idx }}" name="unloadAddress{{ idx }}" maxlength="11"
nz-input placeholder="请输入联系人电话" />
[(ngModel)]="data2.contractTelephone"
formControlName="unloadPhone{{ idx }}"
name="unloadAddress{{ idx }}"
maxlength="11"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -152,24 +108,20 @@
<div nz-row [nzGutter]="24" style="margin-top: 24px"> <div nz-row [nzGutter]="24" style="margin-top: 24px">
<div nz-col nzXs="2" nzSm="4" nzMd="8" nzLg="8" nzXl="10"> <div nz-col nzXs="2" nzSm="4" nzMd="8" nzLg="8" nzXl="10">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>装货时间</nz-form-label> <nz-form-label nzRequired>装货时间</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入装货时间'"> <nz-form-control [nzErrorTip]="'请输入装货时间'">
<nz-date-picker <nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" nzFormat="yyyy-MM-dd HH:00前" formControlName="loadingTime"
[nzShowTime]="{ nzFormat: 'HH' }" [nzDisabledDate]="disabledDateStart"></nz-date-picker>
nzFormat="yyyy-MM-dd HH:00前"
formControlName="loadingTime"
[nzDisabledDate]="disabledDateStart"
></nz-date-picker>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
</div> </div>
<div nz-col nzXs="20" nzSm="16" nzMd="12" nzLg="8" nzXl="4"></div> <div nz-col nzXs="20" nzSm="16" nzMd="12" nzLg="8" nzXl="4"></div>
<div nz-col nzXs="2" nzSm="4" nzMd="8" nzLg="8" nzXl="10"> <div nz-col nzXs="2" nzSm="4" nzMd="8" nzLg="8" nzXl="10">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>卸货时间</nz-form-label> <nz-form-label nzRequired>卸货时间</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入卸货时间'"> <nz-form-control [nzErrorTip]="'请输入卸货时间'">
<nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" <nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" nzFormat="yyyy-MM-dd HH:00前"
nzFormat="yyyy-MM-dd HH:00前" formControlName="unloadingTime"></nz-date-picker> formControlName="unloadingTime"></nz-date-picker>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
</div> </div>
@ -182,31 +134,40 @@
<div class="card-title">货物信息</div> <div class="card-title">货物信息</div>
<div nz-row> <div nz-row>
<div nz-col nzSpan="16"> <div nz-col nzSpan="16">
<sf #sf3 [schema]="schema3" [button]="'none'" [ui]="ui3" [formData]="sf3data"></sf> <sf #sf3 [schema]="schema3" class="sf3" [button]="'none'" [ui]="ui3" [formData]="sf3data">
<ng-template class="1" sf-template="goodsTips" let-i let-ui="ui">
<nz-alert class="goods_tips" nzType="warning" [nzMessage]="tpl" nzShowIcon></nz-alert>
</ng-template>
<ng-template #tpl>
<span style="font-size: 12px;"> 国家法规及行政命令禁限运货物不能托运
<a target="_blank" [queryParams]="{ type: 15 }" [routerLink]="['/agreement']">《禁运物品说明》</a>
</span>
</ng-template>
</sf>
</div> </div>
</div> </div>
<sf #sf4 [schema]="schema4" [button]="'none'" [ui]="ui4" [formData]="sf4data"> <sf #sf4 [schema]="schema4" [button]="'none'" [ui]="ui4" [formData]="sf4data">
<ng-template sf-template="weight" let-i let-ui="ui"> <ng-template sf-template="weight" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="总重量,必填" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="总重量,必填" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="volume" let-i let-ui="ui"> <ng-template sf-template="volume" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="体积" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="体积" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="number" let-i let-ui="ui"> <ng-template sf-template="number" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="件数" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="件数" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="goodsValue" let-i let-ui="ui"> <ng-template sf-template="goodsValue" let-i let-ui="ui">
<div class="align-center"> <div class="align-center">
<nz-input-number [ngModel]="i.value" [nzMin] = "0" [nzMax]="2000000" [nzStep]="0.01" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="2000000" [nzStep]="0.01"
(ngModelChange)="i.setValue($event);getInsurersPrice()" nzPlaceHolder="请输入0-2000000之间数值"> (ngModelChange)="i.setValue($event);getInsurersPrice()" nzPlaceHolder="请输入0-2000000之间数值">
</nz-input-number> </nz-input-number>
</div> </div>
@ -233,8 +194,8 @@
<ng-template sf-template="freeInsurance2" let-i let-ui="ui"> <ng-template sf-template="freeInsurance2" let-i let-ui="ui">
<nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert>
</ng-template> </ng-template>
<ng-template #template1>①香港、澳门、台湾、西藏、新疆不予承保②单次运输保额仅限200万元以内③保险详细内容及注意事项请见<a target="_blank" [queryParams]="{ type: 10 }" <ng-template #template1>①香港、澳门、台湾、西藏、新疆不予承保②单次运输保额仅限200万元以内③保险详细内容及注意事项请见<a target="_blank"
[routerLink]="['/agreement']">《保险告知函》</a></ng-template> [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《保险告知函》</a></ng-template>
</sf> </sf>
</div> </div>
</div> </div>
@ -256,18 +217,21 @@
<div nz-col nzSpan="8"> <div nz-col nzSpan="8">
<sf #sf7 [schema]="schema7" [button]="'none'" [ui]="ui7" [formData]="sf7data"> <sf #sf7 [schema]="schema7" [button]="'none'" [ui]="ui7" [formData]="sf7data">
<ng-template sf-template="prePay" let-i let-ui="ui"> <ng-template sf-template="prePay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="toPay" let-i let-ui="ui"> <ng-template sf-template="toPay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="receiptPay" let-i let-ui="ui"> <ng-template sf-template="receiptPay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="subtotal" let-i let-ui="ui">{{ i.value | currency }}</ng-template> <ng-template sf-template="subtotal" let-i let-ui="ui">{{ i.value | currency }}</ng-template>
@ -276,14 +240,14 @@
<ng-template sf-template="total" let-i let-ui="ui">{{ i.value | currency }}</ng-template> <ng-template sf-template="total" let-i let-ui="ui">{{ i.value | currency }}</ng-template>
<ng-template sf-template="paymentDays" let-i let-ui="ui"> <ng-template sf-template="paymentDays" let-i let-ui="ui">
<div nz-row class="align-center"> <div nz-row class="align-center">
<div nz-col nzSpan="16"> <div nz-col nzSpan="16">
<nz-input-number [ngModel]="i.value" [nzMin]="1" [nzMax]="30" [nzStep]="1" <nz-input-number [ngModel]="i.value" [nzMin]="1" [nzMax]="30" [nzStep]="1"
(ngModelChange)="i.setValue($event)" nzPlaceHolder="请输入1-30" [nzPrecision]="0" (ngModelChange)="i.setValue($event)" nzPlaceHolder="请输入1-30" [nzPrecision]="0"
[nzPrecisionMode]="'cut'"></nz-input-number> [nzPrecisionMode]="'cut'"></nz-input-number>
</div> </div>
<div nz-col nzSpan="8"> <div nz-col nzSpan="8">
<span>&nbsp;天内支付运费</span> <span>&nbsp;天内支付运费</span>
</div> </div>
</div> </div>
</ng-template> </ng-template>
</sf> </sf>
@ -293,12 +257,12 @@
<nz-card> <nz-card>
<div class="align-center"> <div class="align-center">
<button nz-button nzType="primary" *ngIf="this.PageStatus == '整车修改'" (click)="goBack()">取消</button> <button nz-button nzType="primary" *ngIf="this.PageStatus == '整车修改'" (click)="goBack()">取消</button>
<button *ngIf="this.PageStatus == '整车修改'" nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm()" <button *ngIf="this.PageStatus == '整车修改'" nz-button nzType="primary" style="margin-left: 48px"
acl [acl-ability]="['SUPPLY-VEHICLE-AMEND-submitChange']">提交修改</button (click)="submitConfirm()" acl [acl-ability]="['SUPPLY-VEHICLE-AMEND-submitChange']">提交修改</button>
> <button nz-button nzType="primary" *ngIf="this.PageStatus == '整车下一单'" (click)="submitConfirm('assign')" acl
<button nz-button nzType="primary" *ngIf="this.PageStatus == '整车下一单'" (click)="submitConfirm('assign')" acl [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleDesignate']">指派熟车</button> [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleDesignate']">指派熟车</button>
<button *ngIf="this.PageStatus == '整车下一单'" nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')" <button *ngIf="this.PageStatus == '整车下一单'" nz-button nzType="primary" style="margin-left: 48px"
acl [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleAnotherOrder']">司机抢单</button (click)="submitConfirm('publish')" acl
> [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleAnotherOrder']">司机抢单</button>
</div> </div>
</nz-card> </nz-card>

View File

@ -3,10 +3,35 @@
nz-input-number { nz-input-number {
width: 100%; width: 100%;
} }
nz-date-picker { nz-date-picker {
width: 94.3%; width: 94.3%;
} }
.sf3 {
.goods_Tips_item {
.goods_tips {
width: calc(50% - 45px);
.ant-alert {
padding: 0 0 0 2px;
}
}
nz-form-item {
margin-bottom: 8px;
}
// .ant-form-item-control-input-content {
// display: flex;
// justify-content: end;
// }
}
}
} }
i { i {
cursor: pointer; cursor: pointer;
} }
@ -34,7 +59,10 @@
padding: 24px; padding: 24px;
color: #7d7d7d; color: #7d7d7d;
font-size: 30px; font-size: 30px;
:hover{color: #52acff;}
:hover {
color: #52acff;
}
} }
#container { #container {
@ -45,11 +73,13 @@
input[type='number'] { input[type='number'] {
-moz-appearance: textfield; -moz-appearance: textfield;
} }
input[type='number']::-webkit-inner-spin-button, input[type='number']::-webkit-inner-spin-button,
input[type='number']::-webkit-outer-spin-button { input[type='number']::-webkit-outer-spin-button {
margin: 0; margin: 0;
-webkit-appearance: none; -webkit-appearance: none;
} }
.hides { .hides {
margin-left: 10px; margin-left: 10px;
color: aqua; color: aqua;

View File

@ -262,6 +262,17 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
initSF3() { initSF3() {
this.schema3 = { this.schema3 = {
properties: { properties: {
goodsTips: {
type: 'string',
title: '',
ui: {
widget: 'custom',
class: 'goods_Tips_item',
// visibleIf: {
// goodsTypeName: (value: any) => value && value === '其它'
// }
}
},
goodsTypeId: { goodsTypeId: {
type: 'string', type: 'string',
title: '货物名称', title: '货物名称',
@ -323,6 +334,9 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
errors: { required: '请填写货物名称' }, errors: { required: '请填写货物名称' },
visibleIf: { visibleIf: {
goodsTypeName: (value: any) => value && value === '其它' goodsTypeName: (value: any) => value && value === '其它'
},
blur: (value: any) => {
this.checkGoodsName();
} }
} }
} }
@ -333,6 +347,9 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
'*': { '*': {
spanLabelFixed: 90, spanLabelFixed: 90,
grid: { span: 12 } grid: { span: 12 }
},
$goodsTips: {
grid: { span: 24 }
} }
}; };
} }
@ -465,10 +482,10 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
) )
}, },
change: (tag: any, org: any) => { change: (tag: any, org: any) => {
if(tag === '3'){ if (tag === '3') {
this.sf5.setValue('/insurancePremium', null); this.sf5.setValue('/insurancePremium', null);
this.sf5.setValue('/insuranceRate', null); this.sf5.setValue('/insuranceRate', null);
}else { } else {
this.getInsurersPrice(tag); this.getInsurersPrice(tag);
} }
} }
@ -481,7 +498,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
ui: { ui: {
widget: 'custom', widget: 'custom',
visibleIf: { insuranceType: (value: string) => value === '0' } visibleIf: { insuranceType: (value: string) => value === '0' }
} , },
}, },
type2: { type2: {
type: 'string', type: 'string',
@ -494,7 +511,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
insurancePremium: { insurancePremium: {
type: 'string', type: 'string',
title: '服务包费用', title: '服务包费用',
readOnly:true, readOnly: true,
ui: { ui: {
visibleIf: { insuranceType: (value: string) => value !== '3' } visibleIf: { insuranceType: (value: string) => value !== '3' }
} }
@ -523,7 +540,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
} }
}, },
}, },
required: [ 'insurancePremium'] required: ['insurancePremium']
}; };
this.ui5 = { this.ui5 = {
'*': { '*': {
@ -733,7 +750,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
this.service this.service
.request( .request(
this.service.$api_getAdditionalRate + this.service.$api_getAdditionalRate +
`?shipperId=${this?.sf1?.value?.shipperAppUserId || ''}&enterpriseInfoId=${items}&resourcetype='1'` `?shipperId=${this?.sf1?.value?.shipperAppUserId || ''}&enterpriseInfoId=${items}&resourcetype='1'`
) )
.subscribe(res => { .subscribe(res => {
if (res) { if (res) {
@ -986,9 +1003,9 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
]; ];
// 运费信息 // 运费信息
const expenseList = [ const expenseList = [
{ expenseCode: 'PRE', expenseName: '预付', price: this.sf7.value.prePay || 0, id: this.sf7data?.prePayId || '' ,resourceId: this.sf7data?.PREresourceId || '' }, { expenseCode: 'PRE', expenseName: '预付', price: this.sf7.value.prePay || 0, id: this.sf7data?.prePayId || '', resourceId: this.sf7data?.PREresourceId || '' },
{ expenseCode: 'RECE', expenseName: '到付', price: this.sf7.value.toPay || 0, id: this.sf7data?.toPayId || '' ,resourceId: this.sf7data?.RECEresourceId || ''}, { expenseCode: 'RECE', expenseName: '到付', price: this.sf7.value.toPay || 0, id: this.sf7data?.toPayId || '', resourceId: this.sf7data?.RECEresourceId || '' },
{ expenseCode: 'BACK', expenseName: '回单付', price: this.sf7.value.receiptPay || 0, id: this.sf7data?.receiptPayId || '' ,resourceId: this.sf7data?.BACKresourceId || ''} { expenseCode: 'BACK', expenseName: '回单付', price: this.sf7.value.receiptPay || 0, id: this.sf7data?.receiptPayId || '', resourceId: this.sf7data?.BACKresourceId || '' }
]; ];
// 从“再下一单”过来将所有的子参数内的id都删除 // 从“再下一单”过来将所有的子参数内的id都删除
if (this.PageStatus === '整车下一单') { if (this.PageStatus === '整车下一单') {
@ -1017,8 +1034,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
paymentDays: this.sf7.value.paymentDays, paymentDays: this.sf7.value.paymentDays,
estimatedKilometers: this.totalDistance, estimatedKilometers: this.totalDistance,
estimatedTravelTime: this.totalTime, estimatedTravelTime: this.totalTime,
subtotal :this.sf7.value.subtotal, subtotal: this.sf7.value.subtotal,
total:this.sf7.value.total, total: this.sf7.value.total,
insurancePackagedGoods: this.sf4.value.insurancePackagedGoods, insurancePackagedGoods: this.sf4.value.insurancePackagedGoods,
goodsValue: this.sf4.value.goodsValue goodsValue: this.sf4.value.goodsValue
}; };
@ -1081,7 +1098,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
nzWidth: 900, nzWidth: 900,
nzOnOk: item => { nzOnOk: item => {
console.log(item); console.log(item);
if(item?.poi) { if (item?.poi) {
const poi = item.poi; const poi = item.poi;
const locList = poi.pois; const locList = poi.pois;
switch (type) { switch (type) {
@ -1106,7 +1123,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
default: default:
break; break;
} }
if (this.startInfo[0]?.area && this.endInfo[0]?.area) { if (this.startInfo[0]?.area && this.endInfo[0]?.area) {
this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe((res: any) => { this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe((res: any) => {
this.totalDistance = res.distance; this.totalDistance = res.distance;
@ -1114,10 +1131,10 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
this.getInsurersPrice(); // 计算保费金额 this.getInsurersPrice(); // 计算保费金额
}); });
} }
return true return true
} else { } else {
this.service.msgSrv.warning('请重新手动选择地址!') this.service.msgSrv.warning('请重新手动选择地址!')
return false return false
} }
} }
}); });
@ -1155,7 +1172,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
this.totalDistance = res?.estimatedKilometers; this.totalDistance = res?.estimatedKilometers;
this.totalTime = res?.estimatedTravelTime; this.totalTime = res?.estimatedTravelTime;
this.sf1data = { this.sf1data = {
resourceCode:res?.resourceCode || '', resourceCode: res?.resourceCode || '',
enterpriseInfoName: res?.enterpriseInfoName, enterpriseInfoName: res?.enterpriseInfoName,
enterpriseInfoId: res?.enterpriseInfoId, enterpriseInfoId: res?.enterpriseInfoId,
dispatchPhone: res?.dispatchPhone, dispatchPhone: res?.dispatchPhone,
@ -1423,7 +1440,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
// 计算保价费金额 // 计算保价费金额
getInsurersPrice(insuranceType = this.sf5.value.insuranceType) { getInsurersPrice(insuranceType = this.sf5.value.insuranceType) {
console.log(this.totalDistance); console.log(this.totalDistance);
if (insuranceType !== '3' && this.totalDistance > 0) { if (insuranceType !== '3' && this.totalDistance > 0) {
const params = { const params = {
insuranceType, insuranceType,
goodsValue: this.sf4.value.goodsValue, goodsValue: this.sf4.value.goodsValue,
@ -1440,14 +1457,31 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
}); });
} }
} }
// 运费信息价格变更 // 运费信息价格变更
priceChange(event:any, i:any){ priceChange(event: any, i: any) {
i.setValue(event); i.setValue(event);
if(event>=99999){ if (event >= 99999) {
this.modalService.warning({ this.modalService.warning({
nzTitle: '可输入的最大金额为99999元', nzTitle: '可输入的最大金额为99999元',
});
}
this.payChange()
}
checkGoodsName() {
const name = this.sf3.getValue('/goodsName1');
if (!name || name.trim().length === 0) {
return;
}
this.service.request(this.service.$api_checkGoodsName, name).subscribe(res => {
if (res === false) {
const modalRef = this.modalService.error({
nzTitle: '货物名称含有违禁词,请重新输入!',
});
modalRef.afterClose.subscribe(result => {
// this.sf3.setValue('/goodsName1', null);
}); });
} }
this.payChange() });
} }
} }

View File

@ -7,15 +7,13 @@
</page-header-wrapper> </page-header-wrapper>
<nz-card> <nz-card>
<div class="card-title">货源单设置</div> <div class="card-title">货源单设置</div>
<sf #sf1 [schema]="schema1" [button]="'none'" [ui]="ui1" [formData]="sf1data"> <sf #sf1 [schema]="schema1" [button]="'none'" [ui]="ui1" [formData]="sf1data">
<ng-template sf-template="enterpriseInfoName" let-i let-ui="ui"> {{ i.value }} </ng-template> <ng-template sf-template="enterpriseInfoName" let-i let-ui="ui"> {{ i.value }} </ng-template>
</sf> </sf>
</nz-card> </nz-card>
<nz-card> <nz-card>
<div class="card-title" <div class="card-title">装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div>
>装卸货信息<span class="tip-font">预计公里数:{{ totalDistance }}km预计行程耗时{{ totalTime }}小时</span></div
>
<form nz-form [formGroup]="validateForm1" role="form"> <form nz-form [formGroup]="validateForm1" role="form">
<div nz-row [nzGutter]="24"> <div nz-row [nzGutter]="24">
@ -26,47 +24,26 @@
<nz-form-control [nzErrorTip]="'请输入装货地'"> <nz-form-control [nzErrorTip]="'请输入装货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data1.detailedAddress" (click)="openMap('start', idx)"
nz-input formControlName="loadAddress{{ idx }}" placeholder="请输入装货地" readonly="true" />
[(ngModel)]="data1.detailedAddress"
(click)="openMap('start', idx)"
formControlName="loadAddress{{ idx }}"
placeholder="请输入装货地"
readonly="true"
/>
</nz-input-group> </nz-input-group>
<span *ngIf="idx !== 0" style="padding: 0 10px" <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline"
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
></span> <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"><i nz-icon nzType="minus-circle"
<span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
></span>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex; width: 80.7%"> <div style="display: flex; width: 80.7%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data1.appUserName" formControlName="loadName{{ idx }}"
nz-input name="loadName{{ idx }}" maxlength="30" placeholder="请输入联系人姓名" />
[(ngModel)]="data1.appUserName"
formControlName="loadName{{ idx }}"
name="loadName{{ idx }}"
maxlength="30"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data1.contractTelephone" maxlength="11"
style="margin-left: 12px" formControlName="loadPhone{{ idx }}" name="loadPhone{{ idx }}" placeholder="请输入联系人电话" />
nz-input
[(ngModel)]="data1.contractTelephone"
maxlength="11"
formControlName="loadPhone{{ idx }}"
name="loadPhone{{ idx }}"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -83,59 +60,38 @@
</div> </div>
<div nz-col [nzSpan]="4"> <div nz-col [nzSpan]="4">
<div style="display: flex; justify-content: center"> <div style="display: flex; justify-content: center">
<span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" <span class="swap-icon" (click)="swapAddress()"><i nz-icon nzType="swap" nzTheme="outline"></i></span>
nzTheme="outline"></i></span>
</div> </div>
</div> </div>
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<div *ngFor="let data2 of endInfo; let idx = index"> <div *ngFor="let data2 of endInfo; let idx = index">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>卸货地</nz-form-label> <nz-form-label nzRequired>卸货地</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入卸货地'"> <nz-form-control [nzErrorTip]="'请输入卸货地'">
<div class="align-center"> <div class="align-center">
<nz-input-group [nzSuffix]="endInconTemp1"> <nz-input-group [nzSuffix]="endInconTemp1">
<input <input nz-input [(ngModel)]="data2.detailedAddress" (click)="openMap('end', idx)"
nz-input formControlName="unloadAddress{{ idx }}" placeholder="请输入卸货地" name="unloadAddress{{ idx }}"
[(ngModel)]="data2.detailedAddress" readonly="true" />
(click)="openMap('end', idx)"
formControlName="unloadAddress{{ idx }}"
placeholder="请输入卸货地"
name="unloadAddress{{ idx }}"
readonly="true"
/>
</nz-input-group> </nz-input-group>
<span *ngIf="idx !== 0" style="padding: 0 10px" <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline"
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subEndInfo($event, idx)"></i style="color: #d9001b" (click)="subEndInfo($event, idx)"></i></span>
></span> <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"><i nz-icon nzType="minus-circle"
<span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i></span>
><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
></span>
</div> </div>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>联系人</nz-form-label> <nz-form-label nzRequired>联系人</nz-form-label>
<div style="display: flex; width: 80.7%"> <div style="display: flex; width: 80.7%">
<nz-form-control [nzErrorTip]="'请输入联系人姓名'"> <nz-form-control [nzErrorTip]="'请输入联系人姓名'">
<input <input nz-input [(ngModel)]="data2.appUserName" maxlength="30" formControlName="unloadName{{ idx }}"
nz-input name="unloadAddress{{ idx }}" placeholder="请输入联系人姓名" />
[(ngModel)]="data2.appUserName"
maxlength="30"
formControlName="unloadName{{ idx }}"
name="unloadAddress{{ idx }}"
placeholder="请输入联系人姓名"
/>
</nz-form-control> </nz-form-control>
<nz-form-control [nzErrorTip]="'请输入联系人电话'"> <nz-form-control [nzErrorTip]="'请输入联系人电话'">
<input <input style="margin-left: 12px" nz-input [(ngModel)]="data2.contractTelephone"
style="margin-left: 12px" formControlName="unloadPhone{{ idx }}" name="unloadAddress{{ idx }}" maxlength="11"
nz-input placeholder="请输入联系人电话" />
[(ngModel)]="data2.contractTelephone"
formControlName="unloadPhone{{ idx }}"
name="unloadAddress{{ idx }}"
maxlength="11"
placeholder="请输入联系人电话"
/>
</nz-form-control> </nz-form-control>
</div> </div>
</nz-form-item> </nz-form-item>
@ -156,22 +112,18 @@
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>装货时间</nz-form-label> <nz-form-label nzRequired>装货时间</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入装货时间'"> <nz-form-control [nzErrorTip]="'请输入装货时间'">
<nz-date-picker <nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" nzFormat="yyyy-MM-dd HH:00前" formControlName="loadingTime"
[nzShowTime]="{ nzFormat: 'HH' }" [nzDisabledDate]="disabledDateStart"></nz-date-picker>
nzFormat="yyyy-MM-dd HH:00前"
formControlName="loadingTime"
[nzDisabledDate]="disabledDateStart"
></nz-date-picker>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
</div> </div>
<div nz-col [nzSpan]="4"></div> <div nz-col [nzSpan]="4"></div>
<div nz-col [nzSpan]="10"> <div nz-col [nzSpan]="10">
<nz-form-item> <nz-form-item>
<nz-form-label nzRequired>卸货时间</nz-form-label> <nz-form-label nzRequired>卸货时间</nz-form-label>
<nz-form-control [nzErrorTip]="'请输入卸货时间'"> <nz-form-control [nzErrorTip]="'请输入卸货时间'">
<nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" <nz-date-picker [nzShowTime]="{ nzFormat: 'HH' }" nzFormat="yyyy-MM-dd HH:00前"
nzFormat="yyyy-MM-dd HH:00前" formControlName="unloadingTime"></nz-date-picker> formControlName="unloadingTime"></nz-date-picker>
</nz-form-control> </nz-form-control>
</nz-form-item> </nz-form-item>
</div> </div>
@ -184,31 +136,40 @@
<div class="card-title">货物信息</div> <div class="card-title">货物信息</div>
<div nz-row> <div nz-row>
<div nz-col nzSpan="16"> <div nz-col nzSpan="16">
<sf #sf3 [schema]="schema3" [button]="'none'" [ui]="ui3" [formData]="sf3data"></sf> <sf #sf3 class="sf3" [schema]="schema3" [button]="'none'" [ui]="ui3" [formData]="sf3data">
<ng-template class="1" sf-template="goodsTips" let-i let-ui="ui">
<nz-alert class="goods_tips" nzType="warning" [nzMessage]="tpl" nzShowIcon></nz-alert>
</ng-template>
<ng-template #tpl>
<span style="font-size: 12px;"> 国家法规及行政命令禁限运货物不能托运
<a target="_blank" [queryParams]="{ type: 15 }" [routerLink]="['/agreement']">《禁运物品说明》</a>
</span>
</ng-template>
</sf>
</div> </div>
</div> </div>
<sf #sf4 [schema]="schema4" [button]="'none'" [ui]="ui4" [formData]="sf4data"> <sf #sf4 [schema]="schema4" [button]="'none'" [ui]="ui4" [formData]="sf4data">
<ng-template sf-template="weight" let-i let-ui="ui"> <ng-template sf-template="weight" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="总重量,必填" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="总重量,必填" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="volume" let-i let-ui="ui"> <ng-template sf-template="volume" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="体积" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="体积" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="number" let-i let-ui="ui"> <ng-template sf-template="number" let-i let-ui="ui">
<nz-input-group [nzAddOnAfter]="''"> <nz-input-group [nzAddOnAfter]="''">
<nz-input-number [nzMax]="99999" [nzMin] ="0" nzPlaceHolder="件数" type="number" [ngModel]="i.value" <nz-input-number [nzMax]="99999" [nzMin]="0" nzPlaceHolder="件数" type="number" [ngModel]="i.value"
(ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number> (ngModelChange)="i.setValue($event)" [nzPrecision]="2" style="width: 100%;"></nz-input-number>
</nz-input-group> </nz-input-group>
</ng-template> </ng-template>
<ng-template sf-template="goodsValue" let-i let-ui="ui"> <ng-template sf-template="goodsValue" let-i let-ui="ui">
<div class="align-center"> <div class="align-center">
<nz-input-number [ngModel]="i.value" [nzMin] = "0" [nzMax]="2000000" [nzStep]="0.01" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="2000000" [nzStep]="0.01"
(ngModelChange)="i.setValue($event);getInsurersPrice()" nzPlaceHolder="请输入0-2000000之间数值"> (ngModelChange)="i.setValue($event);getInsurersPrice()" nzPlaceHolder="请输入0-2000000之间数值">
</nz-input-number> </nz-input-number>
</div> </div>
@ -235,8 +196,8 @@
<ng-template sf-template="freeInsurance2" let-i let-ui="ui"> <ng-template sf-template="freeInsurance2" let-i let-ui="ui">
<nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert>
</ng-template> </ng-template>
<ng-template #template1>①香港、澳门、台湾、西藏、新疆不予承保②单次运输保额仅限200万元以内③保险详细内容及注意事项请见<a target="_blank" [queryParams]="{ type: 10 }" <ng-template #template1>①香港、澳门、台湾、西藏、新疆不予承保②单次运输保额仅限200万元以内③保险详细内容及注意事项请见<a target="_blank"
[routerLink]="['/agreement']">《保险告知函》</a></ng-template> [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《保险告知函》</a></ng-template>
</sf> </sf>
</div> </div>
</div> </div>
@ -257,18 +218,21 @@
<div nz-col nzSpan="8"> <div nz-col nzSpan="8">
<sf #sf7 [schema]="schema7" [button]="'none'" [ui]="ui7" [formData]="sf7data"> <sf #sf7 [schema]="schema7" [button]="'none'" [ui]="ui7" [formData]="sf7data">
<ng-template sf-template="prePay" let-i let-ui="ui"> <ng-template sf-template="prePay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="toPay" let-i let-ui="ui"> <ng-template sf-template="toPay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="receiptPay" let-i let-ui="ui"> <ng-template sf-template="receiptPay" let-i let-ui="ui">
<nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2" nzPlaceHolder="请输入0-99999" <nz-input-number [ngModel]="i.value" [nzMin]="0" [nzMax]="99999" [nzStep]="0.01" [nzPrecision]="2"
(ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb" [nzParser]="parserRmb"> nzPlaceHolder="请输入0-99999" (ngModelChange)="priceChange($event,i)" [nzFormatter]="formatterRmb"
[nzParser]="parserRmb">
</nz-input-number> </nz-input-number>
</ng-template> </ng-template>
<ng-template sf-template="subtotal" let-i let-ui="ui">{{ i.value | currency }}</ng-template> <ng-template sf-template="subtotal" let-i let-ui="ui">{{ i.value | currency }}</ng-template>
@ -277,14 +241,14 @@
<ng-template sf-template="total" let-i let-ui="ui">{{ i.value | currency }}</ng-template> <ng-template sf-template="total" let-i let-ui="ui">{{ i.value | currency }}</ng-template>
<ng-template sf-template="paymentDays" let-i let-ui="ui"> <ng-template sf-template="paymentDays" let-i let-ui="ui">
<div nz-row class="align-center"> <div nz-row class="align-center">
<div nz-col nzSpan="16"> <div nz-col nzSpan="16">
<nz-input-number [ngModel]="i.value" [nzMin]="1" [nzMax]="30" [nzStep]="1" <nz-input-number [ngModel]="i.value" [nzMin]="1" [nzMax]="30" [nzStep]="1"
(ngModelChange)="i.setValue($event)" nzPlaceHolder="请输入1-30" [nzPrecision]="0" (ngModelChange)="i.setValue($event)" nzPlaceHolder="请输入1-30" [nzPrecision]="0"
[nzPrecisionMode]="'cut'"></nz-input-number> [nzPrecisionMode]="'cut'"></nz-input-number>
</div> </div>
<div nz-col nzSpan="8"> <div nz-col nzSpan="8">
<span>&nbsp;天内支付运费</span> <span>&nbsp;天内支付运费</span>
</div> </div>
</div> </div>
</ng-template> </ng-template>
</sf> </sf>
@ -293,7 +257,9 @@
</nz-card> </nz-card>
<nz-card> <nz-card>
<div class="align-center"> <div class="align-center">
<button nz-button nzType="primary" (click)="submitConfirm('assign')" acl [acl-ability]="['SUPPLY-VEHICLE-RELEASE-bulkDesignate']">指派熟车</button> <button nz-button nzType="primary" (click)="submitConfirm('assign')" acl
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')" *ngIf="type === 'add'" acl [acl-ability]="['SUPPLY-VEHICLE-RELEASE-bulkDriverOrder']">司机抢单</button> [acl-ability]="['SUPPLY-VEHICLE-RELEASE-bulkDesignate']">指派熟车</button>
<button nz-button nzType="primary" style="margin-left: 48px" (click)="submitConfirm('publish')"
*ngIf="type === 'add'" acl [acl-ability]="['SUPPLY-VEHICLE-RELEASE-bulkDriverOrder']">司机抢单</button>
</div> </div>
</nz-card> </nz-card>

View File

@ -3,10 +3,34 @@
nz-input-number { nz-input-number {
width: 100%; width: 100%;
} }
nz-date-picker { nz-date-picker {
width: 94.3%; width: 94.3%;
} }
.sf3 {
.goods_Tips_item {
.goods_tips {
width: calc(50% - 45px);
.ant-alert {
padding: 0 0 0 2px;
}
}
nz-form-item {
margin-bottom: 8px;
}
// .ant-form-item-control-input-content {
// display: flex;
// justify-content: end;
// }
}
}
} }
i { i {
cursor: pointer; cursor: pointer;
} }
@ -34,7 +58,10 @@
padding: 24px; padding: 24px;
color: #7d7d7d; color: #7d7d7d;
font-size: 30px; font-size: 30px;
:hover{color: #52acff;}
:hover {
color: #52acff;
}
} }
#container { #container {
@ -45,6 +72,7 @@
input[type='number'] { input[type='number'] {
-moz-appearance: textfield; -moz-appearance: textfield;
} }
input[type='number']::-webkit-inner-spin-button, input[type='number']::-webkit-inner-spin-button,
input[type='number']::-webkit-outer-spin-button { input[type='number']::-webkit-outer-spin-button {
margin: 0; margin: 0;

View File

@ -237,6 +237,17 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
initSF3() { initSF3() {
this.schema3 = { this.schema3 = {
properties: { properties: {
goodsTips: {
type: 'string',
title: '',
ui: {
widget: 'custom',
class: 'goods_Tips_item',
// visibleIf: {
// goodsTypeName: (value: any) => value && value === '其它'
// }
}
},
goodsTypeId: { goodsTypeId: {
type: 'string', type: 'string',
title: '货物名称', title: '货物名称',
@ -298,6 +309,9 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
errors: { required: '请填写货物名称' }, errors: { required: '请填写货物名称' },
visibleIf: { visibleIf: {
goodsTypeName: (value: any) => value && value === '其它' goodsTypeName: (value: any) => value && value === '其它'
},
blur: (value: any) => {
this.checkGoodsName();
} }
} }
} }
@ -308,6 +322,9 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
'*': { '*': {
spanLabelFixed: 115, spanLabelFixed: 115,
grid: { span: 12 } grid: { span: 12 }
},
$goodsTips: {
grid: { span: 24 }
} }
}; };
} }
@ -436,13 +453,13 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
map((res: any) => { map((res: any) => {
return [...res]; return [...res];
}) })
) );
}, },
change: (tag: any, org: any) => { change: (tag: any, org: any) => {
if(tag === '3'){ if (tag === '3') {
this.sf5.setValue('/insurancePremium', null); this.sf5.setValue('/insurancePremium', null);
this.sf5.setValue('/insuranceRate', null); this.sf5.setValue('/insuranceRate', null);
}else { } else {
this.getInsurersPrice(tag); this.getInsurersPrice(tag);
} }
} }
@ -455,7 +472,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
ui: { ui: {
widget: 'custom', widget: 'custom',
visibleIf: { insuranceType: (value: string) => value === '0' } visibleIf: { insuranceType: (value: string) => value === '0' }
} , }
}, },
type2: { type2: {
type: 'string', type: 'string',
@ -468,7 +485,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
insurancePremium: { insurancePremium: {
type: 'string', type: 'string',
title: '服务包费用', title: '服务包费用',
readOnly:true, readOnly: true,
ui: { ui: {
visibleIf: { insuranceType: (value: string) => value !== '3' } visibleIf: { insuranceType: (value: string) => value !== '3' }
} }
@ -495,9 +512,9 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
widget: 'custom', widget: 'custom',
visibleIf: { insuranceType: (value: string) => value === '1' } visibleIf: { insuranceType: (value: string) => value === '1' }
} }
}, }
}, },
required: [ 'insurancePremium'] required: ['insurancePremium']
}; };
this.ui5 = { this.ui5 = {
'*': { '*': {
@ -562,8 +579,12 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
receiptUserPhone: { receiptUserPhone: {
type: 'string', type: 'string',
title: '联系电话', title: '联系电话',
format: 'mobile',
maxLength: 11, maxLength: 11,
ui: { ui: {
errors: {
format: '请输入正确联系电话格式'
},
visibleIf: { visibleIf: {
receiptType: value => value === '2' receiptType: value => value === '2'
} }
@ -741,9 +762,8 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
this.service this.service
.request( .request(
this.service.$api_getAdditionalRate + this.service.$api_getAdditionalRate +
`?shipperId=${this?.sf1.value?.shipperAppUserId || ''}&enterpriseInfoId=${ `?shipperId=${this?.sf1.value?.shipperAppUserId || ''}&enterpriseInfoId=${this?.sf1.value?.enterpriseInfoName || ''
this?.sf1.value?.enterpriseInfoName || '' }&resourcetype='1'`
}&resourcetype='1'`
) )
.subscribe(res => { .subscribe(res => {
if (res) { if (res) {
@ -955,8 +975,8 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
...this.sf6.value, ...this.sf6.value,
expenseDTOList: expenseList, expenseDTOList: expenseList,
paymentDays: this.sf7.value.paymentDays, paymentDays: this.sf7.value.paymentDays,
subtotal :this.sf7.value.subtotal, subtotal: this.sf7.value.subtotal,
total:this.sf7.value.total, total: this.sf7.value.total,
estimatedKilometers: this.totalDistance, estimatedKilometers: this.totalDistance,
estimatedTravelTime: this.totalTime, estimatedTravelTime: this.totalTime,
insurancePackagedGoods: this.sf4.value.insurancePackagedGoods, insurancePackagedGoods: this.sf4.value.insurancePackagedGoods,
@ -999,42 +1019,42 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
nzContent: AmapPoiPickerComponent, nzContent: AmapPoiPickerComponent,
nzWidth: 900, nzWidth: 900,
nzOnOk: item => { nzOnOk: item => {
if(item?.poi) { if (item?.poi) {
const poi = item.poi; const poi = item.poi;
const locList = poi.pois; const locList = poi.pois;
switch (type) { switch (type) {
case 'start': case 'start':
this.startInfo[index].detailedAddress = poi.formattedAddress; this.startInfo[index].detailedAddress = poi.formattedAddress;
this.startInfo[index].longitude = locList[0]; this.startInfo[index].longitude = locList[0];
this.startInfo[index].latitude = locList[1]; this.startInfo[index].latitude = locList[1];
this.startInfo[index].province = poi.addressComponent.province; this.startInfo[index].province = poi.addressComponent.province;
this.startInfo[index].city = poi.addressComponent.city; this.startInfo[index].city = poi.addressComponent.city;
this.startInfo[index].area = poi.addressComponent.district; this.startInfo[index].area = poi.addressComponent.district;
break; break;
case 'end': case 'end':
this.endInfo[index].detailedAddress = poi.formattedAddress; this.endInfo[index].detailedAddress = poi.formattedAddress;
this.endInfo[index].longitude = locList[0]; this.endInfo[index].longitude = locList[0];
this.endInfo[index].latitude = locList[1]; this.endInfo[index].latitude = locList[1];
this.endInfo[index].province = poi.addressComponent.province; this.endInfo[index].province = poi.addressComponent.province;
this.endInfo[index].city = poi.addressComponent.city; this.endInfo[index].city = poi.addressComponent.city;
this.endInfo[index].area = poi.addressComponent.district; this.endInfo[index].area = poi.addressComponent.district;
break; break;
default: default:
break; break;
}
// 计算里程,时间
if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) {
this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe(res => {
this.totalDistance = res.distance;
this.totalTime = res.time;
this.getInsurersPrice(); // 计算保费金额
});
}
return true;
} else {
this.service.msgSrv.warning('请重新手动选择地址!');
return false;
} }
// 计算里程,时间
if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) {
this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe(res => {
this.totalDistance = res.distance;
this.totalTime = res.time;
this.getInsurersPrice(); // 计算保费金额
});
}
return true
} else {
this.service.msgSrv.warning('请重新手动选择地址!')
return false
}
} }
}); });
} }
@ -1193,7 +1213,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
getInsurersPrice(insuranceType = this.sf5.value?.insuranceType) { getInsurersPrice(insuranceType = this.sf5.value?.insuranceType) {
console.log(insuranceType); console.log(insuranceType);
console.log(this.totalDistance); console.log(this.totalDistance);
if (insuranceType !== '3' && this.totalDistance > 0) { if (insuranceType !== '3' && this.totalDistance > 0) {
const params = { const params = {
insuranceType, insuranceType,
goodsValue: this.sf4.value.goodsValue, goodsValue: this.sf4.value.goodsValue,
@ -1210,14 +1230,31 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
}); });
} }
} }
// 运费信息价格变更 // 运费信息价格变更
priceChange(event:any, i:any){ priceChange(event: any, i: any) {
i.setValue(event); i.setValue(event);
if(event>=99999){ if (event >= 99999) {
this.modalService.warning({ this.modalService.warning({
nzTitle: '可输入的最大金额为99999元', nzTitle: '可输入的最大金额为99999元'
}); });
} }
this.payChange() this.payChange();
}
checkGoodsName() {
const name = this.sf3.getValue('/goodsName1');
if (!name || name.trim().length === 0) {
return;
}
this.service.request(this.service.$api_checkGoodsName, name).subscribe(res => {
if (res === false) {
const modalRef = this.modalService.error({
nzTitle: '货物名称含有违禁词,请重新输入!',
});
modalRef.afterClose.subscribe(result => {
// this.sf3.setValue('/goodsName1', null);
});
} }
});
}
} }

View File

@ -94,7 +94,7 @@
<sv-title>货物信息</sv-title> <sv-title>货物信息</sv-title>
<ng-container *ngFor="let item of i?.goodsInfoVOList"> <ng-container *ngFor="let item of i?.goodsInfoVOList">
<sv label="货物名称"> <sv label="货物名称">
{{ item.goodsName }} {{ item.goodsTypeName }} - {{ item.goodsName }}
</sv> </sv>
<sv label="货物数量"> {{ item.weight }}吨,{{ item.volume }}方,{{ item.number }}件 </sv> <sv label="货物数量"> {{ item.weight }}吨,{{ item.volume }}方,{{ item.number }}件 </sv>
</ng-container> </ng-container>
@ -190,7 +190,7 @@
</span> </span>
<span>(运费{{ i?.totalFreight | currency }}含附加运费 {{ i?.totalSurcharge | currency }}</span> <span>(运费{{ i?.totalFreight | currency }}含附加运费 {{ i?.totalSurcharge | currency }}</span>
</h3> </h3>
<div>车队长:{{ i?.payeeName }}/{{ i?.payeePhone }}/{{ i?.payeeCardNo }}</div> <div *ngIf='i?.resourceStatus !== "1"' >车队长:{{ i?.payeeName }}/{{ i?.payeePhone }}/{{ i?.payeeCardNo }}</div>
</div> </div>
</div> </div>
</nz-card> </nz-card>
@ -220,6 +220,11 @@
[page]="{}" [page]="{}"
[req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"
[res]="{ reName: { list: 'data.records', total: 'data.total' } }"> [res]="{ reName: { list: 'data.records', total: 'data.total' } }">
<ng-template st-row="operator" let-item>
<div>
{{ item?.operator }} {{ item?.telephone ? '/' + item?.telephone : '' }}
</div>
</ng-template>
</st> </st>
</nz-card> </nz-card>
</div> </div>

View File

@ -23,7 +23,7 @@ export class SupplyManagementVehicleDetailComponent implements OnInit {
} }
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '内容', index: 'operationContent' }, { title: '内容', index: 'operationContent' },
{ title: '操作人', index: 'operator' }, { title: '操作人', render: 'operator' },
{ title: '操作时间', index: 'operatorTimestamp' }, { title: '操作时间', index: 'operatorTimestamp' },
]; ];
totalObj: any; totalObj: any;

View File

@ -172,6 +172,8 @@ export class SupplyManagementVehicleComponent implements OnInit {
type: 'default', type: 'default',
onClick: () => { onClick: () => {
tipsModal.destroy(); tipsModal.destroy();
this.st?.reload();
this.getGoodsSourceStatistical();
} }
}, },
{ {
@ -182,10 +184,14 @@ export class SupplyManagementVehicleComponent implements OnInit {
if(!result?.failNumber) { if(!result?.failNumber) {
this.service.msgSrv.error('没有失败数据!'); this.service.msgSrv.error('没有失败数据!');
tipsModal.destroy(); tipsModal.destroy();
this.st?.reload();
this.getGoodsSourceStatistical();
return; return;
} }
this.service.downloadFile(this.service.$api_getFailUploadGoodsOperateResource, result.ids) this.service.downloadFile(this.service.$api_getFailUploadGoodsOperateResource, result.ids)
tipsModal.destroy(); tipsModal.destroy();
this.st?.reload();
this.getGoodsSourceStatistical();
} }
}, },
] ]
@ -194,51 +200,6 @@ export class SupplyManagementVehicleComponent implements OnInit {
}); });
} }
/**
* 修改运费
*/
updateFreight(item: any) {
const modalRef = this.modal.create({
nzTitle: '货源导入',
nzWidth: 600,
nzContent: SupplyManagementImportSupplyComponent,
nzComponentParams: {
// i: item
},
nzFooter: null
});
modalRef.afterClose.subscribe(result => {
if (result) {
const tipsModal = this.modal.create({
nzTitle: '上传提示',
nzWidth: 600,
nzContent: `<div>文件上传完成!成功<span class="text-blue-dark">${result?.successNumber}</span>条,失败<span class="text-red-dark">${result?.failNumber}</span>条!</div>`,
nzFooter: [
{
label: '取 消',
type: 'default',
onClick: () => {
tipsModal.destroy();
}
},
{
label: '下载失败数据',
type: 'primary',
onClick: () => {
this.service.downloadFile(this.service.$api_getFailUploadGoodsOperateResource, result.ids);
// this.service.request(this.service.$api_getFailUploadGoodsOperateResource, result.ids).subscribe((res: any) => {
// if (res) {
// console.log(res);
// }
// });
console.log(111);
}
}
]
});
}
});
}
/** /**
* 重新指派 * 重新指派

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2021-12-03 11:10:14 * @Date : 2021-12-03 11:10:14
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-11 10:35:44 * @LastEditTime : 2022-04-13 10:41:09
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\model\\import-supply\\import-supply.component.html * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\model\\import-supply\\import-supply.component.html
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
--> -->
@ -51,5 +51,5 @@
</div> </div>
<div class="modal-footer text-right"> <div class="modal-footer text-right">
<button nz-button type="button" (click)="close()">取消</button> <button nz-button type="button" (click)="close()">取消</button>
<button nz-button type="submit" nzType="primary" (click)="save()">确定</button> <button nz-button type="submit" nzType="primary" [nzLoading]="load" (click)="save()">确定</button>
</div> </div>

View File

@ -4,7 +4,7 @@
* @Author : Shiming * @Author : Shiming
* @Date : 2022-03-01 15:13:03 * @Date : 2022-03-01 15:13:03
* @LastEditors : Shiming * @LastEditors : Shiming
* @LastEditTime : 2022-03-11 10:33:44 * @LastEditTime : 2022-04-13 10:41:08
* @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\model\\import-supply\\import-supply.component.ts * @FilePath : \\tms-obc-web\\src\\app\\routes\\supply-management\\model\\import-supply\\import-supply.component.ts
* Copyright (C) 2022 huzhenhong. All rights reserved. * Copyright (C) 2022 huzhenhong. All rights reserved.
*/ */
@ -31,6 +31,7 @@ export class SupplyManagementImportSupplyComponent implements OnInit {
status: boolean = true status: boolean = true
files2: any; files2: any;
schema: SFSchema = {}; schema: SFSchema = {};
load = false
ui: SFUISchema = {}; ui: SFUISchema = {};
networkTransporter: any; // 网络货运人id networkTransporter: any; // 网络货运人id
uploadUrl = apiConf.file_upload_url; uploadUrl = apiConf.file_upload_url;
@ -154,12 +155,11 @@ export class SupplyManagementImportSupplyComponent implements OnInit {
}); });
} }
save(): void { save(): void {
console.log(this?.networkTransporter)
console.log(this.sf.value)
if(!this.sf.value?.shipperAppUserId || !this?.networkTransporter || !this.sf.value?.enterpriseProjectId || !this.sf.value?.fileName) { if(!this.sf.value?.shipperAppUserId || !this?.networkTransporter || !this.sf.value?.enterpriseProjectId || !this.sf.value?.fileName) {
this.service.msgSrv.error('请填写必填项并上传文件!') this.service.msgSrv.error('请填写必填项并上传文件!')
return return
} }
this.load =true;
const formData : any= new FormData(); const formData : any= new FormData();
this.files?.forEach((file: any) => { this.files?.forEach((file: any) => {
formData.append('file', file); formData.append('file', file);
@ -172,6 +172,7 @@ export class SupplyManagementImportSupplyComponent implements OnInit {
this.service.request(this.service.$api_goodsResourceOperateImport, formData).subscribe(res => { this.service.request(this.service.$api_goodsResourceOperateImport, formData).subscribe(res => {
if (res) { if (res) {
this.service.msgSrv.success('导入成功'); this.service.msgSrv.success('导入成功');
this.load =false;
this.modal.destroy({ ...res }); this.modal.destroy({ ...res });
} }
}); });

View File

@ -180,6 +180,9 @@ export class SupplyManagementService extends BaseService {
// 发送邀请司机短信 // 发送邀请司机短信
$api_send_msg_code = `/api/mdc/pbc/smsSend/sendInviteDriver`; $api_send_msg_code = `/api/mdc/pbc/smsSend/sendInviteDriver`;
// 校验货物名称是否合规
$api_checkGoodsName = '/api/sdc/goodsResourceShipper/checkGoodsName';
getDictByKey(dictKey: string) { getDictByKey(dictKey: string) {
const params = { dictKey: dictKey }; const params = { dictKey: dictKey };
return this.request(this.$api_getDictValue, params); return this.request(this.$api_getDictValue, params);

View File

@ -8,7 +8,8 @@
[button]="'none'"></sf> [button]="'none'"></sf>
</div> </div>
<div nz-col [nzSpan]="8" nzOffset="1"> <div nz-col [nzSpan]="8" nzOffset="1">
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)" acl [acl-ability]="['SYSTEM-STAFF-list']">查询</button> <button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)" acl
[acl-ability]="['SYSTEM-STAFF-list']">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
</div> </div>
</div> </div>
@ -18,8 +19,9 @@
<div class="d-flex justify-content-between mb-sm"> <div class="d-flex justify-content-between mb-sm">
<label style="font-size: 18px;"></label> <label style="font-size: 18px;"></label>
<div> <div>
<button nz-button nzType="primary" (click)="staffAction()" acl [acl-ability]="['SYSTEM-STAFF-add']">添加员工</button> <button nz-button nzType="primary" (click)="staffAction()" acl
<button nz-button acl [acl-ability]="['SYSTEM-STAFF-export']">导出</button> [acl-ability]="['SYSTEM-STAFF-add']">添加员工</button>
<button nz-button acl [acl-ability]="['SYSTEM-STAFF-export']" (click)="exportList()">导出</button>
</div> </div>
</div> </div>
@ -33,6 +35,6 @@
</div> </div>
<st #st [data]="service.$api_get_enterprise_staff_page" [columns]="columns" [page]="{}" <st #st [data]="service.$api_get_enterprise_staff_page" [columns]="columns" [page]="{}"
[req]="{ params: {nameOrPhone: this.sf.value?.nameOrPhone} }" [loading]="false" [req]="{ params: {nameOrPhone: this.sf.value?.nameOrPhone} }" [loading]="false" [scroll]="{ y: '370px' }"
[scroll]="{ y: '370px' }" (change)="stChange($event)"></st> (change)="stChange($event)"></st>
</nz-card> </nz-card>

View File

@ -32,7 +32,7 @@ export class StaffManagementComponent implements OnInit {
{ title: '', index: 'key', className: 'text-center', type: 'checkbox' }, { title: '', index: 'key', className: 'text-center', type: 'checkbox' },
{ title: '员工姓名', className: 'text-center', index: 'name' }, { title: '员工姓名', className: 'text-center', index: 'name' },
{ title: '手机号码', className: 'text-center', index: 'telephone' }, { title: '手机号码', className: 'text-center', index: 'telephone' },
{ title: '角色',className: 'text-center', index: 'roleName' }, { title: '角色', className: 'text-center', index: 'roleName' },
{ {
title: '最后登录时间', title: '最后登录时间',
index: 'lastLoginDate', index: 'lastLoginDate',
@ -67,7 +67,8 @@ export class StaffManagementComponent implements OnInit {
}, },
{ {
text: '冻结', text: '冻结',
iif: item => item.stateLocked === 0 && item.roleCode.split(',').indexOf('Administrator') === -1 && item.telephone !== this.user.phone, iif: item =>
item.stateLocked === 0 && item.roleCode.split(',').indexOf('Administrator') === -1 && item.telephone !== this.user.phone,
click: item => this.action(item, 1), click: item => this.action(item, 1),
acl: { ability: ['SYSTEM-STAFF-lock'] } acl: { ability: ['SYSTEM-STAFF-lock'] }
}, },
@ -79,7 +80,8 @@ export class StaffManagementComponent implements OnInit {
}, },
{ {
text: '删除', text: '删除',
iif: item => item.stateLocked === 0 && item.roleCode.split(',').indexOf('Administrator') === -1 && item.telephone !== this.user.phone, iif: item =>
item.stateLocked === 0 && item.roleCode.split(',').indexOf('Administrator') === -1 && item.telephone !== this.user.phone,
click: item => this.action(item, 3), click: item => this.action(item, 3),
acl: { ability: ['SYSTEM-STAFF-delete'] } acl: { ability: ['SYSTEM-STAFF-delete'] }
} }
@ -167,6 +169,11 @@ export class StaffManagementComponent implements OnInit {
this.sf.reset(); this.sf.reset();
} }
exportList() {
const params = { nameOrPhone: this.sf.value?.nameOrPhone };
this.service.downloadFile(this.service.$api_export_staff, { ...params, pageSize: -1 });
}
private deleteStaff(params: any) { private deleteStaff(params: any) {
this.service.request(this.service.$api_delete_staff, params).subscribe(res => { this.service.request(this.service.$api_delete_staff, params).subscribe(res => {
if (res) { if (res) {

View File

@ -15,6 +15,8 @@ import { BaseService } from 'src/app/shared/services';
export class SystemService extends BaseService { export class SystemService extends BaseService {
// 分页查询企业项目员工列表 // 分页查询企业项目员工列表
$api_get_enterprise_staff_page = '/api/mdc/cuc/userApp/getEnterpriseProjectStaffListPage'; $api_get_enterprise_staff_page = '/api/mdc/cuc/userApp/getEnterpriseProjectStaffListPage';
// 分页查询企业项目员工列表
$api_export_staff = '/api/mdc/cuc/userApp/enterpriseProjectStaffExport';
// 添加员工 // 添加员工
$api_add_staff = '/api/mdc/cuc/userApp/addStaff'; $api_add_staff = '/api/mdc/cuc/userApp/addStaff';
// 编辑员工 // 编辑员工

View File

@ -36,7 +36,7 @@
</nz-tabset> </nz-tabset>
<!-- 数据列表 --> <!-- 数据列表 -->
<st #st [scroll]="{ x: '1200px',y:'450px' }" [data]="service.$api_get_individual_income_page" [columns]="columns" <st #st [scroll]="{ x: '1200px',y:'450px' }" [data]="service.$api_get_individual_income_page" [columns]="columns"
[req]="{ params: reqParams }" [page]="{}" [loading]="service.http.loading" (change)="stChange($event)"> [req]="{ process: beforeReq }" [page]="{}" [loading]="service.http.loading" (change)="stChange($event)">
</st> </st>
</nz-card> </nz-card>
<ng-template #extraTemplate> <ng-template #extraTemplate>

View File

@ -1,6 +1,6 @@
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { STChange, STColumn, STComponent, STData } from '@delon/abc/st'; import { STChange, STColumn, STComponent, STData, STRequestOptions } from '@delon/abc/st';
import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form'; import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
import { ShipperBaseService } from '@shared'; import { ShipperBaseService } from '@shared';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
@ -32,16 +32,15 @@ export class TaxManagementIndividualIncomeComponent implements OnInit {
constructor(public service: TaxManagementService) {} constructor(public service: TaxManagementService) {}
/** beforeReq = (requestOptions: STRequestOptions) => {
* 查询参数 Object.assign(requestOptions.body, { declareStatus: this.selectedIndex });
*/ if (this.sf) {
get reqParams() { Object.assign(requestOptions.body, { ...this.sf.value });
const params = Object.assign({}, this.sf?.value || {}, { delete requestOptions.body._$expand;
declareStatus: this.selectedIndex }
}); this.selectedRows = [];
delete params._$expand; return requestOptions;
return { ...params }; };
}
stChange(e: STChange): void { stChange(e: STChange): void {
switch (e.type) { switch (e.type) {

View File

@ -119,7 +119,7 @@ export class TaxManagementOrderReportingComponent implements OnInit {
searchLoadingText: '搜索中...', searchLoadingText: '搜索中...',
allowClear: true, allowClear: true,
onSearch: (q: any) => { onSearch: (q: any) => {
let str =q.replace(/^\s+|\s+$/g,""); let str = q.replace(/^\s+|\s+$/g, "");
if (str) { if (str) {
return this.service return this.service
.request(this.service.$api_enterpriceList, { enterpriseName: str }) .request(this.service.$api_enterpriceList, { enterpriseName: str })
@ -129,7 +129,7 @@ export class TaxManagementOrderReportingComponent implements OnInit {
return of([]); return of([]);
} }
}, },
} as SFSelectWidgetSchema } as SFSelectWidgetSchema
}, },
driverName: { driverName: {
@ -261,8 +261,8 @@ export class TaxManagementOrderReportingComponent implements OnInit {
{ title: '卸货地详细地址', index: 'unloadDetailedAddress', className: 'text-center', width: '180px' }, { title: '卸货地详细地址', index: 'unloadDetailedAddress', className: 'text-center', width: '180px' },
{ title: '货主名称', index: 'shipperName', className: 'text-center', width: '180px' }, { title: '货主名称', index: 'shipperName', className: 'text-center', width: '180px' },
{ title: '货主纳税人识别号', index: 'shipperProvinceCode', className: 'text-center', width: '180px' }, { title: '货主纳税人识别号', index: 'shipperProvinceCode', className: 'text-center', width: '180px' },
{ title: '录单时间', index: 'billCreateTime', className: 'text-center', width: '250px' }, { title: '录单时间', index: 'recordTime', className: 'text-center', width: '250px' },
{ title: '接单时间', index: 'wayBillCreateTime', className: 'text-center', width: '200px' }, { title: '接单时间', index: 'wayBillCreateTime', className: 'text-center', width: '200px' },
{ title: '发车时间', index: 'loadTime', className: 'text-center', width: '200px' }, { title: '发车时间', index: 'loadTime', className: 'text-center', width: '200px' },
{ title: '到车时间', index: 'unloadTime', className: 'text-center', width: '150px' }, { title: '到车时间', index: 'unloadTime', className: 'text-center', width: '150px' },
{ title: '结束时间', index: 'payeeName', className: 'text-center', width: '150px' }, { title: '结束时间', index: 'payeeName', className: 'text-center', width: '150px' },
@ -308,7 +308,7 @@ export class TaxManagementOrderReportingComponent implements OnInit {
nzOkText: '确定', nzOkText: '确定',
nzCancelText: '取消', nzCancelText: '取消',
nzOnOk: () => { nzOnOk: () => {
this.service.request(this.service.$api_get_recessionTaxOrder,params).subscribe((res: any) => { this.service.request(this.service.$api_get_recessionTaxOrder, params).subscribe((res: any) => {
if (res) { if (res) {
this.service.msgSrv.success('撤销成功'); this.service.msgSrv.success('撤销成功');
this.search(); this.search();
@ -371,7 +371,7 @@ export class TaxManagementOrderReportingComponent implements OnInit {
selectChange(item: any) { selectChange(item: any) {
console.log(item); console.log(item);
this.selectedIndex = item?.value || ''; this.selectedIndex = item?.value || '';
setTimeout(() => { setTimeout(() => {
this.st.load(); this.st.load();
@ -499,5 +499,4 @@ export class TaxManagementOrderReportingComponent implements OnInit {
}) })
} }
} }

View File

@ -51,7 +51,7 @@ export class TaxManagementOrderVerifyResultComponent implements OnInit {
beforeReq = (requestOptions: STRequestOptions) => {let a: string = ''; beforeReq = (requestOptions: STRequestOptions) => {let a: string = '';
switch (this.subjectType) { switch (this.subjectType) {
case '0': case '0':
a = this.record?.networkTransporter; a = this.record?.networkTransporterId;
break break
case '1': case '1':
a = this.record?.shipperId; a = this.record?.shipperId;
@ -60,7 +60,7 @@ export class TaxManagementOrderVerifyResultComponent implements OnInit {
a = this.record?.driverId; a = this.record?.driverId;
break break
case '3': case '3':
a = this.record?.billId; a = this.record?.wayBillId;
break break
} }
Object.assign(requestOptions.body, { Object.assign(requestOptions.body, {

View File

@ -256,7 +256,7 @@ export class CancellationInvoiceComponent implements OnInit {
hidden: true hidden: true
} }
}, },
vatappHId: { vatappHCode: {
type: 'string', type: 'string',
title: '申请编号', title: '申请编号',
ui: { ui: {
@ -330,18 +330,18 @@ export class CancellationInvoiceComponent implements OnInit {
private initST(): STColumn[] { private initST(): STColumn[] {
return [ return [
{ title: '', index: 'key', type: 'checkbox', fixed: 'left', width: 50, className: 'text-center' }, { title: '', index: 'key', type: 'checkbox', fixed: 'left', width: 50, className: 'text-center' },
{ title: '分票编号', render: 'vatinvcode', width: 200 }, { title: '分票编号', render: 'vatinvcode', width: 220 },
{ {
title: '申请编号', title: '申请编号',
index: 'vatappHCode', index: 'vatappHCode',
width: 150, width: 220,
type: 'link', type: 'link',
click: item => this.router.navigate(['/ticket/invoice-requested/detail/' + item?.vatappHId]) click: item => this.router.navigate(['/ticket/invoice-requested/detail/' + item?.vatappHId])
}, },
{ title: '申请时间', index: 'createTime', type: 'date', width: 150 }, { title: '申请时间', index: 'createTime', type: 'date', width: 150 },
{ title: '发票类型', index: 'vatapptypeLabel', width: 150 }, { title: '发票类型', index: 'vatapptypeLabel', width: 150 },
{ title: '网络货运人', index: 'ltdName', width: 160 }, { title: '网络货运人', index: 'ltdName', width: 220 },
{ title: '购买人', index: 'artoname', width: 160 }, { title: '购买人', index: 'artoname', width: 220 },
{ title: '订单数', index: 'ordlines', width: 90, className: 'text-right' }, { title: '订单数', index: 'ordlines', width: 90, className: 'text-right' },
{ {
title: '价税合计', title: '价税合计',
@ -376,7 +376,7 @@ export class CancellationInvoiceComponent implements OnInit {
}, },
{ title: '服务名称', index: 'vatname', width: 120 }, { title: '服务名称', index: 'vatname', width: 120 },
{ title: '销货清单', index: 'isdetail', width: 120, type: 'enum', enum: { 1: '是', 0: '否' }, className: 'text-center' }, { title: '销货清单', index: 'isdetail', width: 120, type: 'enum', enum: { 1: '是', 0: '否' }, className: 'text-center' },
{ title: '票面备注', index: 'remarks', width: 250 }, { title: '票面备注', index: 'remarks', width: 300 },
{ title: '其他要求', index: 'otherremarks', width: 100 }, { title: '其他要求', index: 'otherremarks', width: 100 },
{ {
title: '操作', title: '操作',

View File

@ -237,7 +237,7 @@ export class ETCBlacklistComponent implements OnInit {
} }
}, },
params5: { params5: {
title: '司机姓名', title: '车辆所有人',
type: 'string', type: 'string',
ui: { ui: {
placeholder: '请输入', placeholder: '请输入',

View File

@ -8,7 +8,7 @@
<nz-card class="statistics-box"> <nz-card class="statistics-box">
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col [nzXl]="8" [nzLg]="8" [nzSm]="8" [nzXs]="8" se-container [labelWidth]="100" col="1"> <div nz-col [nzXl]="12" [nzLg]="12" [nzSm]="8" [nzXs]="8" se-container [labelWidth]="100" col="1">
<se label="销售方"> <se label="销售方">
{{ headerInfo?.ltdName }} {{ headerInfo?.ltdName }}
</se> </se>
@ -34,7 +34,7 @@
{{ headerInfo?.remarks }} {{ headerInfo?.remarks }}
</se> </se>
</div> </div>
<div nz-col [nzXl]="8" [nzLg]="8" [nzSm]="8" [nzXs]="8" se-container [labelWidth]="100" col="1"> <div nz-col [nzXl]="12" [nzLg]="12" [nzSm]="8" [nzXs]="8" se-container [labelWidth]="100" col="1">
<se label="购买方"> <se label="购买方">
{{ headerInfo?.artoname }} {{ headerInfo?.artoname }}
</se> </se>
@ -57,7 +57,7 @@
{{headerInfo?.otherremarks || '-'}} {{headerInfo?.otherremarks || '-'}}
</se> </se>
</div> </div>
<div *ngIf="isCanEdit && selectedIndex===2" nz-col [nzXl]="8" [nzLg]="8" [nzSm]="8" [nzXs]="8" class="text-right"> <div *ngIf="isCanEdit && selectedIndex===2" nz-col [nzXl]="12" [nzLg]="12" [nzSm]="8" [nzXs]="8" class="text-right">
<ng-container *ngIf="isEdit; else elseTemplate"> <ng-container *ngIf="isEdit; else elseTemplate">
<button nz-button (click)="isEdit = false; invoiceST?.load(1)">取消</button> <button nz-button (click)="isEdit = false; invoiceST?.load(1)">取消</button>
<button nz-button nzType="primary" (click)="saveInvoices()">保 存</button> <button nz-button nzType="primary" (click)="saveInvoices()">保 存</button>
@ -118,7 +118,7 @@
(ngModelChange)="invoiceST.setRow(index, { vatname: $event })" style="width: 100%"> (ngModelChange)="invoiceST.setRow(index, { vatname: $event })" style="width: 100%">
<nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of services"></nz-option> <nz-option [nzValue]="item.value" [nzLabel]="item.label" *ngFor="let item of services"></nz-option>
</nz-select> </nz-select>
<ng-container *ngIf="!isEdit">{{ item.vatname }}</ng-container> <ng-container *ngIf="!isEdit">{{ item.vatnameLabel || item.vatname }}</ng-container>
</ng-template> </ng-template>
<ng-template st-row="vatmodel" let-item let-index="index"> <ng-template st-row="vatmodel" let-item let-index="index">
<input *ngIf="isEdit" nz-input [ngModel]="item.vatmodel" <input *ngIf="isEdit" nz-input [ngModel]="item.vatmodel"

View File

@ -8,13 +8,12 @@
<nz-card class="statistics-box"> <nz-card class="statistics-box">
<div nz-row nzGutter="8"> <div nz-row nzGutter="8">
<div nz-col [nzXl]="8" [nzLg]="12" nzMd="12" [nzSm]="24" [nzXs]="24" se-container [labelWidth]="150" col="1"> <div nz-col [nzXl]="8" [nzLg]="12" [nzMd]="12" [nzSm]="24" [nzXs]="24" se-container [labelWidth]="150" col="1">
<se label="网络货运人">
<se label="网络货运人" [labelWidth]="133">
{{headerInfo?.ltdidName}} {{headerInfo?.ltdidName}}
</se> </se>
<se label="申请编号">
{{headerInfo?.vatappcode}}
</se>
<se label="已开/全部订单数"> <se label="已开/全部订单数">
{{headerInfo?.vatinvHNum}} / {{headerInfo?.vatinvBillNum}} {{headerInfo?.vatinvHNum}} / {{headerInfo?.vatinvBillNum}}
</se> </se>
@ -31,13 +30,16 @@
{{headerInfo?.provinceName}}{{headerInfo?.cityName}}{{headerInfo?.areaName}}{{headerInfo?.reciaddr}} {{headerInfo?.provinceName}}{{headerInfo?.cityName}}{{headerInfo?.areaName}}{{headerInfo?.reciaddr}}
</se> </se>
</div> </div>
<div nz-col [nzXl]="8" [nzLg]="12" nzMd="12" [nzSm]="24" [nzXs]="24" se-container [labelWidth]="100" col="1"> <div nz-col [nzXl]="8" [nzLg]="12" [nzMd]="12" [nzSm]="24" [nzXs]="24" se-container [labelWidth]="100" col="1">
<se label="购买方"> <se label="购买方">
{{headerInfo?.artoName}} {{headerInfo?.artoName}}
</se> </se>
<se label="纳税号"> <se label="纳税号">
{{headerInfo?.taxNumber}} {{headerInfo?.taxNumber}}
</se> </se>
<se label="申请编号">
{{headerInfo?.vatappcode}}
</se>
<se label="地址"> <se label="地址">
{{headerInfo?.registerAddr}} {{headerInfo?.registerAddr}}
</se> </se>

View File

@ -177,7 +177,7 @@ export class InvoiceRequestedDetailComponent implements OnInit {
} }
routeToOrder(item: any) { routeToOrder(item: any) {
if (item.billType === 1) { if (item.billType === '1') {
this.router.navigate(['/order-management/vehicle/vehicle-detail/' + item.billHId]); this.router.navigate(['/order-management/vehicle/vehicle-detail/' + item.billHId]);
} else { } else {
this.router.navigate(['/order-management/bulk/bulk-detail/' + item.billHId]); this.router.navigate(['/order-management/bulk/bulk-detail/' + item.billHId]);

View File

@ -20,7 +20,7 @@
<div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right"> <div nz-col [nzXl]="_$expand ? 24 : 6" [nzLg]="24" [nzSm]="24" [nzXs]="24" class="text-right">
<button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)">查询</button> <button nz-button nzType="primary" [nzLoading]="service.http.loading" (click)="st?.load(1)">查询</button>
<button nz-button (click)="resetSF()">重置</button> <button nz-button (click)="resetSF()">重置</button>
<!-- <button nz-button> 导出</button> --> <button nz-button (click)="exprot()"> 导出</button>
<button nz-button nzType="link" (click)="expandToggle()"> <button nz-button nzType="link" (click)="expandToggle()">
{{ !_$expand ? '展开' : '收起' }} {{ !_$expand ? '展开' : '收起' }}
<i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i> <i nz-icon [nzType]="!_$expand ? 'down' : 'up'"></i>
@ -74,4 +74,4 @@
</se> </se>
</div> </div>
</div> </div>
</ng-template> </ng-template>

View File

@ -212,7 +212,7 @@ export class InvoiceRequestedComponent {
label: '手工处理', label: '手工处理',
onClick: () => { onClick: () => {
const params = { const params = {
ficoVatappBillVOList: this.selectedRows.map(item => { ficoVatappHVOList: this.selectedRows.map(item => {
const i = Object.assign({}, { ...item }); const i = Object.assign({}, { ...item });
delete i._values; delete i._values;
delete i._rowClassName; delete i._rowClassName;
@ -236,7 +236,7 @@ export class InvoiceRequestedComponent {
label: '自动开票', label: '自动开票',
onClick: () => { onClick: () => {
const params = { const params = {
ficoVatappBillVOList: this.selectedRows.map(item => { ficoVatappHVOList: this.selectedRows.map(item => {
const i = Object.assign({}, { ...item }); const i = Object.assign({}, { ...item });
delete i._values; delete i._values;
delete i._rowClassName; delete i._rowClassName;
@ -302,6 +302,11 @@ export class InvoiceRequestedComponent {
this.sf?.setValue('/expand', this._$expand); this.sf?.setValue('/expand', this._$expand);
} }
// 导出
exprot() {
this.service.exportStart({ ...this.sf.value, pageSize: -1 }, this.service.$api_export_invoice_requested_page);
}
private initSF(): SFSchema { private initSF(): SFSchema {
return { return {
properties: { properties: {

View File

@ -11,7 +11,7 @@
</se> </se>
<ng-container *ngIf="type===2"> <ng-container *ngIf="type===2">
<se label="收件地址" required> <se label="收件地址" required>
<nz-select [(ngModel)]="data.rcontactInfo" [nzCustomTemplate]="rcontactInfosData"> <nz-select [(ngModel)]="data.rcontactInfo" [nzCustomTemplate]="rcontactInfosData" nzDropdownClassName="print_order_select">
<nz-option [nzValue]="item" nzLabel="Jack" *ngFor="let item of rcontactInfos" <nz-option [nzValue]="item" nzLabel="Jack" *ngFor="let item of rcontactInfos"
[nzCustomContent]="true"> [nzCustomContent]="true">
{{item.contact}} &nbsp; &nbsp;&nbsp; {{item.tel}}<br /> {{item.contact}} &nbsp; &nbsp;&nbsp; {{item.tel}}<br />
@ -25,7 +25,7 @@
</ng-template> </ng-template>
</se> </se>
<se label="寄件地址" required> <se label="寄件地址" required>
<nz-select [(ngModel)]="data.scontactInfo" [nzCustomTemplate]="scontactInfosData"> <nz-select [(ngModel)]="data.scontactInfo" [nzCustomTemplate]="scontactInfosData" nzDropdownClassName="print_order_select">
<nz-option [nzValue]="item" nzLabel="Jack" *ngFor="let item of scontactInfos" <nz-option [nzValue]="item" nzLabel="Jack" *ngFor="let item of scontactInfos"
[nzCustomContent]="true"> [nzCustomContent]="true">
{{item.contact}} &nbsp; &nbsp;&nbsp; {{item.tel}}<br /> {{item.contact}} &nbsp; &nbsp;&nbsp; {{item.tel}}<br />

View File

@ -17,6 +17,8 @@ export class TicketService extends ShipperBaseService {
// 运营端查询发票申请记录 // 运营端查询发票申请记录
$api_get_invoice_requested_page = '/api/fcc/ficoVatappH/queryOperateVatappHList'; $api_get_invoice_requested_page = '/api/fcc/ficoVatappH/queryOperateVatappHList';
// 导出发票申请记录
$api_export_invoice_requested_page = '/api/fcc/ficoVatappH/reportOperateVatappHList';
// 获取开票申请订单明细头部信息 // 获取开票申请订单明细头部信息
$api_get_invoice_requested_header_detail = '/api/fcc/ficoVatappBill/getDetailHeadByVatappHId'; $api_get_invoice_requested_header_detail = '/api/fcc/ficoVatappBill/getDetailHeadByVatappHId';
// 货主/运营端获取开票申请订单明细 // 货主/运营端获取开票申请订单明细
@ -74,7 +76,7 @@ export class TicketService extends ShipperBaseService {
// 获取分票发票抬头开票申请订单明细 // 获取分票发票抬头开票申请订单明细
$api_get_invoice_order_detail = '/api/fcc/ficoVatappBill/getDetailByVatinvHId'; $api_get_invoice_order_detail = '/api/fcc/ficoVatappBill/getDetailByVatinvHId';
// 货主/运营端获取开票申请订单明细导出 // 货主/运营端获取开票申请订单明细导出
$api_export_invoice_order_detail = '/api/fcc/ficoVatappBill/reportDetailByVatapp'; $api_export_invoice_order_detail = '/api/fcc/ficoVatappBill/reportDetailByVatinvHId';
// 获取分票发票抬头开票申请费用明细 // 获取分票发票抬头开票申请费用明细
$api_get_invoice_cost_detail = '/api/fcc/ficoVatappFee/getDetailByVatinvHId'; $api_get_invoice_cost_detail = '/api/fcc/ficoVatappFee/getDetailByVatinvHId';
// 获取分票发票明细 // 获取分票发票明细
@ -149,21 +151,22 @@ export class TicketService extends ShipperBaseService {
if (!url) { if (!url) {
return; return;
} }
const uA = window.navigator.userAgent; // 判断浏览器内核 this.openURL(url);
const isIE = // const uA = window.navigator.userAgent; // 判断浏览器内核
/msie\s|trident\/|edge\//i.test(uA) && // const isIE =
!!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window); // /msie\s|trident\/|edge\//i.test(uA) &&
const objectUrl = url; // !!('uniqueID' in document || 'documentMode' in document || 'ActiveXObject' in window || 'MSInputMethodContext' in window);
const a = document.createElement('a'); // const objectUrl = url;
document.body.appendChild(a); // const a = document.createElement('a');
a.href = objectUrl; // document.body.appendChild(a);
a.download = '面单.pdf'; // a.href = objectUrl;
if (isIE) { // a.download = '面单.pdf';
// 兼容IE11无法触发下载的问题 // if (isIE) {
(navigator as any).msSaveBlob(url, a.download); // // 兼容IE11无法触发下载的问题
} else { // (navigator as any).msSaveBlob(url, a.download);
a.click(); // } else {
} // a.click();
a.remove(); // }
// a.remove();
} }
} }

View File

@ -17,7 +17,7 @@ export class UserCenterComponentsDriverComponent implements OnInit {
_$expand = false; _$expand = false;
@ViewChild('st', { static: false }) st!: STComponent; @ViewChild('st', { static: false }) st!: STComponent;
@ViewChild('sf', { static: false }) sf!: SFComponent; @ViewChild('sf', { static: false }) sf!: SFComponent;
ui: SFUISchema = { '*': { spanLabelFixed: 120, grid: { lg: 8, md: 12, sm: 12, xs: 24 }, enter: () => this.st.load() } }; ui: SFUISchema = { '*': { spanLabelFixed: 130, grid: { lg: 8, md: 12, sm: 12, xs: 24 }, enter: () => this.st.load() } };
schema: SFSchema = this.initSF(); schema: SFSchema = this.initSF();
columns: STColumn[] = this.initST(); columns: STColumn[] = this.initST();
@ -199,10 +199,10 @@ export class UserCenterComponentsDriverComponent implements OnInit {
title: '从业资格证状态', title: '从业资格证状态',
enum: [ enum: [
{ label: '全部', value: '' }, { label: '全部', value: '' },
{ label: '待审核', value: 10 }, { label: '未提交 ', value: -1 },
{ label: '审核通过', value: 20 }, { label: '已提交', value: 1 },
{ label: '驳回', value: 30 }, { label: '已通过', value: 2 },
{ label: '证件过期', value: 40 } { label: '过期', value: 3 }
], ],
default: '', default: '',
ui: { ui: {
@ -302,10 +302,13 @@ export class UserCenterComponentsDriverComponent implements OnInit {
type: 'badge', type: 'badge',
badge: { badge: {
'-1': { text: '未提交', color: 'default' }, '-1': { text: '未提交', color: 'default' },
10: { text: '待审核', color: 'default' }, 1: { text: '已提交', color: 'processing' },
20: { text: '审核通过', color: 'success' }, 2: { text: '通过', color: 'success' },
30: { text: '驳回', color: 'warning' }, 3: { text: '已过期', color: 'error' },
40: { text: '证件过期', color: 'error' } // 10: { text: '待审核', color: 'default' },
// 20: { text: '审核通过', color: 'success' },
// 30: { text: '驳回', color: 'warning' },
// 40: { text: '证件过期', color: 'error' }
}, },
width: 180 width: 180
}, },

View File

@ -1,7 +1,7 @@
import { Component, OnInit, ViewChild } from '@angular/core'; import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router'; import { ActivatedRoute, Router } from '@angular/router';
import { STColumn, STColumnBadge, STComponent, STData } from '@delon/abc/st'; import { STColumn, STColumnBadge, STComponent, STData } from '@delon/abc/st';
import { SFComponent, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form'; import { SFComponent, SFDateWidgetSchema, SFSchema, SFSchemaEnum, SFSelectWidgetSchema, SFUISchema } from '@delon/form';
import { ModalHelper } from '@delon/theme'; import { ModalHelper } from '@delon/theme';
import { NzModalService } from 'ng-zorro-antd/modal'; import { NzModalService } from 'ng-zorro-antd/modal';
import { of, Subject } from 'rxjs'; import { of, Subject } from 'rxjs';
@ -135,7 +135,7 @@ export class VehicleComponentsAuditComponent implements OnInit {
expand: (value: boolean) => value expand: (value: boolean) => value
} }
} }
} },
// approvalStatus: { // approvalStatus: {
// type: 'string', // type: 'string',
// title: '审核状态', // title: '审核状态',
@ -155,9 +155,22 @@ export class VehicleComponentsAuditComponent implements OnInit {
// }, // },
// }, // },
// }, // },
// approvalPassTime: {
// type: 'string',
// title: '审核通过时间',
// ui: {
// widget: 'sl-from-to-search',
// format: 'yyyy-MM-dd',
// placeholder: '请选择',
// nzShowTime: true,
// visibleIf: {
// expand: (value: boolean) => value
// }
// } as SFDateWidgetSchema
// }
} }
}; };
this.ui = { '*': { spanLabelFixed: 90, grid: { span: 8, gutter: 4 }, enter: () => this.st.load() } }; this.ui = { '*': { spanLabelFixed: 120, grid: { span: 8, gutter: 4 }, enter: () => this.st.load() } };
} }
initST() { initST() {
@ -186,6 +199,7 @@ export class VehicleComponentsAuditComponent implements OnInit {
} }
}, },
{ title: '申请时间', width: '180px', className: 'text-center', index: 'createTime' }, { title: '申请时间', width: '180px', className: 'text-center', index: 'createTime' },
{ title: '审核通过时间', width: '180px', className: 'text-center', index: 'approvalPassTime' },
{ {
title: '操作', title: '操作',
fixed: 'right', fixed: 'right',

View File

@ -184,22 +184,22 @@ export class VehicleComponentsListComponent implements OnInit {
} }
} }
}, },
isSelfs: { // isSelfs: {
type: 'string', // type: 'string',
title: '是否入网', // title: '是否入网',
enum: [ // enum: [
{ label: '全部', value: '' }, // { label: '全部', value: '' },
{ label: '是', value: 1 }, // { label: '是', value: 1 },
{ label: '否', value: 0 } // { label: '否', value: 0 }
], // ],
ui: { // ui: {
widget: 'select', // widget: 'select',
allowClear: true, // allowClear: true,
visibleIf: { // visibleIf: {
expand: (value: boolean) => value // expand: (value: boolean) => value
} // }
} // }
} // }
// putOnRecord: { // putOnRecord: {
// type: 'string', // type: 'string',
// title: '是否已备案', // title: '是否已备案',
@ -263,7 +263,7 @@ export class VehicleComponentsListComponent implements OnInit {
3: { text: '已到期', color: 'error' } 3: { text: '已到期', color: 'error' }
} }
}, },
{ title: '是否入网', width: '200px', className: 'text-center', index: 'carOwner' }, // { title: '是否入网', width: '200px', className: 'text-center', index: 'carOwner' },
{ title: '所有人', width: '200px', className: 'text-center', index: 'carOwner' }, { title: '所有人', width: '200px', className: 'text-center', index: 'carOwner' },
{ title: '是否挂靠', width: '150px', className: 'text-center', render: 'isSelf' }, { title: '是否挂靠', width: '150px', className: 'text-center', render: 'isSelf' },
{ title: '挂靠协议', width: '150px', className: 'text-center', render: 'approvalAuditStatus' }, { title: '挂靠协议', width: '150px', className: 'text-center', render: 'approvalAuditStatus' },

View File

@ -39,8 +39,8 @@ export class WaybillManagementBulkeDetailComponent implements OnInit {
modalTitle:string = ''; modalTitle:string = '';
unLoadingPlaceVOList: any = []; unLoadingPlaceVOList: any = [];
logColumns2: STColumn[] = [ logColumns2: STColumn[] = [
{ title: '时间', index: 'vinOutTime' }, { title: '时间', index: 'parkBte' },
{ title: '地点', index: 'cityName' }, { title: '地点', index: 'parkAdr' },
]; ];
logColumns: STColumn[] = [ logColumns: STColumn[] = [
{ title: '款项', index: 'costCodeLabel' }, { title: '款项', index: 'costCodeLabel' },
@ -167,14 +167,15 @@ sureArrive(item: any) {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res.cityArray; this.addressItems = res.parkArray;
if(this.addressItems && this.addressItems.length > 0){ if(this.addressItems && this.addressItems.length > 0){
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -190,7 +191,8 @@ sureArrive(item: any) {
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;

View File

@ -160,14 +160,15 @@ export class WaybillManagementVehicleDetailComponent implements OnInit, OnDestro
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;
this.addressItems = res.cityArray; this.addressItems = res.parkArray;
if (this.addressItems && this.addressItems.length > 0) { if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => { this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.vinOutTime); item.parkBte = this.getLocalTime(item.parkBte);
}); });
} }
} }
@ -183,7 +184,8 @@ export class WaybillManagementVehicleDetailComponent implements OnInit, OnDestro
points?.forEach((item: any) => { points?.forEach((item: any) => {
list.push({ list.push({
name: item.hgt, name: item.hgt,
lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))] lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))],
time: item.gtm
}); });
}); });
this.mapList = list; this.mapList = list;

View File

@ -48,15 +48,18 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
@Output() @Output()
readonly clcikPointEvent = new EventEmitter<any>(); readonly clcikPointEvent = new EventEmitter<any>();
constructor(public service: BaseService, private amapService: AmapService) {} constructor(public service: BaseService, private amapService: AmapService) {
this.mapInit();
}
ngOnChanges(changes: SimpleChanges): void { ngOnChanges(changes: SimpleChanges): void {
// 路线图变更: 设置路线图, 指定路线图 // 路线图变更: 设置路线图, 指定路线图
if (changes?.pathList?.currentValue && this?.pathSimplifierIns) { if (changes?.pathList?.currentValue && this?.pathSimplifierIns) {
this.setData(changes.pathList?.currentValue); this.setData(changes.pathList?.currentValue);
this.setPathIndex(this.selectedIndex); this.setPathIndex(this.selectedIndex);
} }
// 路径信息变更: 更新路线图, 设置路线图, 指定路线图, 获取终点地址信息并标点 // 路径信息变更: 更新路线图, 设置路线图, 指定路线图, 获取终点地址信息并标点
if (changes?.mapList?.currentValue && this?.pathSimplifierIns && changes.mapList?.currentValue.length > 0) { if (changes?.mapList?.currentValue) {
// console.log(this.mapList); // console.log(this.mapList);
this.pathList = [ this.pathList = [
{ {
@ -64,22 +67,29 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
points: changes.mapList?.currentValue points: changes.mapList?.currentValue
} }
]; ];
this.setData(this.pathList); if (this?.pathSimplifierIns) {
this.setPathIndex(this.selectedIndex); this.setData(this.pathList);
this.getPoiByPositon(this.mapList[this.mapList?.length - 1]?.lnglat); if (changes.mapList?.currentValue.length > 0) {
this.setPathIndex(this.selectedIndex);
this.getPoiByPositon('起', 'blue', this.mapList[0]?.lnglat, '时间:' + this.amapService.formatTime(this.mapList[0]?.time));
this.getPoiByPositon(
'终',
'red',
this.mapList[this.mapList?.length - 1]?.lnglat,
'时间:' + this.amapService.formatTime(this.mapList[this.mapList?.length - 1]?.time)
);
}
}
} }
// 标点列表变更: 更新标点数据, 绘画标点 // 标点列表变更: 更新标点数据, 绘画标点
if (changes?.pois?.currentValue) { if (changes?.pois?.currentValue) {
// console.log(this.pois);
this._pois = changes?.pois?.currentValue; this._pois = changes?.pois?.currentValue;
if (this?.markerList && this._pois.length > 0) { if (this?.markerList && this._pois.length > 0) {
this.markerList.render(this._pois); this.markerList.render(this._pois);
} }
} }
} }
ngOnInit(): void { ngOnInit(): void {}
this.mapInit();
}
ngOnDestroy(): void { ngOnDestroy(): void {
// 销毁地图数据 // 销毁地图数据
if (this.aMap) { if (this.aMap) {
@ -143,8 +153,15 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
}); });
this.setData(this.pathList); this.setData(this.pathList);
if (this.pathList.length > 0) { if (this.mapList.length > 0) {
this.setPathIndex(this.selectedIndex); this.setPathIndex(this.selectedIndex);
this.getPoiByPositon('起', 'blue', this.mapList[0]?.lnglat, '时间:' + this.amapService.formatTime(this.mapList[0]?.time));
this.getPoiByPositon(
'终',
'red',
this.mapList[this.mapList?.length - 1]?.lnglat,
'时间:' + this.amapService.formatTime(this.mapList[this.mapList?.length - 1]?.time)
);
} }
this.pathSimplifierIns.on('pointClick', (e: any, info: any) => { this.pathSimplifierIns.on('pointClick', (e: any, info: any) => {
@ -158,7 +175,10 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
position: info.pathData.points[info.pointIndex].lnglat, position: info.pathData.points[info.pointIndex].lnglat,
content: ` content: `
<label style="font-weight: bold;">${result.regeocode.formattedAddress}<label/><br/> <label style="font-weight: bold;">${result.regeocode.formattedAddress}<label/><br/>
<label style="font-weight: 400;">车速: ${info.pathData.points[info.pointIndex].name}<label/><br/> <label style="font-weight: 400;">车速: ${info.pathData.points[info.pointIndex].name}km/h<label/><br/>
<label style="font-weight: 400;">东经: ${info.pathData.points[info.pointIndex].lnglat?.[0]}, 北纬:${
info.pathData.points[info.pointIndex].lnglat?.[1]
}<label/><br/>
<label style="font-weight: 400;">时间: ${this.amapService.formatTime(info.pathData.points[info.pointIndex].time)}<label/> <label style="font-weight: 400;">时间: ${this.amapService.formatTime(info.pathData.points[info.pointIndex].time)}<label/>
` `
}); });
@ -179,12 +199,13 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
//返回数据项对应的Marker //返回数据项对应的Marker
getMarker: (dataItem: POI, context: any, recycledMarker: any) => { getMarker: (dataItem: POI, context: any, recycledMarker: any) => {
//存在可回收利用的marker //存在可回收利用的marker
if (recycledMarker) { // if (recycledMarker) {
//直接更新内容返回 // //直接更新内容返回
recycledMarker.setIconLabel(context.id); // recycledMarker.setIconLabel(context.id);
recycledMarker.setIconStyle(dataItem.color); // recycledMarker.setIconStyle(dataItem.color);
return recycledMarker; // return recycledMarker;
} // }
this.SimpleMarker = SimpleMarker; this.SimpleMarker = SimpleMarker;
//返回一个新的Marker //返回一个新的Marker
return new SimpleMarker({ return new SimpleMarker({
@ -212,6 +233,8 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
}); });
if (this._pois?.length > 0) { if (this._pois?.length > 0) {
console.log(this._pois);
//展示该数据 //展示该数据
this.markerList.render(this._pois); this.markerList.render(this._pois);
} }
@ -241,7 +264,7 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
startNav() { startNav() {
this.navigator = this.pathSimplifierIns?.createPathNavigator(this.selectedIndex, { this.navigator = this.pathSimplifierIns?.createPathNavigator(this.selectedIndex, {
loop: true, //循环播放 loop: true, //循环播放
speed: 500000 * this.navSpeed //巡航速度,单位千米/小时 speed: 50000 * this.navSpeed //巡航速度,单位千米/小时
}); });
this.navigator?.start(); this.navigator?.start();
} }
@ -269,11 +292,11 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
} }
/** 根据标点经纬度获取地址信息 */ /** 根据标点经纬度获取地址信息 */
getPoiByPositon(position: string[]) { getPoiByPositon(label: string, color: string, position: string[], time: string) {
this.geocoder.getAddress(position, (status: any, result: any) => { this.geocoder.getAddress(position, (status: any, result: any) => {
if (status === 'complete' && result.info === 'OK') { if (status === 'complete' && result.info === 'OK') {
// result中对应详细地理坐标信息 // result中对应详细地理坐标信息
this._pois = [...this.pois, { markerLabel: '终', color: 'red', position: position, title: result.regeocode.formattedAddress }]; this._pois = [...this._pois, { markerLabel: label, color: color, position, title: result.regeocode.formattedAddress, time }];
if (this.markerList) { if (this.markerList) {
this.markerList.render(this._pois); this.markerList.render(this._pois);
} }
@ -287,7 +310,14 @@ export class AmapPathSimplifierComponent implements OnInit, OnChanges, OnDestroy
* @param infoItem * @param infoItem
*/ */
selectedPOI(infoItem: InfoItem) { selectedPOI(infoItem: InfoItem) {
this.infoWindow.setContent(infoItem.content || `地址: <pre>${infoItem.title}</pre>`); this.infoWindow.setContent(
infoItem.content ||
`
<label style="font-weight: bold;">${infoItem.title}</label><br/>
东经:${infoItem.position?.[0]}, 北纬:${infoItem.position?.[1]}<br/>
${infoItem.time}
`
);
this.infoWindow.open(this.aMap, infoItem.position); this.infoWindow.open(this.aMap, infoItem.position);
this.infoWindow.setPosition(infoItem.position); this.infoWindow.setPosition(infoItem.position);
// 地图定位居中 // 地图定位居中

View File

@ -114,6 +114,9 @@ export class AmapService {
} }
formatTime(time: string): string { formatTime(time: string): string {
if (!time) {
return '';
}
return `${time.slice(0, 4)}-${time.slice(4, 6)}-${time.slice(6, 8)} ${time.slice(9, 11)}:${time.slice(11, 13)}:${time.slice(13, 15)}`; return `${time.slice(0, 4)}-${time.slice(4, 6)}-${time.slice(6, 8)} ${time.slice(9, 11)}:${time.slice(11, 13)}:${time.slice(13, 15)}`;
} }
} }
@ -128,6 +131,7 @@ export interface POI {
export interface InfoItem { export interface InfoItem {
title?: string; title?: string;
content?: string; content?: string;
time?: string;
position: string[]; position: string[];
} }

View File

@ -34,7 +34,7 @@ import { IBase } from '../../interfaces';
import { EAFileUtil } from '../../utils'; import { EAFileUtil } from '../../utils';
@Injectable({ @Injectable({
providedIn: 'root', providedIn: 'root'
}) })
export class BaseService implements IBase { export class BaseService implements IBase {
// 新增实例接口地址 // 新增实例接口地址
@ -94,7 +94,7 @@ export class BaseService implements IBase {
parameter: any = {}, parameter: any = {},
method: 'POST' | 'GET', method: 'POST' | 'GET',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
if (paramType === 'FORM') { if (paramType === 'FORM') {
parameter = this.getFormData(parameter); parameter = this.getFormData(parameter);
@ -104,7 +104,7 @@ export class BaseService implements IBase {
return this.http return this.http
.request(method, url, { .request(method, url, {
body: paramInBody ? parameter : null, body: paramInBody ? parameter : null,
params: paramInBody ? null : parameter, params: paramInBody ? null : parameter
}) })
.pipe( .pipe(
map((res: any) => { map((res: any) => {
@ -122,7 +122,7 @@ export class BaseService implements IBase {
this.msgSrv.warning(res.msg); this.msgSrv.warning(res.msg);
return allowBadCode ? res : null; return allowBadCode ? res : null;
} }
}), })
); );
} }
@ -144,7 +144,7 @@ export class BaseService implements IBase {
parameter: any = {}, parameter: any = {},
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.httpRequest(url, parameter, method, paramInBody, paramType); return this.httpRequest(url, parameter, method, paramInBody, paramType);
} }
@ -154,7 +154,7 @@ export class BaseService implements IBase {
parameter: any = {}, parameter: any = {},
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.request(url, parameter, method, paramInBody, paramType).toPromise(); return this.request(url, parameter, method, paramInBody, paramType).toPromise();
} }
@ -165,7 +165,7 @@ export class BaseService implements IBase {
url: string = this.$api_add_one, url: string = this.$api_add_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -175,7 +175,7 @@ export class BaseService implements IBase {
url: string = this.$api_add_one, url: string = this.$api_add_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.addOne(parameter, url, method, paramInBody, paramType).toPromise(); return this.addOne(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -185,7 +185,7 @@ export class BaseService implements IBase {
url: string = this.$api_add_many, url: string = this.$api_add_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -195,7 +195,7 @@ export class BaseService implements IBase {
url: string = this.$api_add_many, url: string = this.$api_add_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.addMany(parameter, url, method, paramInBody, paramType).toPromise(); return this.addMany(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -206,7 +206,7 @@ export class BaseService implements IBase {
url: string = this.$api_del_one, url: string = this.$api_del_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -216,7 +216,7 @@ export class BaseService implements IBase {
url: string = this.$api_del_one, url: string = this.$api_del_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.delOne(parameter, url, method, paramInBody, paramType).toPromise(); return this.delOne(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -226,7 +226,7 @@ export class BaseService implements IBase {
url: string = this.$api_del_many, url: string = this.$api_del_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -236,7 +236,7 @@ export class BaseService implements IBase {
url: string = this.$api_del_many, url: string = this.$api_del_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.delMany(parameter, url, method, paramInBody, paramType).toPromise(); return this.delMany(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -247,7 +247,7 @@ export class BaseService implements IBase {
url: string = this.$api_edit_one, url: string = this.$api_edit_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -257,7 +257,7 @@ export class BaseService implements IBase {
url: string = this.$api_edit_one, url: string = this.$api_edit_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.updateOne(parameter, url, method, paramInBody, paramType).toPromise(); return this.updateOne(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -267,7 +267,7 @@ export class BaseService implements IBase {
url: string = this.$api_edit_many, url: string = this.$api_edit_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -277,7 +277,7 @@ export class BaseService implements IBase {
url: string = this.$api_edit_many, url: string = this.$api_edit_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.updateMany(parameter, url, method, paramInBody, paramType).toPromise(); return this.updateMany(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -290,7 +290,7 @@ export class BaseService implements IBase {
url: string = this.$api_get_one, url: string = this.$api_get_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any> { ): Observable<any> {
return this.request(url, parameter, method, paramInBody, paramType); return this.request(url, parameter, method, paramInBody, paramType);
} }
@ -300,7 +300,7 @@ export class BaseService implements IBase {
url: string = this.$api_get_one, url: string = this.$api_get_one,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any> { ): Promise<any> {
return this.getOne(parameter, url, method, paramInBody, paramType).toPromise(); return this.getOne(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -313,12 +313,12 @@ export class BaseService implements IBase {
url: string = this.$api_get_many, url: string = this.$api_get_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Observable<any[]> { ): Observable<any[]> {
return this.httpRequest(url, parameter, method, paramInBody, paramType).pipe( return this.httpRequest(url, parameter, method, paramInBody, paramType).pipe(
map((res) => { map(res => {
return (res as any[]) || []; return (res as any[]) || [];
}), })
); );
} }
@ -327,7 +327,7 @@ export class BaseService implements IBase {
url: string = this.$api_get_many, url: string = this.$api_get_many,
method: 'POST' | 'GET' = 'POST', method: 'POST' | 'GET' = 'POST',
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON'
): Promise<any[]> { ): Promise<any[]> {
return this.getMany(parameter, url, method, paramInBody, paramType).toPromise(); return this.getMany(parameter, url, method, paramInBody, paramType).toPromise();
} }
@ -352,19 +352,19 @@ export class BaseService implements IBase {
paramInBody: boolean = true, paramInBody: boolean = true,
paramType: 'JSON' | 'FORM' = 'JSON', paramType: 'JSON' | 'FORM' = 'JSON',
allowBadCode: boolean = true, allowBadCode: boolean = true,
async: boolean = true, async: boolean = true
): Observable<any> | Promise<any> { ): Observable<any> | Promise<any> {
if (allowBadCode) { if (allowBadCode) {
url += `?_allow_badcode=true`; url += `?_allow_badcode=true`;
} }
const response = this.httpRequest(url, parameter, method, paramInBody, paramType).pipe( const response = this.httpRequest(url, parameter, method, paramInBody, paramType).pipe(
tap((res) => { tap(res => {
if (res.success) { if (res.success) {
this.msgSrv.success(`创建下载任务成功,请前往下载任务列表下载您的文件!`); this.msgSrv.success(`创建下载任务成功,请前往下载任务列表下载您的文件!`);
window.open('#/download'); window.open('#/download');
} }
return res; return res;
}), })
); );
return async ? response.toPromise() : response; return async ? response.toPromise() : response;
} }
@ -396,11 +396,15 @@ export class BaseService implements IBase {
this.msgSrv.warning(m.msg); this.msgSrv.warning(m.msg);
return false; return false;
} }
}), })
) )
.toPromise(); .toPromise();
} }
openURL(url: string) {
window.open(url);
}
/** /**
* 直接下载文件 * 直接下载文件
*/ */
@ -464,19 +468,19 @@ export class BaseService implements IBase {
*/ */
getDict(key: string): Observable<any[]> { getDict(key: string): Observable<any[]> {
return this.http.post(this.$api_get_dict, { dict: key }).pipe( return this.http.post(this.$api_get_dict, { dict: key }).pipe(
map((res) => { map(res => {
if (res.success === true) { if (res.success === true) {
return res.data.map((r: any) => { return res.data.map((r: any) => {
return { return {
label: r.itemValue, label: r.itemValue,
value: r.itemKey, value: r.itemKey
}; };
}); });
} else { } else {
this.msgSrv.warning(`获取取字典【${key}】时发生错误:${res.msg || '未知错误!'}`); this.msgSrv.warning(`获取取字典【${key}】时发生错误:${res.msg || '未知错误!'}`);
return []; return [];
} }
}), })
); );
} }
@ -508,7 +512,7 @@ export class BaseService implements IBase {
if (paramsIndex > -1) { if (paramsIndex > -1) {
const paramsStr = url.substr(paramsIndex + 1); const paramsStr = url.substr(paramsIndex + 1);
const params = paramsStr.split('&'); const params = paramsStr.split('&');
const keyMap = params.find((e) => e.includes(paramName)); const keyMap = params.find(e => e.includes(paramName));
const value = keyMap ? keyMap.split('=')[1] : ''; const value = keyMap ? keyMap.split('=')[1] : '';
return value; return value;
} }

View File

@ -66,41 +66,47 @@ st {
} }
nz-range-picker { nz-range-picker {
width: 100%; width : 100%;
word-break: break-all; word-break: break-all;
word-wrap : break-word; word-wrap : break-word;
} }
.ant-select-tree .ant-select-tree-treenode-disabled { .ant-select-tree .ant-select-tree-treenode-disabled {
.ant-select-tree-checkbox { .ant-select-tree-checkbox {
margin: 0; margin: 0;
.ant-select-tree-checkbox-inner { .ant-select-tree-checkbox-inner {
width : 0px; width : 0px;
border-color: #ffffff !important; border-color: #ffffff !important;
}
} }
}
.ant-select-tree-node-content-wrapper { .ant-select-tree-node-content-wrapper {
color : unset; color : unset;
cursor: not-allowed; cursor: not-allowed;
} }
} }
.area-tree-select { .area-tree-select {
.ant-select-tree .ant-select-tree-treenode-disabled { .ant-select-tree .ant-select-tree-treenode-disabled {
.ant-select-tree-checkbox { .ant-select-tree-checkbox {
margin: 0; margin: 0;
.ant-select-tree-checkbox-inner { .ant-select-tree-checkbox-inner {
width : 0px; width : 0px;
border-color: #ffffff !important; border-color: #ffffff !important;
} }
}
.ant-select-tree-node-content-wrapper {
color : unset;
cursor: not-allowed;
}
} }
.ant-select-tree-node-content-wrapper {
color : unset;
cursor: not-allowed;
}
}
}
.print_order_select {
cdk-virtual-scroll-viewport {
min-height: 54px;
}
} }