Merge branch 'develop' of https://gitlab.eascs.com/tms-ui/tms-obc-web into develop
This commit is contained in:
		@ -4,7 +4,7 @@
 | 
				
			|||||||
 * @Author       : Shiming
 | 
					 * @Author       : Shiming
 | 
				
			||||||
 * @Date         : 2022-01-12 10:52:50
 | 
					 * @Date         : 2022-01-12 10:52:50
 | 
				
			||||||
 * @LastEditors  : Shiming
 | 
					 * @LastEditors  : Shiming
 | 
				
			||||||
 * @LastEditTime : 2022-02-24 20:03:23
 | 
					 * @LastEditTime : 2022-02-28 17:00:48
 | 
				
			||||||
 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\insurance-management\\components\\list\\list.component.html
 | 
					 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\insurance-management\\components\\list\\list.component.html
 | 
				
			||||||
 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
					 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
				
			||||||
-->
 | 
					-->
 | 
				
			||||||
@ -91,6 +91,11 @@
 | 
				
			|||||||
        <div>
 | 
					        <div>
 | 
				
			||||||
          {{ item?.billCode }}
 | 
					          {{ item?.billCode }}
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
 | 
					      </ng-template>
 | 
				
			||||||
 | 
					      <ng-template st-row="resourceCode" let-item let-index="index">
 | 
				
			||||||
 | 
					        <div>
 | 
				
			||||||
 | 
					          {{ item?.resourceCode }}
 | 
				
			||||||
 | 
					        </div>
 | 
				
			||||||
        <div>
 | 
					        <div>
 | 
				
			||||||
          {{ item?.resourceStatusLabel }}
 | 
					          {{ item?.resourceStatusLabel }}
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -412,7 +412,7 @@ export class insuranceManagementListComponent implements OnInit {
 | 
				
			|||||||
      {
 | 
					      {
 | 
				
			||||||
        title: '货源编号',
 | 
					        title: '货源编号',
 | 
				
			||||||
        className: 'text-right',
 | 
					        className: 'text-right',
 | 
				
			||||||
        index: 'resourceCode',
 | 
					        render: 'resourceCode',
 | 
				
			||||||
        width: '150px'
 | 
					        width: '150px'
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      {
 | 
					      {
 | 
				
			||||||
 | 
				
			|||||||
@ -12,6 +12,7 @@ import { VehicleFreightPeopleComponent } from '../../modal/vehicle/freight-peopl
 | 
				
			|||||||
import { VehicleModifyCaptainComponent } from '../../modal/vehicle/modify-captain/modify-captain.component';
 | 
					import { VehicleModifyCaptainComponent } from '../../modal/vehicle/modify-captain/modify-captain.component';
 | 
				
			||||||
import { VehicleModifyRateComponent } from '../../modal/vehicle/modify-rate/modify-rate.component';
 | 
					import { VehicleModifyRateComponent } from '../../modal/vehicle/modify-rate/modify-rate.component';
 | 
				
			||||||
import { VehicleUpdateFreightComponent } from '../../modal/vehicle/update-freight/update-freight.component';
 | 
					import { VehicleUpdateFreightComponent } from '../../modal/vehicle/update-freight/update-freight.component';
 | 
				
			||||||
 | 
					import { OneCarOrderViewtrackComponent } from '../../modal/vehicle/view-track/view-track.component';
 | 
				
			||||||
import { OrderManagementService } from '../../services/order-management.service';
 | 
					import { OrderManagementService } from '../../services/order-management.service';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -458,8 +459,8 @@ resourceStatus: any;
 | 
				
			|||||||
          },
 | 
					          },
 | 
				
			||||||
          {
 | 
					          {
 | 
				
			||||||
            text: '查看轨迹 ',
 | 
					            text: '查看轨迹 ',
 | 
				
			||||||
            click: (_record) => this.cancellation(_record),
 | 
					            click: (_record) => this.viewTrack(_record),
 | 
				
			||||||
            iif: item => item.billStatus == '4' || item.billStatus == '5' || item.billStatus == '2' || item.billStatus == '3',
 | 
					            iif: item => item.billStatus !== '1' && item.billStatus !== '6',
 | 
				
			||||||
            // acl: { ability: ['VEHICLE-LIST-view'] },
 | 
					            // acl: { ability: ['VEHICLE-LIST-view'] },
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
          
 | 
					          
 | 
				
			||||||
@ -856,4 +857,22 @@ resourceStatus: any;
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					   *查看轨迹
 | 
				
			||||||
 | 
					   */
 | 
				
			||||||
 | 
					   viewTrack(item: any) {
 | 
				
			||||||
 | 
					    const modalRef = this.modal.create({
 | 
				
			||||||
 | 
					      nzTitle: '查看轨迹',
 | 
				
			||||||
 | 
					      nzContent: OneCarOrderViewtrackComponent,
 | 
				
			||||||
 | 
					      nzWidth: 1200,
 | 
				
			||||||
 | 
					      nzComponentParams: {
 | 
				
			||||||
 | 
					        i: item,
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      nzFooter: null
 | 
				
			||||||
 | 
					    });
 | 
				
			||||||
 | 
					    modalRef.afterClose.subscribe((res: boolean) => {
 | 
				
			||||||
 | 
					      if(res) {
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    });
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -4,7 +4,7 @@
 | 
				
			|||||||
 * @Author       : Shiming
 | 
					 * @Author       : Shiming
 | 
				
			||||||
 * @Date         : 2022-02-22 13:53:29
 | 
					 * @Date         : 2022-02-22 13:53:29
 | 
				
			||||||
 * @LastEditors  : Shiming
 | 
					 * @LastEditors  : Shiming
 | 
				
			||||||
 * @LastEditTime : 2022-02-22 15:51:53
 | 
					 * @LastEditTime : 2022-02-28 15:56:46
 | 
				
			||||||
 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\cancel-confirm\\cancel-confirm.component.ts
 | 
					 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\cancel-confirm\\cancel-confirm.component.ts
 | 
				
			||||||
 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
					 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
@ -75,8 +75,7 @@ export class OneCarOrderCancelConfirmComponent implements OnInit {
 | 
				
			|||||||
  initData() {
 | 
					  initData() {
 | 
				
			||||||
    let indexId = 0
 | 
					    let indexId = 0
 | 
				
			||||||
    let index = 0
 | 
					    let index = 0
 | 
				
			||||||
    console.log(this.i);
 | 
					    let indexSurcharge = 0
 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    this.i?.mybidDetailInfo.forEach((ele: any) => {
 | 
					    this.i?.mybidDetailInfo.forEach((ele: any) => {
 | 
				
			||||||
      if(this.sts == 1) {
 | 
					      if(this.sts == 1) {
 | 
				
			||||||
        // 大宗
 | 
					        // 大宗
 | 
				
			||||||
@ -85,25 +84,21 @@ export class OneCarOrderCancelConfirmComponent implements OnInit {
 | 
				
			|||||||
        }
 | 
					        }
 | 
				
			||||||
        if (ele?.paymentStatusLabel == '已支付') {
 | 
					        if (ele?.paymentStatusLabel == '已支付') {
 | 
				
			||||||
          indexId += 1;
 | 
					          indexId += 1;
 | 
				
			||||||
 | 
					          indexSurcharge += ele?.surcharge;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
        // 整车
 | 
					        // 整车
 | 
				
			||||||
        if (ele?.paymentStatusLabel == '已支付') {
 | 
					        if (ele?.paymentStatusLabel == '已支付') {
 | 
				
			||||||
          indexId += 1;
 | 
					          indexId += 1;
 | 
				
			||||||
          index += ele?.price;
 | 
					          index += ele?.price;
 | 
				
			||||||
 | 
					          indexSurcharge += ele?.surcharge;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        console.log(ele.expenseCode)
 | 
					        console.log(ele.expenseCode)
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      if (ele.expenseCode == '"ATT"' || ele.expenseCode == 'ATT'){
 | 
					 | 
				
			||||||
        if(ele?.paymentStatusLabel == '已支付') {
 | 
					 | 
				
			||||||
          this.ATTPrice = ele.price;
 | 
					 | 
				
			||||||
        } else {
 | 
					 | 
				
			||||||
          this.ATTPrice = 0;
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
    this.index = indexId
 | 
					    this.index = indexId
 | 
				
			||||||
    this.List = index
 | 
					    this.List = index
 | 
				
			||||||
 | 
					    this.ATTPrice = indexSurcharge
 | 
				
			||||||
    console.log(this.index)
 | 
					    console.log(this.index)
 | 
				
			||||||
    console.log(this.List)
 | 
					    console.log(this.List)
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
				
			|||||||
@ -0,0 +1,34 @@
 | 
				
			|||||||
 | 
					<!--
 | 
				
			||||||
 | 
					 * @Description  : 
 | 
				
			||||||
 | 
					 * @Version      : 1.0
 | 
				
			||||||
 | 
					 * @Author       : Shiming
 | 
				
			||||||
 | 
					 * @Date         : 2022-02-22 13:53:29
 | 
				
			||||||
 | 
					 * @LastEditors  : Shiming
 | 
				
			||||||
 | 
					 * @LastEditTime : 2022-02-28 16:47:04
 | 
				
			||||||
 | 
					 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\view-track\\view-track.component.html
 | 
				
			||||||
 | 
					 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
				
			||||||
 | 
					-->
 | 
				
			||||||
 | 
					  <div nz-row>
 | 
				
			||||||
 | 
					    <nz-card nzTitle="轨迹信息"   [nzExtra]="extraTemplate" >
 | 
				
			||||||
 | 
					      <div nz-row>
 | 
				
			||||||
 | 
					        <div nz-col [nzSpan]="12">
 | 
				
			||||||
 | 
					          <st #st [data]="i?.auditRecordList" [columns]="logColumns" [ps]="0" [page]="{ show: false, showSize: false }">
 | 
				
			||||||
 | 
					    </st>
 | 
				
			||||||
 | 
					        </div>
 | 
				
			||||||
 | 
					        <div nz-col [nzSpan]="12" class="mapBox">
 | 
				
			||||||
 | 
					          <amap-path-simplifier [mapWidth]="'400px'" [MapList]="MapList"></amap-path-simplifier>
 | 
				
			||||||
 | 
					        </div>
 | 
				
			||||||
 | 
					      </div>
 | 
				
			||||||
 | 
					    </nz-card>
 | 
				
			||||||
 | 
					    <ng-template #extraTemplate>
 | 
				
			||||||
 | 
					      <nz-radio-group [(ngModel)]="trajectory">
 | 
				
			||||||
 | 
					        <label nz-radio-button nzValue="car">车辆轨迹</label>
 | 
				
			||||||
 | 
					        <label nz-radio-button nzValue="driver">司机轨迹</label>
 | 
				
			||||||
 | 
					      </nz-radio-group>
 | 
				
			||||||
 | 
					    </ng-template>
 | 
				
			||||||
 | 
					  </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					<div class="modal-footer">
 | 
				
			||||||
 | 
					  <button nz-button type="button" (click)="close(false)">取消</button>
 | 
				
			||||||
 | 
					  <button nz-button type="submit" nzType="primary" (click)="close(true)">确认</button>
 | 
				
			||||||
 | 
					</div>
 | 
				
			||||||
@ -0,0 +1,11 @@
 | 
				
			|||||||
 | 
					:host {
 | 
				
			||||||
 | 
					     ::ng-deep {
 | 
				
			||||||
 | 
					       .mapBox {
 | 
				
			||||||
 | 
					          iframe, canvas {
 | 
				
			||||||
 | 
					                 width: 400px !important;
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					       }
 | 
				
			||||||
 | 
					 
 | 
				
			||||||
 | 
					     }
 | 
				
			||||||
 | 
					   
 | 
				
			||||||
 | 
					 }
 | 
				
			||||||
@ -0,0 +1,98 @@
 | 
				
			|||||||
 | 
					/*
 | 
				
			||||||
 | 
					 * @Description  : 
 | 
				
			||||||
 | 
					 * @Version      : 1.0
 | 
				
			||||||
 | 
					 * @Author       : Shiming
 | 
				
			||||||
 | 
					 * @Date         : 2022-02-22 13:53:29
 | 
				
			||||||
 | 
					 * @LastEditors  : Shiming
 | 
				
			||||||
 | 
					 * @LastEditTime : 2022-02-28 14:37:42
 | 
				
			||||||
 | 
					 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\view-track\\view-track.component.ts
 | 
				
			||||||
 | 
					 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
				
			||||||
 | 
					 */
 | 
				
			||||||
 | 
					import { Component, OnInit, ViewChild } from '@angular/core';
 | 
				
			||||||
 | 
					import { STColumn } from '@delon/abc/st';
 | 
				
			||||||
 | 
					import {
 | 
				
			||||||
 | 
					  SFComponent,
 | 
				
			||||||
 | 
					  SFCustomWidgetSchema,
 | 
				
			||||||
 | 
					  SFNumberWidgetSchema,
 | 
				
			||||||
 | 
					  SFRadioWidgetSchema,
 | 
				
			||||||
 | 
					  SFSchema,
 | 
				
			||||||
 | 
					  SFTextareaWidgetSchema,
 | 
				
			||||||
 | 
					  SFUISchema
 | 
				
			||||||
 | 
					} from '@delon/form';
 | 
				
			||||||
 | 
					import format from 'date-fns/format';
 | 
				
			||||||
 | 
					import { _HttpClient } from '@delon/theme';
 | 
				
			||||||
 | 
					import { NzMessageService } from 'ng-zorro-antd/message';
 | 
				
			||||||
 | 
					import { NzModalRef, NzModalService } from 'ng-zorro-antd/modal';
 | 
				
			||||||
 | 
					import { OrderManagementService } from '../../../services/order-management.service';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@Component({
 | 
				
			||||||
 | 
					  selector: 'app-order-management-view-track',
 | 
				
			||||||
 | 
					  styleUrls: ['./view-track.component.less'],
 | 
				
			||||||
 | 
					  templateUrl: './view-track.component.html'
 | 
				
			||||||
 | 
					})
 | 
				
			||||||
 | 
					export class OneCarOrderViewtrackComponent implements OnInit {
 | 
				
			||||||
 | 
					  i: any;     // 单行数据
 | 
				
			||||||
 | 
					  MapList: any;     // 地图数据
 | 
				
			||||||
 | 
					  trajectory = 'car';
 | 
				
			||||||
 | 
					  addressItems: any[] = []; //打点地址数据组
 | 
				
			||||||
 | 
					  logColumns: STColumn[] = [
 | 
				
			||||||
 | 
					    { title: '款项', index: 'expenseCodeLabel' },
 | 
				
			||||||
 | 
					    { title: '小计(元)', render: 'price' },
 | 
				
			||||||
 | 
					    { title: '运输费(元)', render: 'price' },
 | 
				
			||||||
 | 
					    { title: '附加费(元)', render: 'surcharge' },
 | 
				
			||||||
 | 
					    { title: '支付时间', index: 'paymentTime' },
 | 
				
			||||||
 | 
					    {
 | 
				
			||||||
 | 
					      title: '支付状态',
 | 
				
			||||||
 | 
					      className: 'text-center',
 | 
				
			||||||
 | 
					      index: 'paymentStatus',
 | 
				
			||||||
 | 
					      type: 'badge',
 | 
				
			||||||
 | 
					      width: '120px',
 | 
				
			||||||
 | 
					      badge: {
 | 
				
			||||||
 | 
					        '1': { text: '待申请', color: 'warning' },
 | 
				
			||||||
 | 
					        '2': { text: '已支付', color: 'success' },
 | 
				
			||||||
 | 
					        '3': { text: '已拒绝', color: 'warning' },
 | 
				
			||||||
 | 
					        '4': { text: '申请中', color: 'warning' }
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  ];
 | 
				
			||||||
 | 
					  constructor(
 | 
				
			||||||
 | 
					    private modalRef: NzModalRef,
 | 
				
			||||||
 | 
					    private modal: NzModalService,
 | 
				
			||||||
 | 
					    private msgSrv: NzMessageService,
 | 
				
			||||||
 | 
					    public service: OrderManagementService
 | 
				
			||||||
 | 
					  ) {}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ngOnInit(): void {
 | 
				
			||||||
 | 
					    console.log(this.i);
 | 
				
			||||||
 | 
					    this.MapInit();
 | 
				
			||||||
 | 
					  
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					    // 获取轨迹
 | 
				
			||||||
 | 
					    MapInit() {
 | 
				
			||||||
 | 
					      this.service.request(this.service.$api_get_getTrajectory, { id: this.i.id }).subscribe(res => {
 | 
				
			||||||
 | 
					        if (res) {
 | 
				
			||||||
 | 
					          const points = res.trackArray;
 | 
				
			||||||
 | 
					          points?.forEach((item: any) => {
 | 
				
			||||||
 | 
					            this.MapList.push({
 | 
				
			||||||
 | 
					              name: item.hgt,
 | 
				
			||||||
 | 
					              lnglat: [Number((Number(item.lon) / 600000).toFixed(6)), Number((Number(item.lat) / 600000).toFixed(6))]
 | 
				
			||||||
 | 
					            });
 | 
				
			||||||
 | 
					          });
 | 
				
			||||||
 | 
					          this.addressItems = res.parkArray;
 | 
				
			||||||
 | 
					          if (this.addressItems && this.addressItems.length > 0) {
 | 
				
			||||||
 | 
					            this.addressItems.forEach(item => {
 | 
				
			||||||
 | 
					              item.parkBte = this.getLocalTime(item.parkBte);
 | 
				
			||||||
 | 
					              item.parkEte = this.getLocalTime(item.parkEte);
 | 
				
			||||||
 | 
					            });
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  close(value: boolean): void {
 | 
				
			||||||
 | 
					        this.modalRef.close(false);
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					  getLocalTime(time: any) {
 | 
				
			||||||
 | 
					    return format(new Date(parseInt(time)), 'yyyy-MM-dd HH:mm:ss');
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
@ -36,6 +36,7 @@ import { VehicleModifyRateComponent } from './modal/vehicle/modify-rate/modify-r
 | 
				
			|||||||
import { VehicleSureArriveComponent } from './modal/vehicle/sure-arrive/sure-arrive.component';
 | 
					import { VehicleSureArriveComponent } from './modal/vehicle/sure-arrive/sure-arrive.component';
 | 
				
			||||||
import { VehicleSureDepartComponent } from './modal/vehicle/sure-depart/sure-depart.component';
 | 
					import { VehicleSureDepartComponent } from './modal/vehicle/sure-depart/sure-depart.component';
 | 
				
			||||||
import { VehicleUpdateFreightComponent } from './modal/vehicle/update-freight/update-freight.component';
 | 
					import { VehicleUpdateFreightComponent } from './modal/vehicle/update-freight/update-freight.component';
 | 
				
			||||||
 | 
					import { OneCarOrderViewtrackComponent } from './modal/vehicle/view-track/view-track.component';
 | 
				
			||||||
import { OrderManagementRoutingModule } from './order-management-routing.module';
 | 
					import { OrderManagementRoutingModule } from './order-management-routing.module';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const COMPONENTS: Type<void>[] = [
 | 
					const COMPONENTS: Type<void>[] = [
 | 
				
			||||||
@ -62,7 +63,8 @@ const COMPONENTS: Type<void>[] = [
 | 
				
			|||||||
  OrderManagementReceiptsAuditComponent,
 | 
					  OrderManagementReceiptsAuditComponent,
 | 
				
			||||||
  orderManagementVoucherViewComponent,
 | 
					  orderManagementVoucherViewComponent,
 | 
				
			||||||
  OrderManagementComplianceAuditComponent,
 | 
					  OrderManagementComplianceAuditComponent,
 | 
				
			||||||
  OneCarOrderCancelConfirmComponent
 | 
					  OneCarOrderCancelConfirmComponent,
 | 
				
			||||||
 | 
					  OneCarOrderViewtrackComponent
 | 
				
			||||||
];
 | 
					];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@NgModule({
 | 
					@NgModule({
 | 
				
			||||||
 | 
				
			|||||||
@ -412,6 +412,7 @@ export class SupplyManagementBulkPublishComponent implements OnInit {
 | 
				
			|||||||
        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
					        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carModel: {
 | 
					      $carModel: {
 | 
				
			||||||
 | 
					        spanLabelFixed: 120,
 | 
				
			||||||
        grid: { span: 8 }
 | 
					        grid: { span: 8 }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carLength: {
 | 
					      $carLength: {
 | 
				
			||||||
 | 
				
			|||||||
@ -435,6 +435,7 @@ export class SupplyManagementBulkReleasePublishComponent implements OnInit {
 | 
				
			|||||||
        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
					        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carModel: {
 | 
					      $carModel: {
 | 
				
			||||||
 | 
					        spanLabelFixed: 120,
 | 
				
			||||||
        grid: { span: 8 }
 | 
					        grid: { span: 8 }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carLength: {
 | 
					      $carLength: {
 | 
				
			||||||
 | 
				
			|||||||
@ -33,10 +33,10 @@
 | 
				
			|||||||
                </nz-input-group>
 | 
					                </nz-input-group>
 | 
				
			||||||
              
 | 
					              
 | 
				
			||||||
                <span *ngIf="idx !== 0" [ngClass]="idx == 0 ? 'hides' : ''" style="padding: 0 10px"
 | 
					                <span *ngIf="idx !== 0" [ngClass]="idx == 0 ? 'hides' : ''" style="padding: 0 10px"
 | 
				
			||||||
                  ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx, data.id)"></i
 | 
					                  ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
 | 
				
			||||||
                ></span>
 | 
					                ></span>
 | 
				
			||||||
                <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"
 | 
					                <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"
 | 
				
			||||||
                  ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx, data.id)"></i
 | 
					                  ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
 | 
				
			||||||
                ></span>
 | 
					                ></span>
 | 
				
			||||||
              </div>
 | 
					              </div>
 | 
				
			||||||
            </nz-form-control>
 | 
					            </nz-form-control>
 | 
				
			||||||
@ -69,7 +69,7 @@
 | 
				
			|||||||
          </nz-form-item>
 | 
					          </nz-form-item>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <div style="display: flex; justify-content: center">
 | 
					        <div style="display: flex; justify-content: center">
 | 
				
			||||||
          <button nz-button nzType="primary" (click)="addStartInfo($event)">
 | 
					          <button nz-button nzType="primary" (click)="addStartInfo()">
 | 
				
			||||||
            <i nz-icon nzType="plus"></i>
 | 
					            <i nz-icon nzType="plus"></i>
 | 
				
			||||||
            添加装货地
 | 
					            添加装货地
 | 
				
			||||||
          </button>
 | 
					          </button>
 | 
				
			||||||
@ -98,7 +98,7 @@
 | 
				
			|||||||
                </nz-input-group>
 | 
					                </nz-input-group>
 | 
				
			||||||
                <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subEndInfo($event, idx)"></i></span>
 | 
					                <span *ngIf="idx !== 0" style="padding: 0 10px"><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subEndInfo($event, idx)"></i></span>
 | 
				
			||||||
                <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"
 | 
					                <span *ngIf="idx == 0" style="visibility:hidden;padding: 0 10px"
 | 
				
			||||||
                ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx, data.id)"></i
 | 
					                ><i nz-icon nzType="minus-circle" nzTheme="outline" style="color: #d9001b" (click)="subStartInfo($event, idx)"></i
 | 
				
			||||||
              ></span>
 | 
					              ></span>
 | 
				
			||||||
              </div>
 | 
					              </div>
 | 
				
			||||||
            </nz-form-control>
 | 
					            </nz-form-control>
 | 
				
			||||||
@ -131,7 +131,7 @@
 | 
				
			|||||||
          </nz-form-item>
 | 
					          </nz-form-item>
 | 
				
			||||||
        </div>
 | 
					        </div>
 | 
				
			||||||
        <div style="display: flex; justify-content: center">
 | 
					        <div style="display: flex; justify-content: center">
 | 
				
			||||||
          <button nz-button nzType="primary" (click)="addEndInfo($event)">
 | 
					          <button nz-button nzType="primary" (click)="addEndInfo()">
 | 
				
			||||||
            <i nz-icon nzType="plus"></i>
 | 
					            <i nz-icon nzType="plus"></i>
 | 
				
			||||||
            添加卸货地
 | 
					            添加卸货地
 | 
				
			||||||
          </button>
 | 
					          </button>
 | 
				
			||||||
@ -146,9 +146,8 @@
 | 
				
			|||||||
            <nz-date-picker
 | 
					            <nz-date-picker
 | 
				
			||||||
            nzShowTime
 | 
					            nzShowTime
 | 
				
			||||||
            nzFormat="yyyy-MM-dd HH:mm:ss"
 | 
					            nzFormat="yyyy-MM-dd HH:mm:ss"
 | 
				
			||||||
              [ngModel]="loadingTime"
 | 
					            formControlName="loadingTime"
 | 
				
			||||||
              (ngModelChange)="changeLO($event)"
 | 
					            [nzDisabledDate]="disabledDateStart"
 | 
				
			||||||
              [ngModelOptions]="{ standalone: true }"
 | 
					 | 
				
			||||||
          ></nz-date-picker>
 | 
					          ></nz-date-picker>
 | 
				
			||||||
          </nz-form-control>
 | 
					          </nz-form-control>
 | 
				
			||||||
        </nz-form-item>
 | 
					        </nz-form-item>
 | 
				
			||||||
@ -158,13 +157,7 @@
 | 
				
			|||||||
        <nz-form-item>
 | 
					        <nz-form-item>
 | 
				
			||||||
          <nz-form-label [nzSpan]="5" nzRequired>卸货时间</nz-form-label>
 | 
					          <nz-form-label [nzSpan]="5" nzRequired>卸货时间</nz-form-label>
 | 
				
			||||||
          <nz-form-control [nzErrorTip]="'请输入卸货时间'">
 | 
					          <nz-form-control [nzErrorTip]="'请输入卸货时间'">
 | 
				
			||||||
            <nz-date-picker
 | 
					            <nz-date-picker nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss" formControlName="unloadingTime"></nz-date-picker>
 | 
				
			||||||
              nzShowTime
 | 
					 | 
				
			||||||
              nzFormat="yyyy-MM-dd HH:mm:ss"
 | 
					 | 
				
			||||||
              [ngModel]="unloadingTime"
 | 
					 | 
				
			||||||
              (ngModelChange)="changeUn($event)"
 | 
					 | 
				
			||||||
              [ngModelOptions]="{ standalone: true }"
 | 
					 | 
				
			||||||
            ></nz-date-picker>
 | 
					 | 
				
			||||||
          </nz-form-control>
 | 
					          </nz-form-control>
 | 
				
			||||||
        </nz-form-item>
 | 
					        </nz-form-item>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
@ -172,13 +165,14 @@
 | 
				
			|||||||
    <ng-template #endInconTemp1><i nz-icon nzType="global"></i></ng-template>
 | 
					    <ng-template #endInconTemp1><i nz-icon nzType="global"></i></ng-template>
 | 
				
			||||||
  </form>
 | 
					  </form>
 | 
				
			||||||
</nz-card>
 | 
					</nz-card>
 | 
				
			||||||
 | 
					 | 
				
			||||||
<nz-card>
 | 
					<nz-card>
 | 
				
			||||||
  <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="16">
 | 
				
			||||||
      <sf #sf3 [schema]="schema3" [formData]="sf3data" [button]="'none'" [ui]="ui3"></sf>
 | 
					      <sf #sf3 [schema]="schema3" [button]="'none'" [ui]="ui3" [formData]="sf3data"></sf>
 | 
				
			||||||
      <sf #sf4 [schema]="schema4" [formData]="sf4data" [button]="'none'" [ui]="ui4">
 | 
					    </div>
 | 
				
			||||||
 | 
					  </div>
 | 
				
			||||||
 | 
					  <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]="'吨'">
 | 
				
			||||||
        <input
 | 
					        <input
 | 
				
			||||||
@ -189,6 +183,7 @@
 | 
				
			|||||||
          step="0.01"
 | 
					          step="0.01"
 | 
				
			||||||
          (ngModelChange)="i.setValue($event)"
 | 
					          (ngModelChange)="i.setValue($event)"
 | 
				
			||||||
          placeholder="总重量,必填"
 | 
					          placeholder="总重量,必填"
 | 
				
			||||||
 | 
					          oninput="if(value>99999)value=99999;if(value<0)value=0"
 | 
				
			||||||
        />
 | 
					        />
 | 
				
			||||||
      </nz-input-group>
 | 
					      </nz-input-group>
 | 
				
			||||||
    </ng-template>
 | 
					    </ng-template>
 | 
				
			||||||
@ -201,26 +196,25 @@
 | 
				
			|||||||
          min="0"
 | 
					          min="0"
 | 
				
			||||||
          step="0.01"
 | 
					          step="0.01"
 | 
				
			||||||
          (ngModelChange)="i.setValue($event)"
 | 
					          (ngModelChange)="i.setValue($event)"
 | 
				
			||||||
              placeholder="总体积"
 | 
					          placeholder="体积"
 | 
				
			||||||
 | 
					          oninput="if(value>99999)value=99999;if(value<0)value=0"
 | 
				
			||||||
        />
 | 
					        />
 | 
				
			||||||
      </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]="'件'">
 | 
				
			||||||
        <input
 | 
					        <input
 | 
				
			||||||
          nz-input
 | 
					          nz-input
 | 
				
			||||||
          type="number"
 | 
					          type="number"
 | 
				
			||||||
          [ngModel]="i.value"
 | 
					          [ngModel]="i.value"
 | 
				
			||||||
          min="0"
 | 
					          min="0"
 | 
				
			||||||
              step="0.01"
 | 
					 | 
				
			||||||
          (ngModelChange)="i.setValue($event)"
 | 
					          (ngModelChange)="i.setValue($event)"
 | 
				
			||||||
              placeholder="总车次"
 | 
					          placeholder="车次"
 | 
				
			||||||
 | 
					          oninput="if(value>99999)value=99999;if(value<0)value=0"
 | 
				
			||||||
        />
 | 
					        />
 | 
				
			||||||
      </nz-input-group>
 | 
					      </nz-input-group>
 | 
				
			||||||
    </ng-template>
 | 
					    </ng-template>
 | 
				
			||||||
  </sf>
 | 
					  </sf>
 | 
				
			||||||
    </div>
 | 
					 | 
				
			||||||
  </div>
 | 
					 | 
				
			||||||
</nz-card>
 | 
					</nz-card>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
<nz-card>
 | 
					<nz-card>
 | 
				
			||||||
@ -239,7 +233,7 @@
 | 
				
			|||||||
              [nzMin]="50000"
 | 
					              [nzMin]="50000"
 | 
				
			||||||
              [nzMax]="3000000"
 | 
					              [nzMax]="3000000"
 | 
				
			||||||
              [nzStep]="0.01"
 | 
					              [nzStep]="0.01"
 | 
				
			||||||
              (ngModelChange)="i.setValue($event);getInsurersPrice($event)"
 | 
					              (ngModelChange)="i.setValue($event);getInsurersPrice()"
 | 
				
			||||||
              nzPlaceHolder="请输入50000-3000000之间数值"
 | 
					              nzPlaceHolder="请输入50000-3000000之间数值"
 | 
				
			||||||
            ></nz-input-number>
 | 
					            ></nz-input-number>
 | 
				
			||||||
          </div>
 | 
					          </div>
 | 
				
			||||||
@ -353,7 +347,7 @@
 | 
				
			|||||||
    acl  [acl-ability]="['SUPPLY-VEHICLE-AMEND-submitChange']">提交修改</button
 | 
					    acl  [acl-ability]="['SUPPLY-VEHICLE-AMEND-submitChange']">提交修改</button
 | 
				
			||||||
    >
 | 
					    >
 | 
				
			||||||
    <button nz-button nzType="primary" *ngIf="this.PageStatus == '整车下一单'" (click)="submitConfirm('assign')" acl  [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleDesignate']">指派熟车</button>
 | 
					    <button nz-button nzType="primary" *ngIf="this.PageStatus == '整车下一单'" (click)="submitConfirm('assign')" acl  [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleDesignate']">指派熟车</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" (click)="submitConfirm('publish')"
 | 
				
			||||||
    acl  [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleAnotherOrder']">司机抢单</button
 | 
					    acl  [acl-ability]="['SUPPLY-BULK-PLACEORDER-vehicleAnotherOrder']">司机抢单</button
 | 
				
			||||||
    >
 | 
					    >
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -1,6 +1,7 @@
 | 
				
			|||||||
import { Component, OnInit, ViewChild } from '@angular/core';
 | 
					import { Component, OnInit, ViewChild } from '@angular/core';
 | 
				
			||||||
import { debounceTime } from 'rxjs/operators';
 | 
					 | 
				
			||||||
import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
 | 
					import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
 | 
				
			||||||
 | 
					import differenceInCalendarDays from 'date-fns/differenceInCalendarDays';
 | 
				
			||||||
 | 
					import format from 'date-fns/format';
 | 
				
			||||||
import { Subject } from 'rxjs';
 | 
					import { Subject } from 'rxjs';
 | 
				
			||||||
import { ActivatedRoute, Router } from '@angular/router';
 | 
					import { ActivatedRoute, Router } from '@angular/router';
 | 
				
			||||||
import {
 | 
					import {
 | 
				
			||||||
@ -14,9 +15,8 @@ import {
 | 
				
			|||||||
  SFUISchema
 | 
					  SFUISchema
 | 
				
			||||||
} from '@delon/form';
 | 
					} from '@delon/form';
 | 
				
			||||||
import { _HttpClient } from '@delon/theme';
 | 
					import { _HttpClient } from '@delon/theme';
 | 
				
			||||||
import { AmapPoiPickerComponent, AmapService, ShipperBaseService } from '@shared';
 | 
					import { AmapPoiPickerComponent, AmapService, EACacheService, ShipperBaseService } from '@shared';
 | 
				
			||||||
import { NzModalService } from 'ng-zorro-antd/modal';
 | 
					import { NzModalService } from 'ng-zorro-antd/modal';
 | 
				
			||||||
import { type } from 'os';
 | 
					 | 
				
			||||||
import { of } from 'rxjs';
 | 
					import { of } from 'rxjs';
 | 
				
			||||||
import { map } from 'rxjs/operators';
 | 
					import { map } from 'rxjs/operators';
 | 
				
			||||||
import { SupplyManagementService } from '../../services/supply-management.service';
 | 
					import { SupplyManagementService } from '../../services/supply-management.service';
 | 
				
			||||||
@ -24,13 +24,22 @@ import { SupplyManagementVehicleAssignedCarComponent } from '../assigned-car/ass
 | 
				
			|||||||
import { TranAgreementComponent } from '../tran-agreement/tran-agreement.component';
 | 
					import { TranAgreementComponent } from '../tran-agreement/tran-agreement.component';
 | 
				
			||||||
import { PublishAddressListComponent } from './address-list/address-list.component';
 | 
					import { PublishAddressListComponent } from './address-list/address-list.component';
 | 
				
			||||||
import { PublishSuccessComponent } from './publish-success/publish-success.component';
 | 
					import { PublishSuccessComponent } from './publish-success/publish-success.component';
 | 
				
			||||||
 | 
					import { cacheConf } from '@conf/cache.conf';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@Component({
 | 
					@Component({
 | 
				
			||||||
  selector: 'app-publish-goods-onecar-publish',
 | 
					  selector: 'app-publish-goods-onecar-publish',
 | 
				
			||||||
  templateUrl: './onecar-publish.component.html',
 | 
					  templateUrl: './onecar-publish.component.html',
 | 
				
			||||||
  styleUrls: ['./onecar-publish.component.less']
 | 
					  styleUrls: ['./onecar-publish.component.less']
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
					export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			||||||
 | 
					  // 环境信息 appId、tenantId
 | 
				
			||||||
 | 
					  envInfo = this.eaCacheSrv.get(cacheConf.env);
 | 
				
			||||||
  validateForm1: FormGroup;
 | 
					  validateForm1: FormGroup;
 | 
				
			||||||
 | 
					  limitValues = {
 | 
				
			||||||
 | 
					    maxWeight: 99999,
 | 
				
			||||||
 | 
					    maxVolume: 99999,
 | 
				
			||||||
 | 
					    maxPiece: 99999
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
  sf1data: any; // 货源单设置回显
 | 
					  sf1data: any; // 货源单设置回显
 | 
				
			||||||
  sf3data: any; // 货源单设置回显
 | 
					  sf3data: any; // 货源单设置回显
 | 
				
			||||||
  sf4data: any; // 货源单设置回显
 | 
					  sf4data: any; // 货源单设置回显
 | 
				
			||||||
@ -61,18 +70,14 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
    private modalService: NzModalService,
 | 
					    private modalService: NzModalService,
 | 
				
			||||||
    public service: SupplyManagementService,
 | 
					    public service: SupplyManagementService,
 | 
				
			||||||
    private amapService: AmapService,
 | 
					    private amapService: AmapService,
 | 
				
			||||||
    public shipperSrv: ShipperBaseService
 | 
					    public shipperSrv: ShipperBaseService,
 | 
				
			||||||
 | 
					    private eaCacheSrv: EACacheService
 | 
				
			||||||
  ) {
 | 
					  ) {
 | 
				
			||||||
    this.validateForm1 = fb.group({
 | 
					    this.validateForm1 = fb.group({
 | 
				
			||||||
      loadAddress0: [null, [Validators.required]],
 | 
					      loadingTime: [null, [Validators.required]],
 | 
				
			||||||
      loadName0: [null, [Validators.required]],
 | 
					      unloadingTime: [null, [Validators.required]]
 | 
				
			||||||
      loadPhone0: [null, [Validators.required, Validators.pattern('^[0-9]*$')]],
 | 
					 | 
				
			||||||
      unloadAddress0: [null, [Validators.required]],
 | 
					 | 
				
			||||||
      unloadName0: [null, [Validators.required]],
 | 
					 | 
				
			||||||
      unloadPhone0: [null, [Validators.required, Validators.pattern('^[0-9]*$')]],
 | 
					 | 
				
			||||||
      loadingTime: [null, []],
 | 
					 | 
				
			||||||
      unloadingTime: [null, []]
 | 
					 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
 | 
					    this.envCache = this.eaCacheSrv.get(cacheConf.env);
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  @ViewChild('sf1', { static: false }) sf1!: SFComponent;
 | 
					  @ViewChild('sf1', { static: false }) sf1!: SFComponent;
 | 
				
			||||||
  schema1: SFSchema = {};
 | 
					  schema1: SFSchema = {};
 | 
				
			||||||
@ -107,11 +112,10 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
  ui7!: SFUISchema;
 | 
					  ui7!: SFUISchema;
 | 
				
			||||||
  formatterRmb = (value: number): string => {
 | 
					  formatterRmb = (value: number): string => {
 | 
				
			||||||
    if (value) {
 | 
					    if (value) {
 | 
				
			||||||
      let  value2 = Number(value).toLocaleString(undefined,{'minimumFractionDigits':2,'maximumFractionDigits':2});
 | 
					      let value2 = Number(value).toLocaleString(undefined, { minimumFractionDigits: 2, maximumFractionDigits: 2 });
 | 
				
			||||||
      return `¥ ${value2}`;
 | 
					      return `¥ ${value2}`;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    return `¥ 0.00`
 | 
					    return `¥ 0.00`;
 | 
				
			||||||
     
 | 
					 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
  parserRmb = (value: string): string => value.replace('¥ ', '').replace(',', '');
 | 
					  parserRmb = (value: string): string => value.replace('¥ ', '').replace(',', '');
 | 
				
			||||||
  // 页面初始化
 | 
					  // 页面初始化
 | 
				
			||||||
@ -127,8 +131,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
    this.initSF5();
 | 
					    this.initSF5();
 | 
				
			||||||
    this.initSF6();
 | 
					    this.initSF6();
 | 
				
			||||||
    this.initSF7();
 | 
					    this.initSF7();
 | 
				
			||||||
 | 
					    this.getLimitvalue();
 | 
				
			||||||
    this.initdata();
 | 
					    this.initdata();
 | 
				
			||||||
    this.getInsurers()
 | 
					 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  initSF1() {
 | 
					  initSF1() {
 | 
				
			||||||
    this.schema1 = {
 | 
					    this.schema1 = {
 | 
				
			||||||
@ -341,8 +345,8 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
            errors: { required: '请选择车型' },
 | 
					            errors: { required: '请选择车型' },
 | 
				
			||||||
            asyncData: () => this.service.getDictOptions({ dictKey: 'car:model' }),
 | 
					            asyncData: () => this.service.getDictOptions({ dictKey: 'car:model' }),
 | 
				
			||||||
            change: (tag: any, org: any) => {
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
              if(tag.includes("999")){
 | 
					              if (tag.includes('999')) {
 | 
				
			||||||
                this.sf4.setValue('/carModel',["999"]);
 | 
					                this.sf4.setValue('/carModel', ['999']);
 | 
				
			||||||
              }
 | 
					              }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
@ -358,12 +362,12 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
            errors: { required: '请选择车长' },
 | 
					            errors: { required: '请选择车长' },
 | 
				
			||||||
            asyncData: () => this.service.getDictOptions({ dictKey: 'car:length' }),
 | 
					            asyncData: () => this.service.getDictOptions({ dictKey: 'car:length' }),
 | 
				
			||||||
            change: (tag: any, org: any) => {
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
              if(tag.includes("999")){
 | 
					              if (tag.includes('999')) {
 | 
				
			||||||
                this.sf4.setValue('/carModel',["999"]);
 | 
					                this.sf4.setValue('/carModel', ['999']);
 | 
				
			||||||
 | 
					              }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      required: ['weight', 'carModel', 'carLength']
 | 
					      required: ['weight', 'carModel', 'carLength']
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
@ -397,8 +401,17 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '增值服务套餐',
 | 
					          title: '增值服务套餐',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'dict-select',
 | 
					            widget: 'select',
 | 
				
			||||||
            params: { dictKey: 'bill:insurance:type' },
 | 
					            asyncData: () => {
 | 
				
			||||||
 | 
					              return this.service.request(this.service.$api_getDictValue, { dictKey: 'bill:insurance:type' }).pipe(
 | 
				
			||||||
 | 
					                map((res: any) => {
 | 
				
			||||||
 | 
					                  return [...res];
 | 
				
			||||||
 | 
					                })
 | 
				
			||||||
 | 
					              );
 | 
				
			||||||
 | 
					            },
 | 
				
			||||||
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
 | 
					              this.getInsurersPrice(tag);
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
          default: '3'
 | 
					          default: '3'
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -409,7 +422,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          readOnly: true,
 | 
					          readOnly: true,
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'checkbox',
 | 
					            widget: 'checkbox',
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value === '0' }
 | 
					            visibleIf: { insuranceType: (value: string) => value === '1' }
 | 
				
			||||||
          } as SFCheckboxWidgetSchema,
 | 
					          } as SFCheckboxWidgetSchema,
 | 
				
			||||||
          default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险']
 | 
					          default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险']
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -420,7 +433,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          readOnly: true,
 | 
					          readOnly: true,
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'checkbox',
 | 
					            widget: 'checkbox',
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value === '1' }
 | 
					            visibleIf: { insuranceType: (value: string) => value === '2' }
 | 
				
			||||||
          } as SFCheckboxWidgetSchema,
 | 
					          } as SFCheckboxWidgetSchema,
 | 
				
			||||||
          default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险']
 | 
					          default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险']
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -438,6 +451,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'dict-select',
 | 
					            widget: 'dict-select',
 | 
				
			||||||
            params: { dictKey: 'insure:packaged:goods' },
 | 
					            params: { dictKey: 'insure:packaged:goods' },
 | 
				
			||||||
 | 
					            containsAllLabel: false,
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
					            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
				
			||||||
          } as SFSelectWidgetSchema
 | 
					          } as SFSelectWidgetSchema
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -463,6 +477,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          title: '',
 | 
					          title: '',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
 | 
					            validator: val => this.customValidator(val),
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
					            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -472,9 +487,9 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            hidden: true
 | 
					            hidden: true
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      },
 | 
					      required: ['insurancePackagedGoods', 'insurancePremium']
 | 
				
			||||||
      required: ['insurancePackagedGoods']
 | 
					 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui5 = {
 | 
					    this.ui5 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
@ -489,9 +504,26 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      },
 | 
					      },
 | 
				
			||||||
      $freeInsurance: {
 | 
					      $freeInsurance: {
 | 
				
			||||||
        grid: { span: 24 }
 | 
					        grid: { span: 24 }
 | 
				
			||||||
      },
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  /**
 | 
				
			||||||
 | 
					   * 自定义校验数据
 | 
				
			||||||
 | 
					   * @param val
 | 
				
			||||||
 | 
					   */
 | 
				
			||||||
 | 
					  customValidator(val: number) {
 | 
				
			||||||
 | 
					    if (this.isEmpty(val)) {
 | 
				
			||||||
 | 
					      return [{ keyword: 'required', message: '不能为空' }];
 | 
				
			||||||
 | 
					    } else {
 | 
				
			||||||
 | 
					      if (val <= 0) {
 | 
				
			||||||
 | 
					        return [{ keyword: 'required', message: '数值需大于0' }];
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      return [];
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					  isEmpty(val: any) {
 | 
				
			||||||
 | 
					    return val === undefined || val === null || val.toString().trim() === '';
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
  initSF6() {
 | 
					  initSF6() {
 | 
				
			||||||
    this.schema6 = {
 | 
					    this.schema6 = {
 | 
				
			||||||
      properties: {
 | 
					      properties: {
 | 
				
			||||||
@ -522,45 +554,65 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
 | 
					        receiptAddress: {
 | 
				
			||||||
 | 
					          type: 'string',
 | 
				
			||||||
 | 
					          title: '回单收件人信息',
 | 
				
			||||||
 | 
					          ui: {
 | 
				
			||||||
 | 
					            widget: 'custom',
 | 
				
			||||||
 | 
					            placeholder: '请点击选择回单收件人信息',
 | 
				
			||||||
 | 
					            // validator: val => (this.sf6?.value?.receiptType === '2' ? [{ keyword: 'required', message: '请点击选择收回单地址' }] : []),
 | 
				
			||||||
 | 
					            visibleIf: {
 | 
				
			||||||
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					          },
 | 
				
			||||||
 | 
					          default: ''
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        receiptAddressId: {
 | 
				
			||||||
 | 
					          type: 'string',
 | 
				
			||||||
 | 
					          title: '',
 | 
				
			||||||
 | 
					          ui: {
 | 
				
			||||||
 | 
					            hidden: true
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
        receiptUserName: {
 | 
					        receiptUserName: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '联系人',
 | 
					          title: '联系人',
 | 
				
			||||||
          maxLength: 15,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
        receiptUserPhone: {
 | 
					          readOnly: true
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        phon: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '联系电话',
 | 
					          title: '联系电话',
 | 
				
			||||||
          maxLength: 11,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
        receiptAddressArea: {
 | 
					          readOnly: true
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        area: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '所在地区',
 | 
					          title: '所在地区',
 | 
				
			||||||
          maxLength: 30,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
        receiptAddress: {
 | 
					          readOnly: true
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
 | 
					        address: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '详细地址',
 | 
					          title: '详细地址',
 | 
				
			||||||
          maxLength: 30,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          },
 | 
				
			||||||
 | 
					          readOnly: true
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        remarks: {
 | 
					        remarks: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
@ -573,11 +625,11 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          } as SFTextareaWidgetSchema
 | 
					          } as SFTextareaWidgetSchema
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      required: ['stateReceipt', 'receiptType', 'receiptUserName', 'receiptUserPhone', 'receiptAddressArea', 'receiptAddress']
 | 
					      required: ['stateReceipt', 'receiptType', 'receiptAddress']
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui6 = {
 | 
					    this.ui6 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
        spanLabelFixed: 90,
 | 
					        spanLabelFixed: 115,
 | 
				
			||||||
        grid: { span: 24 }
 | 
					        grid: { span: 24 }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
@ -646,41 +698,34 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
        }
 | 
					        }
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  changeValue() {
 | 
					 | 
				
			||||||
    this.totalFees =
 | 
					 | 
				
			||||||
      Number(this.sf7?.value?.appendFee) +
 | 
					 | 
				
			||||||
      Number(this.sf7?.value?.prePay) +
 | 
					 | 
				
			||||||
      Number(this.sf7?.value?.receiptPay) +
 | 
					 | 
				
			||||||
      Number(this.sf7?.value?.toPay);
 | 
					 | 
				
			||||||
    console.log(this.totalFees);
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  payChange() {
 | 
					  payChange() {
 | 
				
			||||||
    const prePay = this.sf7.value.prePay || 0;
 | 
					    const prePay = this.sf7.value.prePay || 0;
 | 
				
			||||||
    const toPay = this.sf7.value.toPay || 0
 | 
					    const toPay = this.sf7.value.toPay || 0;
 | 
				
			||||||
    const receiptPay = this.sf7.value.receiptPay || 0;
 | 
					    const receiptPay = this.sf7.value.receiptPay || 0;
 | 
				
			||||||
    // const oilCardPay = 0;
 | 
					    const oilCardPay = 0;
 | 
				
			||||||
    const subtotal = prePay + toPay + receiptPay;
 | 
					    const subtotal = prePay + toPay + receiptPay;
 | 
				
			||||||
    const params = {
 | 
					    const params = {
 | 
				
			||||||
      shipperId: this.envCache?.enterpriseId,
 | 
					      shipperId: this.envCache?.enterpriseId,
 | 
				
			||||||
      enterpriseInfoId: this.envCache?.networkTransporterId,
 | 
					      enterpriseInfoId: this.envCache?.networkTransporterId,
 | 
				
			||||||
      totalFreight: subtotal,
 | 
					      totalFreight: subtotal,
 | 
				
			||||||
      // fuelCardAmount:oilCardPay,
 | 
					      fuelCardAmount: oilCardPay,
 | 
				
			||||||
      resourcetype: '1'
 | 
					      resourcetype: '1'
 | 
				
			||||||
    }
 | 
					    };
 | 
				
			||||||
    this.service
 | 
					    this.service.request(this.service.$api_getCalculatedSurcharge, params).subscribe(res => {
 | 
				
			||||||
      .request(this.service.$api_getCalculatedSurcharge,params)
 | 
					      console.log('999');
 | 
				
			||||||
      .subscribe(res => {
 | 
					      console.log(this.envCache);
 | 
				
			||||||
      if (res) {
 | 
					      if (res) {
 | 
				
			||||||
        this.sf7.setValue('/appendFee', res.surcharge);
 | 
					        this.sf7.setValue('/appendFee', res.surcharge);
 | 
				
			||||||
        this.sf7.setValue('/subtotal', subtotal);
 | 
					        this.sf7.setValue('/subtotal', subtotal);
 | 
				
			||||||
        this.sf7.setValue('/total', subtotal + res.surcharge);
 | 
					        this.sf7.setValue('/total', subtotal + res.surcharge);
 | 
				
			||||||
        this.service
 | 
					        this.service
 | 
				
			||||||
            .request(this.service.$api_getcalculatedServiceRate + `?invoiceAmount=${subtotal + res.surcharge}&totalFreight=${subtotal}`)
 | 
					          .request(
 | 
				
			||||||
 | 
					            this.service.$api_getAdditionalRate +
 | 
				
			||||||
 | 
					              `?shipperId=${this.envCache?.enterpriseId}&enterpriseInfoId=${this?.enterpriseProjectIds}&resourcetype='1'`
 | 
				
			||||||
 | 
					          )
 | 
				
			||||||
          .subscribe(res => {
 | 
					          .subscribe(res => {
 | 
				
			||||||
            if (res) {
 | 
					            if (res) {
 | 
				
			||||||
              this.currentRate = res.rate * 100;
 | 
					              this.currentRate = res.rate * 100;
 | 
				
			||||||
              } else {
 | 
					 | 
				
			||||||
                this.service.msgSrv.error(res.msg);
 | 
					 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          });
 | 
					          });
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
@ -688,8 +733,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  // 添加 删除发货卸货地址
 | 
					  addStartInfo() {
 | 
				
			||||||
  addStartInfo(_event: any) {
 | 
					 | 
				
			||||||
    if (this.startInfo.length < 5) {
 | 
					    if (this.startInfo.length < 5) {
 | 
				
			||||||
      const controlId = this.startInfo.length;
 | 
					      const controlId = this.startInfo.length;
 | 
				
			||||||
      this.startInfo.push({
 | 
					      this.startInfo.push({
 | 
				
			||||||
@ -701,29 +745,37 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
        province: '',
 | 
					        province: '',
 | 
				
			||||||
        city: '',
 | 
					        city: '',
 | 
				
			||||||
        area: '',
 | 
					        area: '',
 | 
				
			||||||
        type: 1
 | 
					        type: '1'
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
      this.validateForm1.addControl(`loadAddress${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(`loadAddress${controlId}`, new FormControl(null, Validators.required));
 | 
				
			||||||
      this.validateForm1.addControl(`loadName${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(`loadName${controlId}`, new FormControl(null, Validators.required));
 | 
				
			||||||
      this.validateForm1.addControl(`loadPhone${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(`loadPhone${controlId}`, new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')]));
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  // 添加 删除发货卸货地址
 | 
					
 | 
				
			||||||
  subStartInfo(event: any, index: number, id?: any) {
 | 
					  getLimitvalue() {
 | 
				
			||||||
    console.log(event, index, id);
 | 
					    // 货物核载信息最大值
 | 
				
			||||||
    if (id) {
 | 
					    // 货物运输费(小计)最大值
 | 
				
			||||||
      this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe(res => {
 | 
					    const getlimitvaluesParms = [this.service.limitKeys.weight, this.service.limitKeys.volume, this.service.limitKeys.piece];
 | 
				
			||||||
        console.log(res);
 | 
					    this.service.request(this.service.$api_findItemValueByItemKeys, getlimitvaluesParms).subscribe(res => {
 | 
				
			||||||
 | 
					      const maxWeight = res.filter((item: any) => item.itemKey === this.service.limitKeys.weight)[0].itemValue;
 | 
				
			||||||
 | 
					      const maxVolume = res.filter((item: any) => item.itemKey === this.service.limitKeys.volume)[0].itemValue;
 | 
				
			||||||
 | 
					      const maxPiece = res.filter((item: any) => item.itemKey === this.service.limitKeys.piece)[0].itemValue;
 | 
				
			||||||
 | 
					      this.limitValues = {
 | 
				
			||||||
 | 
					        maxWeight: Number(maxWeight),
 | 
				
			||||||
 | 
					        maxVolume: Number(maxVolume),
 | 
				
			||||||
 | 
					        maxPiece: Number(maxPiece)
 | 
				
			||||||
 | 
					      };
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  subStartInfo(event: any, index: number) {
 | 
				
			||||||
    this.startInfo.splice(index, 1);
 | 
					    this.startInfo.splice(index, 1);
 | 
				
			||||||
    this.validateForm1.removeControl(`loadAddress${index}`);
 | 
					    this.validateForm1.removeControl(`loadAddress${index}`);
 | 
				
			||||||
    this.validateForm1.removeControl(`loadName${index}`);
 | 
					    this.validateForm1.removeControl(`loadName${index}`);
 | 
				
			||||||
    this.validateForm1.removeControl(`loadPhone${index}`);
 | 
					    this.validateForm1.removeControl(`loadPhone${index}`);
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  // 添加 删除发货卸货地址
 | 
					  addEndInfo() {
 | 
				
			||||||
  addEndInfo(_event: any) {
 | 
					    if (this.endInfo.length < 5) {
 | 
				
			||||||
    if (this.addEndInfo.length < 5) {
 | 
					 | 
				
			||||||
      const controlId = this.endInfo.length;
 | 
					      const controlId = this.endInfo.length;
 | 
				
			||||||
      this.endInfo.push({
 | 
					      this.endInfo.push({
 | 
				
			||||||
        detailedAddress: '',
 | 
					        detailedAddress: '',
 | 
				
			||||||
@ -734,21 +786,17 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
        province: '',
 | 
					        province: '',
 | 
				
			||||||
        city: '',
 | 
					        city: '',
 | 
				
			||||||
        area: '',
 | 
					        area: '',
 | 
				
			||||||
        type: 2
 | 
					        type: '2'
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
      this.validateForm1.addControl(`unloadAddress${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(`unloadAddress${controlId}`, new FormControl(null, Validators.required));
 | 
				
			||||||
      this.validateForm1.addControl(`unloadName${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(`unloadName${controlId}`, new FormControl(null, Validators.required));
 | 
				
			||||||
      this.validateForm1.addControl(`unloadPhone${controlId}`, new FormControl(null, Validators.required));
 | 
					      this.validateForm1.addControl(
 | 
				
			||||||
 | 
					        `unloadPhone${controlId}`,
 | 
				
			||||||
 | 
					        new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')])
 | 
				
			||||||
 | 
					      );
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  // 添加 删除发货卸货地址
 | 
					  subEndInfo(event: any, index: number) {
 | 
				
			||||||
  subEndInfo(event: any, index: number, id?: any) {
 | 
					 | 
				
			||||||
    if (id) {
 | 
					 | 
				
			||||||
      this.service.request(this.service.$api_delete_Wholedeletebatch, [id]).subscribe(res => {
 | 
					 | 
				
			||||||
        console.log(res);
 | 
					 | 
				
			||||||
      });
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
    console.log(event, index, id);
 | 
					 | 
				
			||||||
    this.endInfo.splice(index, 1);
 | 
					    this.endInfo.splice(index, 1);
 | 
				
			||||||
    this.validateForm1.removeControl(`unloadAddress${index}`);
 | 
					    this.validateForm1.removeControl(`unloadAddress${index}`);
 | 
				
			||||||
    this.validateForm1.removeControl(`unloadName${index}`);
 | 
					    this.validateForm1.removeControl(`unloadName${index}`);
 | 
				
			||||||
@ -773,10 +821,12 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      .subscribe(res => {
 | 
					      .subscribe(res => {
 | 
				
			||||||
        if (res) {
 | 
					        if (res) {
 | 
				
			||||||
          this.sf3.getProperty('/goodsNameId')!.schema.enum = res;
 | 
					          this.sf3.getProperty('/goodsNameId')!.schema.enum = res;
 | 
				
			||||||
          this.sf3.getProperty('/goodsNameId')!.widget?.reset(res);
 | 
					          this.sf3.getProperty('/goodsNameId')!.widget.reset(res);
 | 
				
			||||||
          if (this.sf3data.goodsNameId) {
 | 
					          if (this.sf3data.goodsNameId) {
 | 
				
			||||||
            this.sf3.setValue('/goodsNameId', this.sf3data.goodsNameId);
 | 
					            this.sf3.setValue('/goodsNameId', this.sf3data.goodsNameId);
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					        } else {
 | 
				
			||||||
 | 
					          this.service.msgSrv.error(res.msg);
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
@ -812,26 +862,76 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
    });
 | 
					    });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  // 提交前确认,委托运输协议弹窗
 | 
					  // 提交前确认,委托运输协议弹窗
 | 
				
			||||||
  submitConfirm(submitType?: any) {
 | 
					  submitConfirm(submitType?: string) {
 | 
				
			||||||
    Object.keys(this.validateForm1.controls).forEach(key => {
 | 
					    Object.keys(this.validateForm1.controls).forEach(key => {
 | 
				
			||||||
      this.validateForm1.controls[key].markAsDirty();
 | 
					      this.validateForm1.controls[key].markAsDirty();
 | 
				
			||||||
      this.validateForm1.controls[key].updateValueAndValidity();
 | 
					      this.validateForm1.controls[key].updateValueAndValidity();
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
    this.sf1.validator({ emitError: true });
 | 
					 | 
				
			||||||
    this.sf3.validator({ emitError: true });
 | 
					    this.sf3.validator({ emitError: true });
 | 
				
			||||||
    this.sf4.validator({ emitError: true });
 | 
					    this.sf4.validator({ emitError: true });
 | 
				
			||||||
 | 
					    this.sf5.validator({ emitError: true });
 | 
				
			||||||
    this.sf6.validator({ emitError: true });
 | 
					    this.sf6.validator({ emitError: true });
 | 
				
			||||||
    this.sf7.validator({ emitError: true });
 | 
					    this.sf7.validator({ emitError: true });
 | 
				
			||||||
    console.log(this.sf1.valid);
 | 
					    console.log(this.validateForm1.invalid)
 | 
				
			||||||
    if (this.validateForm1.invalid || !this.sf3.valid || !this.sf1.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
 | 
					    console.log(this.sf4.valid)
 | 
				
			||||||
 | 
					    console.log(this.sf5.valid)
 | 
				
			||||||
 | 
					    console.log(this.sf6.valid)
 | 
				
			||||||
 | 
					    console.log(this.sf7.valid)
 | 
				
			||||||
 | 
					    if (this.validateForm1.invalid || !this.sf3.valid || !this.sf4.valid || !this.sf5.valid || !this.sf6.valid || !this.sf7.valid) {
 | 
				
			||||||
 | 
					      this.service.msgSrv.warning('请完善必填项!');
 | 
				
			||||||
 | 
					      return;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (this.validateForm1.value.loadingTime < new Date()) {
 | 
				
			||||||
 | 
					      this.service.msgSrv.warning('装货时间必须大于当前时间!');
 | 
				
			||||||
 | 
					      return;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (this.validateForm1.value.loadingTime > this.validateForm1.value.unloadingTime) {
 | 
				
			||||||
 | 
					      this.service.msgSrv.warning('装货时间不能大于卸货时间!');
 | 
				
			||||||
 | 
					      return;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    if (this.sf7.value.total <= 0) {
 | 
				
			||||||
 | 
					      this.service.msgSrv.warning('总费用不能为0!');
 | 
				
			||||||
      return;
 | 
					      return;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if (
 | 
				
			||||||
 | 
					      this.sf4.value.weight > this.limitValues.maxWeight ||
 | 
				
			||||||
 | 
					      this.sf4.value.volume > this.limitValues.maxVolume ||
 | 
				
			||||||
 | 
					      this.sf4.value.number > this.limitValues.maxPiece
 | 
				
			||||||
 | 
					    ) {
 | 
				
			||||||
 | 
					      this.service.msgSrv.error(
 | 
				
			||||||
 | 
					        `当前货物核载信息已超出限定值【${this.limitValues.maxWeight}吨、${this.limitValues.maxVolume}方、${this.limitValues.maxPiece}件】`
 | 
				
			||||||
 | 
					      );
 | 
				
			||||||
 | 
					      return;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    const getFreightParms = { carLengthKeys: this.sf4.value.carLength, km: this.totalDistance };
 | 
				
			||||||
 | 
					    this.service.request(this.service.$api_getFreight, getFreightParms).subscribe(res => {
 | 
				
			||||||
 | 
					      if (this.sf7.value.subtotal > res.maxPrice) {
 | 
				
			||||||
 | 
					        this.service.msgSrv.error(`运费过高,请调整录入`);
 | 
				
			||||||
 | 
					        return;
 | 
				
			||||||
 | 
					      } else if (this.sf7.value.subtotal > res.ewPrice) {
 | 
				
			||||||
 | 
					        this.modalService.confirm({
 | 
				
			||||||
 | 
					          nzTitle: '',
 | 
				
			||||||
 | 
					          nzContent: `您的录入的运费过高,可能会影响支付,请仔细确认`,
 | 
				
			||||||
 | 
					          nzOkText: '继续',
 | 
				
			||||||
 | 
					          nzCancelText: '取消',
 | 
				
			||||||
 | 
					          nzOnOk: () => {
 | 
				
			||||||
 | 
					            this.agreementConfirm(submitType);
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					        });
 | 
				
			||||||
 | 
					      } else {
 | 
				
			||||||
 | 
					        this.agreementConfirm(submitType);
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    });
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					  // 提交前协议弹窗
 | 
				
			||||||
 | 
					  agreementConfirm(submitType?: string) {
 | 
				
			||||||
    const modalRef = this.modalService.create({
 | 
					    const modalRef = this.modalService.create({
 | 
				
			||||||
      nzTitle: '运输协议',
 | 
					      nzTitle: '运输协议',
 | 
				
			||||||
      nzContent: TranAgreementComponent,
 | 
					      nzContent: TranAgreementComponent,
 | 
				
			||||||
      nzWidth: 900,
 | 
					      nzWidth: 900,
 | 
				
			||||||
      nzFooter: null,
 | 
					      nzFooter: null
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
    modalRef.afterClose.subscribe(result => {
 | 
					    modalRef.afterClose.subscribe(result => {
 | 
				
			||||||
      if (result) {
 | 
					      if (result) {
 | 
				
			||||||
@ -841,73 +941,77 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
  }
 | 
					  }
 | 
				
			||||||
  // 提交
 | 
					  // 提交
 | 
				
			||||||
  submit(submitType?: string): void {
 | 
					  submit(submitType?: string): void {
 | 
				
			||||||
    Object.keys(this.validateForm1.controls).forEach(key => {
 | 
					    //装卸货信息
 | 
				
			||||||
      this.validateForm1.controls[key].markAsDirty();
 | 
					    const LoadingList = this.startInfo.concat(this.endInfo);
 | 
				
			||||||
      this.validateForm1.controls[key].updateValueAndValidity();
 | 
					
 | 
				
			||||||
    });
 | 
					    // 货物信息
 | 
				
			||||||
    this.sf1.validator({ emitError: true });
 | 
					    const sf3Values = { ...this.sf3.value };
 | 
				
			||||||
    this.sf3.validator({ emitError: true });
 | 
					    if (sf3Values.goodsTypeName === '其它') {
 | 
				
			||||||
    this.sf4.validator({ emitError: true });
 | 
					      sf3Values.goodsName = sf3Values.goodsName1;
 | 
				
			||||||
    this.sf6.validator({ emitError: true });
 | 
					      delete sf3Values.goodsName1;
 | 
				
			||||||
    this.sf7.validator({ emitError: true });
 | 
					 | 
				
			||||||
    console.log(this.sf1.valid);
 | 
					 | 
				
			||||||
    if (this.validateForm1.invalid || !this.sf3.valid || !this.sf1.valid || !this.sf4.valid || !this.sf6.valid || !this.sf7.valid) {
 | 
					 | 
				
			||||||
      return;
 | 
					 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    console.log(this?.loadingTime);
 | 
					    if (this.sf4.value.carModel.includes('999')) {
 | 
				
			||||||
    console.log(this?.unloadingTime);
 | 
					      this.sf4.value.carModel = ['999'];
 | 
				
			||||||
    if (typeof this.unloadingTime !== 'string') {
 | 
					 | 
				
			||||||
      var c = new Date(this.unloadingTime);
 | 
					 | 
				
			||||||
      this.unloadingTime =
 | 
					 | 
				
			||||||
        c.getFullYear() +
 | 
					 | 
				
			||||||
        '-' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getMonth() + 1) +
 | 
					 | 
				
			||||||
        '-' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getDate()) +
 | 
					 | 
				
			||||||
        ' ' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getHours()) +
 | 
					 | 
				
			||||||
        ':' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getMinutes()) +
 | 
					 | 
				
			||||||
        ':' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getSeconds());
 | 
					 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    if (typeof this.loadingTime !== 'string') {
 | 
					    if (this.sf4.value.carLength.includes('999')) {
 | 
				
			||||||
      var c = new Date(this.loadingTime);
 | 
					      this.sf4.value.carLength = ['999'];
 | 
				
			||||||
      this.loadingTime =
 | 
					 | 
				
			||||||
        c.getFullYear() +
 | 
					 | 
				
			||||||
        '-' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getMonth() + 1) +
 | 
					 | 
				
			||||||
        '-' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getDate()) +
 | 
					 | 
				
			||||||
        ' ' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getHours()) +
 | 
					 | 
				
			||||||
        ':' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getMinutes()) +
 | 
					 | 
				
			||||||
        ':' +
 | 
					 | 
				
			||||||
        this.addPreZero(c.getSeconds());
 | 
					 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    console.log(this.loadingTime)
 | 
					    const goodsInfoVOList = [
 | 
				
			||||||
    const params: any = {
 | 
					 | 
				
			||||||
      ...this.sf1.value,
 | 
					 | 
				
			||||||
      ...this.sf5.value,
 | 
					 | 
				
			||||||
      ...this.sf6.value,
 | 
					 | 
				
			||||||
      paymentDays: this.sf7.value.paymentDays,
 | 
					 | 
				
			||||||
      loadingTime: this.loadingTime,
 | 
					 | 
				
			||||||
      unloadingTime: this.unloadingTime,
 | 
					 | 
				
			||||||
      unLoadingPlaceDTOList: [...this.startInfo, ...this.endInfo],
 | 
					 | 
				
			||||||
      goodsInfoDTOList: [
 | 
					 | 
				
			||||||
      {
 | 
					      {
 | 
				
			||||||
 | 
					        ...sf3Values,
 | 
				
			||||||
        ...this.sf4.value,
 | 
					        ...this.sf4.value,
 | 
				
			||||||
          ...this.sf3.value,
 | 
					 | 
				
			||||||
        carModel: this.sf4.value.carModel.join(','),
 | 
					        carModel: this.sf4.value.carModel.join(','),
 | 
				
			||||||
        carLength: this.sf4.value.carLength.join(',')
 | 
					        carLength: this.sf4.value.carLength.join(',')
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
      ]
 | 
					    ];
 | 
				
			||||||
    };
 | 
					    // 运费信息
 | 
				
			||||||
    params.shippingInformationDTO = {
 | 
					    const expenseList = [
 | 
				
			||||||
      ...this.sf7.value,
 | 
					      { expenseCode: 'PRE', expenseName: '预付', price: this.sf7.value.prePay || 0, id: this.sf7data?.prePayId || '' },
 | 
				
			||||||
      totalFees: this.totalFees
 | 
					      { expenseCode: 'RECE', expenseName: '到付', price: this.sf7.value.toPay || 0, id: this.sf7data?.toPayId || '' },
 | 
				
			||||||
 | 
					      { expenseCode: 'BACK', expenseName: '回单付', price: this.sf7.value.receiptPay || 0, id: this.sf7data?.receiptPayId || '' }
 | 
				
			||||||
 | 
					    ];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    // 从“再下一单”过来,将所有的子参数内的id都删除
 | 
				
			||||||
 | 
					    if ((this.PageStatus = '整车下一单')) {
 | 
				
			||||||
 | 
					      LoadingList.forEach((ele: any) => {
 | 
				
			||||||
 | 
					        delete ele.id;
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					      goodsInfoVOList.forEach((ele: any) => {
 | 
				
			||||||
 | 
					        delete ele.id;
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					      expenseList.forEach((ele: any) => {
 | 
				
			||||||
 | 
					        delete ele.id;
 | 
				
			||||||
 | 
					      });
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					    const params = {
 | 
				
			||||||
 | 
					      id: '',
 | 
				
			||||||
 | 
					      ...this.sf1.value,
 | 
				
			||||||
 | 
					      unLoadingPlaceDTOList: LoadingList,
 | 
				
			||||||
 | 
					      unloadingTime: format(this.validateForm1.value.unloadingTime, 'yyyy-MM-dd HH:mm:ss'),
 | 
				
			||||||
 | 
					      loadingTime: format(this.validateForm1.value.loadingTime, 'yyyy-MM-dd HH:mm:ss'),
 | 
				
			||||||
 | 
					      goodsInfoDTOList: goodsInfoVOList,
 | 
				
			||||||
 | 
					      ...this.sf5.value,
 | 
				
			||||||
 | 
					      ...this.sf6.value,
 | 
				
			||||||
 | 
					      expenseDTOList: expenseList,
 | 
				
			||||||
 | 
					      paymentDays: this.sf7.value.paymentDays
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
 | 
					    // const params: any = {
 | 
				
			||||||
 | 
					    //   ...this.sf1.value,
 | 
				
			||||||
 | 
					    //   ...this.sf5.value,
 | 
				
			||||||
 | 
					    //   ...this.sf6.value,
 | 
				
			||||||
 | 
					    //   paymentDays: this.sf7.value.paymentDays,
 | 
				
			||||||
 | 
					    //   loadingTime: this.loadingTime,
 | 
				
			||||||
 | 
					    //   unloadingTime: this.unloadingTime,
 | 
				
			||||||
 | 
					    //   unLoadingPlaceDTOList: [...this.startInfo, ...this.endInfo],
 | 
				
			||||||
 | 
					    //   goodsInfoDTOList: [
 | 
				
			||||||
 | 
					    //     {
 | 
				
			||||||
 | 
					    //       ...this.sf4.value,
 | 
				
			||||||
 | 
					    //       ...this.sf3.value,
 | 
				
			||||||
 | 
					    //       carModel: this.sf4.value.carModel.join(','),
 | 
				
			||||||
 | 
					    //       carLength: this.sf4.value.carLength.join(',')
 | 
				
			||||||
 | 
					    //     }
 | 
				
			||||||
 | 
					    //   ]
 | 
				
			||||||
 | 
					    // };
 | 
				
			||||||
    console.log(params);
 | 
					    console.log(params);
 | 
				
			||||||
    if (submitType) {
 | 
					    if (submitType) {
 | 
				
			||||||
      if (submitType == 'assign') {
 | 
					      if (submitType == 'assign') {
 | 
				
			||||||
@ -979,6 +1083,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          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;
 | 
				
			||||||
 | 
					            this.getInsurersPrice(); // 计算保费金额
 | 
				
			||||||
          });
 | 
					          });
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
@ -1108,26 +1213,27 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      this.sf3data.goodsName1 = res?.goodsInfoVOList[0]?.goodsName || '';
 | 
					      this.sf3data.goodsName1 = res?.goodsInfoVOList[0]?.goodsName || '';
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    this.changeGoodsType(this.sf3data.goodsTypeId, { label: this.sf3data.goodsTypeName, value: this.sf3data.goodsTypeId });
 | 
					    this.changeGoodsType(this.sf3data.goodsTypeId, { label: this.sf3data.goodsTypeName, value: this.sf3data.goodsTypeId });
 | 
				
			||||||
    this.sf4data = {
 | 
					  
 | 
				
			||||||
      weight: res?.goodsInfoVOList[0]?.weight,
 | 
					 | 
				
			||||||
      volume: res?.goodsInfoVOList[0]?.volume,
 | 
					 | 
				
			||||||
      vehicleDemand: res?.goodsInfoVOList[0]?.vehicleDemand,
 | 
					 | 
				
			||||||
      carLength: res?.goodsInfoVOList[0]?.carLength?.split(','),
 | 
					 | 
				
			||||||
      carModel: res?.goodsInfoVOList[0]?.carModel?.split(',') || '',
 | 
					 | 
				
			||||||
      number: res?.goodsInfoVOList[0]?.number,
 | 
					 | 
				
			||||||
      goodsTypeName: res?.goodsInfoVOList[0]?.goodsTypeName,
 | 
					 | 
				
			||||||
      modifyUserId: res?.goodsInfoVOList[0]?.modifyUserId,
 | 
					 | 
				
			||||||
      resourceId: res?.goodsInfoVOList[0]?.resourceId,
 | 
					 | 
				
			||||||
      rule: res?.goodsInfoVOList[0]?.rule,
 | 
					 | 
				
			||||||
      settlementBasis: res?.goodsInfoVOList[0]?.settlementBasis
 | 
					 | 
				
			||||||
    };
 | 
					 | 
				
			||||||
    if (res?.loadingTime) {
 | 
					    if (res?.loadingTime) {
 | 
				
			||||||
      this.loadingTime = res?.loadingTime;
 | 
					      this.loadingTime = res?.loadingTime;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    if (res?.unloadingTime) {
 | 
					    if (res?.unloadingTime) {
 | 
				
			||||||
      this.unloadingTime = res?.unloadingTime;
 | 
					      this.unloadingTime = res?.unloadingTime;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					    this.validateForm1.patchValue(
 | 
				
			||||||
 | 
					      {
 | 
				
			||||||
 | 
					        loadingTime: new Date(Date.parse(res.loadingTime.replace(/-/g, '/'))),
 | 
				
			||||||
 | 
					        unloadingTime: new Date(Date.parse(res.unloadingTime.replace(/-/g, '/')))
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      { onlySelf: true }
 | 
				
			||||||
 | 
					    );
 | 
				
			||||||
 | 
					    this.sf4data = {
 | 
				
			||||||
 | 
					      weight: res?.goodsInfoVOList[0]?.weight || '',
 | 
				
			||||||
 | 
					      volume: res?.goodsInfoVOList[0]?.volume || '',
 | 
				
			||||||
 | 
					      number: res?.goodsInfoVOList[0]?.number || '',
 | 
				
			||||||
 | 
					      carModel: res?.goodsInfoVOList[0]?.carModel?.split(',') || [],
 | 
				
			||||||
 | 
					      carLength: res?.goodsInfoVOList[0]?.carLength?.split(',') || []
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
    if (this.PageStatus === '整车修改') {
 | 
					    if (this.PageStatus === '整车修改') {
 | 
				
			||||||
      this.sf4data.id = res?.goodsInfoVOList[0]?.id;
 | 
					      this.sf4data.id = res?.goodsInfoVOList[0]?.id;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
@ -1203,40 +1309,21 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
          default:
 | 
					          default:
 | 
				
			||||||
            break;
 | 
					            break;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					        // 计算里程,时间
 | 
				
			||||||
 | 
					        if (this.startInfo[0]?.area && this.endInfo[0]?.area) {
 | 
				
			||||||
 | 
					          this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe(res => {
 | 
				
			||||||
 | 
					            this.totalDistance = res.distance;
 | 
				
			||||||
 | 
					            this.totalTime = res.time;
 | 
				
			||||||
 | 
					            this.getInsurersPrice(); //计算保费金额
 | 
				
			||||||
 | 
					          });
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  changeUn(event: Date) {
 | 
					    // 不可选择的时间
 | 
				
			||||||
    console.log(event)
 | 
					    disabledDateStart = (current: Date): boolean => {
 | 
				
			||||||
    this.unloadingTime = event;
 | 
					      return differenceInCalendarDays(new Date(), current) > 0;
 | 
				
			||||||
    if(typeof this.loadingTime === 'string') {
 | 
					    };
 | 
				
			||||||
      var a = new Date(this.loadingTime)
 | 
					 | 
				
			||||||
    if ( a > this.unloadingTime?.getTime() ) {
 | 
					 | 
				
			||||||
      this.service.msgSrv.error('卸货时间不能小于装货时间!');
 | 
					 | 
				
			||||||
      this.unloadingTime = '';
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  } else {
 | 
					 | 
				
			||||||
    if ( this.loadingTime?.getTime() > this.unloadingTime?.getTime() ) {
 | 
					 | 
				
			||||||
      this.service.msgSrv.error('卸货时间不能小于装货时间!');
 | 
					 | 
				
			||||||
      this.unloadingTime = '';
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  changeLO(event: Date) {
 | 
					 | 
				
			||||||
    this.loadingTime = event;
 | 
					 | 
				
			||||||
    if(typeof this.unloadingTime === 'string') {
 | 
					 | 
				
			||||||
      var a = new Date(this.unloadingTime)
 | 
					 | 
				
			||||||
      if ( a.getTime()< this.loadingTime?.getTime()) {
 | 
					 | 
				
			||||||
        this.service.msgSrv.error('装货时间不能大于卸货时间!');
 | 
					 | 
				
			||||||
        this.loadingTime = '';
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    } else {
 | 
					 | 
				
			||||||
      if ( this.unloadingTime?.getTime()< this.loadingTime?.getTime()) {
 | 
					 | 
				
			||||||
        this.service.msgSrv.error('装货时间不能大于卸货时间!');
 | 
					 | 
				
			||||||
        this.loadingTime = '';
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  // 装卸货地址互换
 | 
					  // 装卸货地址互换
 | 
				
			||||||
  swapAddress() {
 | 
					  swapAddress() {
 | 
				
			||||||
    this.startInfo.forEach((element: any, index: any) => {
 | 
					    this.startInfo.forEach((element: any, index: any) => {
 | 
				
			||||||
@ -1271,63 +1358,16 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe(res => {
 | 
					      this.amapService.drivingCompute([...this.startInfo], [...this.endInfo]).subscribe(res => {
 | 
				
			||||||
        this.totalDistance = res.distance;
 | 
					        this.totalDistance = res.distance;
 | 
				
			||||||
        this.totalTime = res.time;
 | 
					        this.totalTime = res.time;
 | 
				
			||||||
 | 
					        this.getInsurersPrice(); //计算保费金额
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
  goodsValuesChange(value: any) {
 | 
					  // 计算保价费金额
 | 
				
			||||||
    console.log(value);
 | 
					  getInsurersPrice(insuranceType = this.sf5.value.insuranceType) {
 | 
				
			||||||
    console.log(this.totalDistance);
 | 
					    if (this.sf5.value.goodsValue >= 50000 && this.totalDistance > 0) {
 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    if(value >= 50000 && this.totalDistance > 0){
 | 
					 | 
				
			||||||
      const params = {
 | 
					 | 
				
			||||||
        goodsValue: value,
 | 
					 | 
				
			||||||
        insuranceType: this.sf55.value.insuranceType,
 | 
					 | 
				
			||||||
        km: this.totalDistance
 | 
					 | 
				
			||||||
      };
 | 
					 | 
				
			||||||
      this.service
 | 
					 | 
				
			||||||
        .request(this.service.$api_getWholeInsuranceInfo, params)
 | 
					 | 
				
			||||||
        .subscribe(res => {
 | 
					 | 
				
			||||||
          if (res) {
 | 
					 | 
				
			||||||
            this.sf5.setValue('/insurancePremium',res.insurancePremium);
 | 
					 | 
				
			||||||
          }else{
 | 
					 | 
				
			||||||
            this.sf5.setValue('/insurancePremium',null);
 | 
					 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
      });
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  getInsurersPrice($event?: any) {
 | 
					 | 
				
			||||||
    console.log($event);
 | 
					 | 
				
			||||||
    this.changeSub.next(`${$event}`);
 | 
					 | 
				
			||||||
   
 | 
					 | 
				
			||||||
 
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  getInsurers($event?: any) {
 | 
					 | 
				
			||||||
    this.changeSub.pipe(debounceTime(500)).subscribe((res: any) => {
 | 
					 | 
				
			||||||
      console.log(res)
 | 
					 | 
				
			||||||
      if (res) {
 | 
					 | 
				
			||||||
        console.log(res)
 | 
					 | 
				
			||||||
        if(res > 3000000 ) {
 | 
					 | 
				
			||||||
          console.log('1111')
 | 
					 | 
				
			||||||
          this.sf5.getProperty('/goodsValue')!.widget.reset(3000000);
 | 
					 | 
				
			||||||
          this.sf5.setValue('/goodsValue', 3000000);
 | 
					 | 
				
			||||||
          this.service.msgSrv.error('请输入50000-3000000之间数值!')
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
        if(res < 50000) {
 | 
					 | 
				
			||||||
          // this.sf5.setValue('/goodsValue', 50000);
 | 
					 | 
				
			||||||
          this.sf5.getProperty('/goodsValue')!.widget.reset(50000);
 | 
					 | 
				
			||||||
          this.sf5.setValue('/goodsValue', 50000);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
          console.log('2222')
 | 
					 | 
				
			||||||
          this.service.msgSrv.error('请输入50000-3000000之间数值!')
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
        if (this.sf5.value.goodsValue >= 50000) {
 | 
					 | 
				
			||||||
          if(this.totalDistance <=0){
 | 
					 | 
				
			||||||
            this.service.msgSrv.warning('当前装卸货距离为0,无法计算保价费金额');
 | 
					 | 
				
			||||||
            return;
 | 
					 | 
				
			||||||
          }
 | 
					 | 
				
			||||||
      const params = {
 | 
					      const params = {
 | 
				
			||||||
 | 
					        insuranceType,
 | 
				
			||||||
        goodsValue: this.sf5.value.goodsValue,
 | 
					        goodsValue: this.sf5.value.goodsValue,
 | 
				
			||||||
            insuranceType: this.sf5.value.insuranceType,
 | 
					 | 
				
			||||||
        km: this.totalDistance
 | 
					        km: this.totalDistance
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
      this.service.request(this.service.$api_getWholeInsuranceInfo, params).subscribe(res => {
 | 
					      this.service.request(this.service.$api_getWholeInsuranceInfo, params).subscribe(res => {
 | 
				
			||||||
@ -1341,8 +1381,4 @@ export class SupplyManagementOnecarPublishComponent implements OnInit {
 | 
				
			|||||||
      });
 | 
					      });
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
    
 | 
					 | 
				
			||||||
    });
 | 
					 | 
				
			||||||
  }
 | 
					 | 
				
			||||||
  
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
@ -158,7 +158,12 @@
 | 
				
			|||||||
        <nz-form-item>
 | 
					        <nz-form-item>
 | 
				
			||||||
          <nz-form-label [nzSpan]="3" nzRequired>装货时间</nz-form-label>
 | 
					          <nz-form-label [nzSpan]="3" nzRequired>装货时间</nz-form-label>
 | 
				
			||||||
          <nz-form-control [nzErrorTip]="'请输入装货时间'">
 | 
					          <nz-form-control [nzErrorTip]="'请输入装货时间'">
 | 
				
			||||||
            <nz-date-picker nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss" formControlName="loadingTime" name="loadingTime"></nz-date-picker>
 | 
					            <nz-date-picker
 | 
				
			||||||
 | 
					            nzShowTime
 | 
				
			||||||
 | 
					            nzFormat="yyyy-MM-dd HH:mm:ss"
 | 
				
			||||||
 | 
					            formControlName="loadingTime"
 | 
				
			||||||
 | 
					            [nzDisabledDate]="disabledDateStart"
 | 
				
			||||||
 | 
					          ></nz-date-picker>
 | 
				
			||||||
          </nz-form-control>
 | 
					          </nz-form-control>
 | 
				
			||||||
        </nz-form-item>
 | 
					        </nz-form-item>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
@ -167,7 +172,7 @@
 | 
				
			|||||||
        <nz-form-item>
 | 
					        <nz-form-item>
 | 
				
			||||||
          <nz-form-label [nzSpan]="3" nzRequired>卸货时间</nz-form-label>
 | 
					          <nz-form-label [nzSpan]="3" nzRequired>卸货时间</nz-form-label>
 | 
				
			||||||
          <nz-form-control [nzErrorTip]="'请输入卸货时间'">
 | 
					          <nz-form-control [nzErrorTip]="'请输入卸货时间'">
 | 
				
			||||||
            <nz-date-picker nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss" formControlName="unloadingTime" name="unloadingTime"></nz-date-picker>
 | 
					            <nz-date-picker nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss" formControlName="unloadingTime"></nz-date-picker>
 | 
				
			||||||
          </nz-form-control>
 | 
					          </nz-form-control>
 | 
				
			||||||
        </nz-form-item>
 | 
					        </nz-form-item>
 | 
				
			||||||
      </div>
 | 
					      </div>
 | 
				
			||||||
 | 
				
			|||||||
@ -2,6 +2,7 @@ import { Component, OnInit, ViewChild } from '@angular/core';
 | 
				
			|||||||
import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
 | 
					import { FormBuilder, FormControl, FormGroup, Validators } from '@angular/forms';
 | 
				
			||||||
import { ActivatedRoute, Router } from '@angular/router';
 | 
					import { ActivatedRoute, Router } from '@angular/router';
 | 
				
			||||||
import { cacheConf } from '@conf/cache.conf';
 | 
					import { cacheConf } from '@conf/cache.conf';
 | 
				
			||||||
 | 
					import differenceInCalendarDays from 'date-fns/differenceInCalendarDays';
 | 
				
			||||||
import {
 | 
					import {
 | 
				
			||||||
  SFCheckboxWidgetSchema,
 | 
					  SFCheckboxWidgetSchema,
 | 
				
			||||||
  SFComponent,
 | 
					  SFComponent,
 | 
				
			||||||
@ -241,7 +242,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'select',
 | 
					            widget: 'select',
 | 
				
			||||||
            placeholder: '请选择',
 | 
					            placeholder: '请选择',
 | 
				
			||||||
            errors: { required: '请选择货物类型' },
 | 
					            errors: { required: '请选择货物名称' },
 | 
				
			||||||
            asyncData: () =>
 | 
					            asyncData: () =>
 | 
				
			||||||
              this.shipperSrv.loadConfigByKey('goods.name.config.type').pipe(
 | 
					              this.shipperSrv.loadConfigByKey('goods.name.config.type').pipe(
 | 
				
			||||||
                map((data: any) => {
 | 
					                map((data: any) => {
 | 
				
			||||||
@ -270,7 +271,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
            widget: 'select',
 | 
					            widget: 'select',
 | 
				
			||||||
            placeholder: '请选择',
 | 
					            placeholder: '请选择',
 | 
				
			||||||
            errors: { required: '请填写货物名称' },
 | 
					            errors: { required: '请填写货物名称' },
 | 
				
			||||||
            change: (_value: any, data: any) => {
 | 
					            change: (value: any, data: any) => {
 | 
				
			||||||
              this.sf3.setValue('/goodsName', data.label);
 | 
					              this.sf3.setValue('/goodsName', data.label);
 | 
				
			||||||
            },
 | 
					            },
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
@ -299,11 +300,11 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          }
 | 
					          }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      required: ['goodsTypeId', 'goodsName', 'goodsNameId']
 | 
					      required: ['goodsTypeId', 'goodsName', 'goodsNameId', 'goodsName1']
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui3 = {
 | 
					    this.ui3 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
        spanLabelFixed: 90,
 | 
					        spanLabelFixed: 115,
 | 
				
			||||||
        grid: { span: 12 }
 | 
					        grid: { span: 12 }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
@ -317,7 +318,8 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
            placeholder: '请输入',
 | 
					            placeholder: '请输入',
 | 
				
			||||||
            errors: { required: '必填项' }
 | 
					            errors: { required: '必填项' },
 | 
				
			||||||
 | 
					            validator: val => this.customValidator(val)
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        volume: {
 | 
					        volume: {
 | 
				
			||||||
@ -325,7 +327,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          title: '',
 | 
					          title: '',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
            placeholder: '请输入'
 | 
					            placeholder: '请输入',
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        number: {
 | 
					        number: {
 | 
				
			||||||
@ -333,7 +335,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          title: '',
 | 
					          title: '',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
            placeholder: '请输入'
 | 
					            placeholder: '请输入',
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        carModel: {
 | 
					        carModel: {
 | 
				
			||||||
@ -347,8 +349,8 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
            errors: { required: '请选择车型' },
 | 
					            errors: { required: '请选择车型' },
 | 
				
			||||||
            asyncData: () => this.service.getDictOptions({ dictKey: 'car:model' }),
 | 
					            asyncData: () => this.service.getDictOptions({ dictKey: 'car:model' }),
 | 
				
			||||||
            change: (tag: any, org: any) => {
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
              if(tag.includes("999")){
 | 
					              if (tag.includes('999')) {
 | 
				
			||||||
                this.sf4.setValue('/carModel',["999"]);
 | 
					                this.sf4.setValue('/carModel', ['999']);
 | 
				
			||||||
              }
 | 
					              }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
@ -364,38 +366,27 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
            errors: { required: '请选择车长' },
 | 
					            errors: { required: '请选择车长' },
 | 
				
			||||||
            asyncData: () => this.service.getDictOptions({ dictKey: 'car:length' }),
 | 
					            asyncData: () => this.service.getDictOptions({ dictKey: 'car:length' }),
 | 
				
			||||||
            change: (tag: any, org: any) => {
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
              if(tag.includes("999")){
 | 
					              if (tag.includes('999')) {
 | 
				
			||||||
                this.sf4.setValue('/carModel',["999"]);
 | 
					                this.sf4.setValue('/carLength', ['999']);
 | 
				
			||||||
 | 
					              }
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        },
 | 
					 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      required: ['weight', 'carModel', 'carLength']
 | 
					      required: ['weight', 'carModel', 'carLength']
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui4 = {
 | 
					    this.ui4 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
        spanLabelFixed: 90,
 | 
					        spanLabelFixed: 115,
 | 
				
			||||||
        grid: { span: 24 }
 | 
					        grid: { span: 8 }
 | 
				
			||||||
      },
 | 
					 | 
				
			||||||
      $weight: {
 | 
					 | 
				
			||||||
        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
					 | 
				
			||||||
      },
 | 
					 | 
				
			||||||
      $volume: {
 | 
					 | 
				
			||||||
        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
					 | 
				
			||||||
      },
 | 
					 | 
				
			||||||
      $number: {
 | 
					 | 
				
			||||||
        grid: { lg: 8, md: 12, sm: 12, xs: 24 }
 | 
					 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carModel: {
 | 
					      $carModel: {
 | 
				
			||||||
        spanLabelFixed: 100,
 | 
					        spanLabelFixed: 100,
 | 
				
			||||||
        grid: { span: 8 }
 | 
					        grid: { span: 8 }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      $carLength: {
 | 
					 | 
				
			||||||
        grid: { span: 8 }
 | 
					 | 
				
			||||||
      }
 | 
					 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  initSF5() {
 | 
					  initSF5() {
 | 
				
			||||||
    this.schema5 = {
 | 
					    this.schema5 = {
 | 
				
			||||||
      properties: {
 | 
					      properties: {
 | 
				
			||||||
@ -403,8 +394,17 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '增值服务套餐',
 | 
					          title: '增值服务套餐',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'dict-select',
 | 
					            widget: 'select',
 | 
				
			||||||
            params: { dictKey: 'bill:insurance:type' },
 | 
					            asyncData: () => {
 | 
				
			||||||
 | 
					              return this.service.request(this.service.$api_getDictValue, { dictKey: 'bill:insurance:type' }).pipe(
 | 
				
			||||||
 | 
					                map((res: any) => {
 | 
				
			||||||
 | 
					                  return [...res];
 | 
				
			||||||
 | 
					                })
 | 
				
			||||||
 | 
					              )
 | 
				
			||||||
 | 
					            },
 | 
				
			||||||
 | 
					            change: (tag: any, org: any) => {
 | 
				
			||||||
 | 
					              this.getInsurersPrice(tag);
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
          default: '3'
 | 
					          default: '3'
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -415,7 +415,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          readOnly: true,
 | 
					          readOnly: true,
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'checkbox',
 | 
					            widget: 'checkbox',
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value === '0' }
 | 
					            visibleIf: { insuranceType: (value: string) => value === '1' }
 | 
				
			||||||
          } as SFCheckboxWidgetSchema,
 | 
					          } as SFCheckboxWidgetSchema,
 | 
				
			||||||
          default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险']
 | 
					          default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险']
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -426,7 +426,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          readOnly: true,
 | 
					          readOnly: true,
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'checkbox',
 | 
					            widget: 'checkbox',
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value === '1' }
 | 
					            visibleIf: { insuranceType: (value: string) => value === '2' }
 | 
				
			||||||
          } as SFCheckboxWidgetSchema,
 | 
					          } as SFCheckboxWidgetSchema,
 | 
				
			||||||
          default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险']
 | 
					          default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险']
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -444,6 +444,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'dict-select',
 | 
					            widget: 'dict-select',
 | 
				
			||||||
            params: { dictKey: 'insure:packaged:goods' },
 | 
					            params: { dictKey: 'insure:packaged:goods' },
 | 
				
			||||||
 | 
					            containsAllLabel: false,
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
					            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
				
			||||||
          } as SFSelectWidgetSchema
 | 
					          } as SFSelectWidgetSchema
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -469,6 +470,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          title: '',
 | 
					          title: '',
 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
 | 
					            validator: val => this.customValidator(val),
 | 
				
			||||||
            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
					            visibleIf: { insuranceType: (value: string) => value !== '3' }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
@ -478,9 +480,9 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            hidden: true
 | 
					            hidden: true
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      },
 | 
					      required: ['insurancePackagedGoods', 'insurancePremium']
 | 
				
			||||||
      required: ['insurancePackagedGoods']
 | 
					 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui5 = {
 | 
					    this.ui5 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
@ -495,9 +497,10 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
      },
 | 
					      },
 | 
				
			||||||
      $freeInsurance: {
 | 
					      $freeInsurance: {
 | 
				
			||||||
        grid: { span: 24 }
 | 
					        grid: { span: 24 }
 | 
				
			||||||
      },
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  initSF6() {
 | 
					  initSF6() {
 | 
				
			||||||
    this.schema6 = {
 | 
					    this.schema6 = {
 | 
				
			||||||
      properties: {
 | 
					      properties: {
 | 
				
			||||||
@ -520,7 +523,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            widget: 'dict-select',
 | 
					            widget: 'dict-select',
 | 
				
			||||||
            params: { dictKey: 'receipt:type' },
 | 
					            params: { dictKey: 'receipt:type' },
 | 
				
			||||||
            containsAllLable: false,
 | 
					            containsAllLabel: false,
 | 
				
			||||||
            placeholder: '请选择',
 | 
					            placeholder: '请选择',
 | 
				
			||||||
            errors: { required: '请选择' },
 | 
					            errors: { required: '请选择' },
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
@ -528,58 +531,65 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
            }
 | 
					            }
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        // receiptAddressId: {
 | 
					        receiptAddress: {
 | 
				
			||||||
        //   type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
        //   title: '选择地址',
 | 
					          title: '回单收件人信息',
 | 
				
			||||||
        //   ui: {
 | 
					          ui: {
 | 
				
			||||||
        //     widget: 'custom',
 | 
					            widget: 'custom',
 | 
				
			||||||
        //     placeholder: '请点击选择收回单地址',
 | 
					            placeholder: '请点击选择回单收件人信息',
 | 
				
			||||||
        //     // validator: val => (this.sf6?.value?.receiptType === '2' ? [{ keyword: 'required', message: '请点击选择收回单地址' }] : []),
 | 
					            // validator: val => (this.sf6?.value?.receiptType === '2' ? [{ keyword: 'required', message: '请点击选择收回单地址' }] : []),
 | 
				
			||||||
        //     visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
        //       receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
        //     }
 | 
					            }
 | 
				
			||||||
        //   },
 | 
					          },
 | 
				
			||||||
        //   default: ''
 | 
					          default: ''
 | 
				
			||||||
        // },
 | 
					        },
 | 
				
			||||||
 | 
					        receiptAddressId: {
 | 
				
			||||||
 | 
					          type: 'string',
 | 
				
			||||||
 | 
					          title: '',
 | 
				
			||||||
 | 
					          ui: {
 | 
				
			||||||
 | 
					            hidden: true
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					        },
 | 
				
			||||||
        receiptUserName: {
 | 
					        receiptUserName: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '联系人',
 | 
					          title: '联系人',
 | 
				
			||||||
          maxLength: 15,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
 | 
					          readOnly: true
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        receiptUserPhone: {
 | 
					        phon: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '联系电话',
 | 
					          title: '联系电话',
 | 
				
			||||||
          maxLength: 11,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
 | 
					          readOnly: true
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        receiptAddressArea: {
 | 
					        area: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '所在地区',
 | 
					          title: '所在地区',
 | 
				
			||||||
          maxLength: 30,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
 | 
					          readOnly: true
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        receiptAddress: {
 | 
					        address: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
          title: '详细地址',
 | 
					          title: '详细地址',
 | 
				
			||||||
          maxLength: 50,
 | 
					 | 
				
			||||||
          ui: {
 | 
					          ui: {
 | 
				
			||||||
            visibleIf: {
 | 
					            visibleIf: {
 | 
				
			||||||
              receiptType: value => value === '2'
 | 
					              receiptType: value => value === '2'
 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          },
 | 
					          },
 | 
				
			||||||
 | 
					          readOnly: true
 | 
				
			||||||
        },
 | 
					        },
 | 
				
			||||||
        remarks: {
 | 
					        remarks: {
 | 
				
			||||||
          type: 'string',
 | 
					          type: 'string',
 | 
				
			||||||
@ -592,15 +602,16 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          } as SFTextareaWidgetSchema
 | 
					          } as SFTextareaWidgetSchema
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
      required: ['stateReceipt', 'receiptType', 'receiptUserName','receiptUserPhone','receiptAddressArea','receiptAddress']
 | 
					      required: ['stateReceipt', 'receiptType', 'receiptAddress']
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
    this.ui6 = {
 | 
					    this.ui6 = {
 | 
				
			||||||
      '*': {
 | 
					      '*': {
 | 
				
			||||||
        spanLabelFixed: 90,
 | 
					        spanLabelFixed: 115,
 | 
				
			||||||
        grid: { span: 24 }
 | 
					        grid: { span: 24 }
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  initSF7() {
 | 
					  initSF7() {
 | 
				
			||||||
    this.schema7 = {
 | 
					    this.schema7 = {
 | 
				
			||||||
      properties: {
 | 
					      properties: {
 | 
				
			||||||
@ -643,6 +654,29 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
      }
 | 
					      }
 | 
				
			||||||
    };
 | 
					    };
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					    // 不可选择的时间
 | 
				
			||||||
 | 
					    disabledDateStart = (current: Date): boolean => {
 | 
				
			||||||
 | 
					      return differenceInCalendarDays(new Date(), current) > 0;
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					  
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * 自定义校验数据
 | 
				
			||||||
 | 
					     * @param val
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    customValidator(val: number) {
 | 
				
			||||||
 | 
					      if (this.isEmpty(val)) {
 | 
				
			||||||
 | 
					        return [{ keyword: 'required', message: '不能为空' }];
 | 
				
			||||||
 | 
					      } else {
 | 
				
			||||||
 | 
					        if (val <= 0) {
 | 
				
			||||||
 | 
					          return [{ keyword: 'required', message: '数值需大于0' }];
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        return [];
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					  
 | 
				
			||||||
 | 
					    isEmpty(val: any) {
 | 
				
			||||||
 | 
					      return val === undefined || val === null || val.toString().trim() === '';
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
  // 获取城市列表
 | 
					  // 获取城市列表
 | 
				
			||||||
  getRegionCode(regionCode: any) {
 | 
					  getRegionCode(regionCode: any) {
 | 
				
			||||||
    console.log(regionCode);
 | 
					    console.log(regionCode);
 | 
				
			||||||
@ -663,31 +697,29 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
  }
 | 
					  }
 | 
				
			||||||
  payChange() {
 | 
					  payChange() {
 | 
				
			||||||
    const prePay = this.sf7.value.prePay || 0;
 | 
					    const prePay = this.sf7.value.prePay || 0;
 | 
				
			||||||
    const toPay = this.sf7.value.toPay || 0
 | 
					    const toPay = this.sf7.value.toPay || 0;
 | 
				
			||||||
    const receiptPay = this.sf7.value.receiptPay || 0;
 | 
					    const receiptPay = this.sf7.value.receiptPay || 0;
 | 
				
			||||||
    // const oilCardPay = 0;
 | 
					    const oilCardPay = 0;
 | 
				
			||||||
    const subtotal = prePay + toPay + receiptPay;
 | 
					    const subtotal = prePay + toPay + receiptPay;
 | 
				
			||||||
    const params = {
 | 
					    const params = {
 | 
				
			||||||
      shipperId: this.envCache?.enterpriseId,
 | 
					      shipperId: this?.sf1.value?.shipperAppUserId,
 | 
				
			||||||
      enterpriseInfoId: this.envCache?.networkTransporterId,
 | 
					      enterpriseInfoId: this?.sf1.value?.enterpriseInfoName,
 | 
				
			||||||
      totalFreight: subtotal,
 | 
					      totalFreight: subtotal,
 | 
				
			||||||
      // fuelCardAmount:oilCardPay,
 | 
					      fuelCardAmount: oilCardPay,
 | 
				
			||||||
      resourcetype: '1'
 | 
					      resourcetype: '1'
 | 
				
			||||||
    }
 | 
					    };
 | 
				
			||||||
    this.service
 | 
					    this.service.request(this.service.$api_getCalculatedSurcharge, params).subscribe(res => {
 | 
				
			||||||
      .request(this.service.$api_getCalculatedSurcharge,params)
 | 
					      console.log('999')
 | 
				
			||||||
      .subscribe(res => {
 | 
					      console.log(this?.sf1.value)
 | 
				
			||||||
      if (res) {
 | 
					      if (res) {
 | 
				
			||||||
        this.sf7.setValue('/appendFee', res.surcharge);
 | 
					        this.sf7.setValue('/appendFee', res.surcharge);
 | 
				
			||||||
        this.sf7.setValue('/subtotal', subtotal);
 | 
					        this.sf7.setValue('/subtotal', subtotal);
 | 
				
			||||||
        this.sf7.setValue('/total', subtotal + res.surcharge);
 | 
					        this.sf7.setValue('/total', subtotal + res.surcharge);
 | 
				
			||||||
        this.service
 | 
					        this.service
 | 
				
			||||||
            .request(this.service.$api_getcalculatedServiceRate + `?invoiceAmount=${subtotal + res.surcharge}&totalFreight=${subtotal}`)
 | 
					          .request(this.service.$api_getAdditionalRate + `?shipperId=${this?.sf1.value?.shipperAppUserId}&enterpriseInfoId=${this?.sf1.value?.enterpriseInfoName}&resourcetype='1'`)
 | 
				
			||||||
          .subscribe(res => {
 | 
					          .subscribe(res => {
 | 
				
			||||||
            if (res) {
 | 
					            if (res) {
 | 
				
			||||||
              this.currentRate = res.rate * 100;
 | 
					              this.currentRate = res.rate * 100;
 | 
				
			||||||
              } else {
 | 
					 | 
				
			||||||
                this.service.msgSrv.error(res.msg);
 | 
					 | 
				
			||||||
            }
 | 
					            }
 | 
				
			||||||
          });
 | 
					          });
 | 
				
			||||||
      } else {
 | 
					      } else {
 | 
				
			||||||
@ -983,6 +1015,8 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
          if (this.sf3data.goodsNameId) {
 | 
					          if (this.sf3data.goodsNameId) {
 | 
				
			||||||
            this.sf3.setValue('/goodsNameId', this.sf3data.goodsNameId);
 | 
					            this.sf3.setValue('/goodsNameId', this.sf3data.goodsNameId);
 | 
				
			||||||
          }
 | 
					          }
 | 
				
			||||||
 | 
					        } else {
 | 
				
			||||||
 | 
					          this.service.msgSrv.error(res.msg);
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      });
 | 
					      });
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
@ -1049,17 +1083,13 @@ export class SupplyManagementReleasePublishComponent implements OnInit {
 | 
				
			|||||||
        });
 | 
					        });
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    getInsurersPrice() {
 | 
					  // 计算保价费金额
 | 
				
			||||||
      console.log(this.sf5.value.goodsValue)
 | 
					  getInsurersPrice(insuranceType = this.sf5.value.insuranceType) {
 | 
				
			||||||
      console.log(this.sf5.value.insuranceType)
 | 
					    if (this.sf5.value.goodsValue >= 50000 && this.totalDistance > 0) {
 | 
				
			||||||
      if (this.sf5.value.goodsValue >= 50000) {
 | 
					
 | 
				
			||||||
        if(this.totalDistance <=0){
 | 
					 | 
				
			||||||
          this.service.msgSrv.warning('当前装卸货距离为0,无法计算保价费金额');
 | 
					 | 
				
			||||||
          return;
 | 
					 | 
				
			||||||
        }
 | 
					 | 
				
			||||||
      const params = {
 | 
					      const params = {
 | 
				
			||||||
 | 
					        insuranceType,
 | 
				
			||||||
        goodsValue: this.sf5.value.goodsValue,
 | 
					        goodsValue: this.sf5.value.goodsValue,
 | 
				
			||||||
          insuranceType: this.sf5.value.insuranceType,
 | 
					 | 
				
			||||||
        km: this.totalDistance
 | 
					        km: this.totalDistance
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
      this.service.request(this.service.$api_getWholeInsuranceInfo, params).subscribe(res => {
 | 
					      this.service.request(this.service.$api_getWholeInsuranceInfo, params).subscribe(res => {
 | 
				
			||||||
 | 
				
			|||||||
@ -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-02-28 11:31:44
 | 
					 * @LastEditTime : 2022-02-28 15:22:19
 | 
				
			||||||
 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\supply-management\\services\\supply-management.service.ts
 | 
					 * @FilePath     : \\tms-obc-web\\src\\app\\routes\\supply-management\\services\\supply-management.service.ts
 | 
				
			||||||
 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
					 * Copyright (C) 2022 huzhenhong. All rights reserved.
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
@ -54,6 +54,8 @@ export class SupplyManagementService extends BaseService {
 | 
				
			|||||||
  $api_getCalculatedSurcharge = `/api/sdc/expense/getCalculatedSurcharge`;
 | 
					  $api_getCalculatedSurcharge = `/api/sdc/expense/getCalculatedSurcharge`;
 | 
				
			||||||
  // 整车计算附加费率
 | 
					  // 整车计算附加费率
 | 
				
			||||||
  $api_getcalculatedServiceRate = `/api/sdc/expense/getAdditionalRate`;
 | 
					  $api_getcalculatedServiceRate = `/api/sdc/expense/getAdditionalRate`;
 | 
				
			||||||
 | 
					    // 整车计算附加费率
 | 
				
			||||||
 | 
					    $api_getAdditionalRate = `/api/sdc/expense/getAdditionalRate`;
 | 
				
			||||||
  // 代发整车货源
 | 
					  // 代发整车货源
 | 
				
			||||||
  $api_consignWhole = `/api/sdc/goodsResourceOperate/consignWhole`;
 | 
					  $api_consignWhole = `/api/sdc/goodsResourceOperate/consignWhole`;
 | 
				
			||||||
  // 代发大宗货源
 | 
					  // 代发大宗货源
 | 
				
			||||||
@ -113,6 +115,8 @@ export class SupplyManagementService extends BaseService {
 | 
				
			|||||||
  $api_getDictValue = `/api/mdc/pbc/dictItems/getDictValue`;
 | 
					  $api_getDictValue = `/api/mdc/pbc/dictItems/getDictValue`;
 | 
				
			||||||
  // 获取协议信息
 | 
					  // 获取协议信息
 | 
				
			||||||
  public $api_getAgreementInfoByType = '/api/mdc/pbc/agreementInfo/getAgreementInfoByType';
 | 
					  public $api_getAgreementInfoByType = '/api/mdc/pbc/agreementInfo/getAgreementInfoByType';
 | 
				
			||||||
 | 
					  // 获取运价
 | 
				
			||||||
 | 
					  public $api_getFreight = '/api/mdc/cuc/freightConfig/getFreight';
 | 
				
			||||||
  /**
 | 
					  /**
 | 
				
			||||||
   * 获取车型、车长字典数据
 | 
					   * 获取车型、车长字典数据
 | 
				
			||||||
   * @returns
 | 
					   * @returns
 | 
				
			||||||
@ -132,6 +136,13 @@ export class SupplyManagementService extends BaseService {
 | 
				
			|||||||
  constructor(public injector: Injector) {
 | 
					  constructor(public injector: Injector) {
 | 
				
			||||||
    super(injector);
 | 
					    super(injector);
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  public limitKeys = {
 | 
				
			||||||
 | 
					    weight: 'sys.config.goods.approvalCarMaxWeight', //整车-核载重量上限
 | 
				
			||||||
 | 
					    volume: 'sys.config.goods.approvalCarMaxVolume', //整车-核载体积上限
 | 
				
			||||||
 | 
					    piece: 'sys.config.goods.approvalCarMaxPiece' //整车-核载件数上限
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
 | 
					  // 根据ItemKey获取项值
 | 
				
			||||||
 | 
					  public $api_findItemValueByItemKeys = '/api/mdc/pbc/sysConfigItem/findItemValueByItemKeys';
 | 
				
			||||||
  // 获取保价费信息
 | 
					  // 获取保价费信息
 | 
				
			||||||
  public $api_getWholeInsuranceInfo = '/api/sdc/goodsResourceShipper/getWholeInsuranceInfo';
 | 
					  public $api_getWholeInsuranceInfo = '/api/sdc/goodsResourceShipper/getWholeInsuranceInfo';
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user