This commit is contained in:
Taric Xin
2022-04-15 17:34:59 +08:00
parent aacf116e4b
commit df09ed518a
19 changed files with 688 additions and 707 deletions

View File

@ -58,7 +58,6 @@
<nz-card nzTitle="运单进度" #distannce1>
<div class="approval-status">
<div style="width: 60%; margin: 0 auto">
 
<nz-steps [nzCurrent]="i?.scheduleVOList?.length + 1" nzLabelPlacement="vertical">
<nz-step *ngFor="let item of i?.scheduleVOList" [nzTitle]="item.state" [nzSubtitle]="item.stateTime"
[nzDescription]="item.cancelReason ? '取消原因' + item.cancelReason : ''"
@ -207,38 +206,32 @@
</nz-card>
<nz-card>
<p class="detail_title" #distannce5><span>|</span> 轨迹信息</p>
<div nz-row>
<nz-card nzTitle="轨迹信息" style="width: 100%" [nzExtra]="extraTemplate" #distannce5>
<div nz-row>
<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>
</div>
<div nz-col [nzSpan]="12">
<amap-path-simplifier [mapWidth]="'100%'" [mapHeight]="'600px'" [mapList]="mapList" [pois]="pois">
</amap-path-simplifier>
</div>
</div>
</nz-card>
<ng-template #extraTemplate>
<nz-radio-group [(ngModel)]="trajectory" (ngModelChange)="trajectoryChange($event)">
<div nz-col [nzSpan]="24">
<amap-path-simplifier [mapWidth]="'100%'" [mapHeight]="'600px'" [mapList]="mapList" [pois]="pois">
</amap-path-simplifier>
<st [scroll]="{ y: '350px' }" #st [data]="addressItems" [columns]="logColumns2" [ps]="0"
[page]="{ show: false, showSize: false }" size="small" class="map_st">
</st>
<nz-radio-group [(ngModel)]="trajectory" (ngModelChange)="trajectoryChange($event)" class="map_radio">
<label nz-radio-button nzValue="car">车辆轨迹</label>
<label nz-radio-button nzValue="driver">司机轨迹</label>
</nz-radio-group>
</ng-template>
</div>
</div>
</nz-card>
<nz-card >
<nz-card>
<nz-tabset>
<nz-tab nzTitle="风险异常检测">
<div *ngIf="abnormalList.length > 0">
<div> 您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您! </div>
<div>如果您的运单没有问题可以提出申诉并提供相关资料我们将24小时内审核反馈</div>
<ul *ngFor="let item of abnormalList">
<li style="color: red;">系统识别:{{ item?.complianceTypeName }}</li>
<li style="color: red;">{{ item?.determineDetails }}</li>
</ul>
<div *ngIf="abnormalList.length > 0">
<div> 您的订单可能存在交易风险,请及时提交申诉材料,提交成功后,平台将及时完成审核并通知您! </div>
<div>如果您的运单没有问题可以提出申诉并提供相关资料我们将24小时内审核反馈</div>
<ul *ngFor="let item of abnormalList">
<li style="color: red;">系统识别:{{ item?.complianceTypeName }}</li>
<li style="color: red;">{{ item?.determineDetails }}</li>
</ul>
</div>
</nz-tab>
<nz-tab nzTitle="异常预警">
@ -254,7 +247,7 @@
{{item?.operator}}/{{item.telephone}}
</ng-template>
</st> -->
<app-logistics-time-line [data]="operationList"></app-logistics-time-line>
<app-logistics-time-line [data]="operationList"></app-logistics-time-line>
</nz-tab>
</nz-tabset>

View File

@ -19,7 +19,7 @@ import { OrderManagementService } from '../../services/order-management.service'
@Component({
selector: 'app-supply-management-vehicle-detail',
templateUrl: './vehicle-detail.component.html',
styleUrls: ['./vehicle-detail.component.less']
styleUrls: ['./vehicle-detail.component.less', '../../../commom/less/trajectory.less']
})
export class OrderManagementVehicleDetailComponent implements OnInit {
id = this.route.snapshot.params.id;
@ -46,7 +46,7 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
approvalLsit: any;
isVisible = false;
logColumns2: STColumn[] = [
{ title: '时间', index: 'parkBte' },
{ title: '时间', index: 'parkBte', width: 120, className: 'text-center' },
{ title: '地点', index: 'parkAdr' }
];
logColumns3: STColumn[] = [
@ -56,7 +56,7 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
operateLogColums: STColumn[] = [
{ title: '内容', index: 'operationContent' },
{ title: '操作人', render: 'operator' },
{ title: '操作时间', index: 'operatorTimestamp' },
{ title: '操作时间', index: 'operatorTimestamp' }
];
logColumns: STColumn[] = [
{ title: '款项', index: 'expenseCodeLabel' },
@ -84,7 +84,7 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
this.getTrajectory();
}
get logParams() {
return { operateObject: this.i?.billCode, operateTypeList: ['3','8'] }
return { operateObject: this.i?.billCode, operateTypeList: ['3', '8'] };
}
initData() {
this.service.request(this.service.$api_get_getWholeBillDetail, { id: this.id }).subscribe(res => {
@ -108,22 +108,24 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
time: '计划卸货时间:' + res.unloadPlanTime
}
];
this.service.request(this.service.$api_get_log_list,{operateObject: this.i?.billCode, operateTypeList: ['3','8']}).subscribe(res => {
if (res) {
console.log('操作日志');
console.log(res);
let a :any= []
res.records.forEach((item: any) => {
a.push({
value: `操作人: ${item.operator} <br /> 操作内容: ${ item.operationContent}`,
time: item.operatorTimestamp,
color: 'green'
})
})
console.log(a);
this.operationList = a;
}
});
this.service
.request(this.service.$api_get_log_list, { operateObject: this.i?.billCode, operateTypeList: ['3', '8'] })
.subscribe(res => {
if (res) {
console.log('操作日志');
console.log(res);
let a: any = [];
res.records.forEach((item: any) => {
a.push({
value: `操作人: ${item.operator} <br /> 操作内容: ${item.operationContent}`,
time: item.operatorTimestamp,
color: 'green'
});
});
console.log(a);
this.operationList = a;
}
});
this.billExpenses = this.i?.billExpenseDetails?.filter(
(data: any) => data.expenseCode === 'PRE' || data.expenseCode === 'RECE' || data.expenseCode === 'BACK'
);
@ -140,10 +142,9 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
if (res) {
console.log('异常预警');
console.log(res);
this.warringList = res
this.warringList = res;
}
});
}
// 取消订单
cancellation() {
@ -185,7 +186,7 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
this.isVisible = false;
}
goDistance(elf: NzCardComponent) {
goDistance(elf: any) {
if (elf) {
elf['elementRef'].nativeElement.scrollIntoView({ behavior: 'smooth', block: 'start', inline: 'start' });
// elf['elementRef'].nativeElement.className = 'target-fix'
@ -205,11 +206,14 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
});
});
this.mapList = list;
this.addressItems = res.parkArray;
if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => {
const addressItems: any[] = res.parkArray;
if (addressItems?.length > 0) {
addressItems.forEach(item => {
item.parkBte = this.getLocalTime(item.parkBte);
});
this.addressItems = [...addressItems];
} else {
this.addressItems = [];
}
}
});
@ -228,13 +232,17 @@ export class OrderManagementVehicleDetailComponent implements OnInit {
time: item.gtm
});
});
this.mapList = list;
this.addressItems = [...res.enclosureDataAppTrack];
if (this.addressItems && this.addressItems.length > 0) {
this.addressItems.forEach(item => {
item.vinOutTime = this.getLocalTime(item.gtm);
item.cityName = item.appAdress;
this.mapList = list || [];
const addressItems = [...res.tracks];
if (addressItems) {
addressItems.forEach(item => {
// item.parkBte = item.gtm;
item.parkBte = this.getLocalTime(item.gtm);
item.parkAdr = item.appAdress;
});
this.addressItems = [...addressItems];
} else {
this.addressItems = [];
}
}
});