fix bug
This commit is contained in:
		| @ -10,6 +10,16 @@ | |||||||
| --> | --> | ||||||
| <nz-alert nzType="info" [nzMessage]="'已选择'+ data?.ids?.length + '条订单'" nzShowIcon></nz-alert> | <nz-alert nzType="info" [nzMessage]="'已选择'+ data?.ids?.length + '条订单'" nzShowIcon></nz-alert> | ||||||
| <sf style="margin-top: 15px" #sf mode="edit" [schema]="schema" [ui]="ui" button="none"></sf> | <sf style="margin-top: 15px" #sf mode="edit" [schema]="schema" [ui]="ui" button="none"></sf> | ||||||
|  |  | ||||||
|  | <st #st [data]="service.$api_getChangeRecordWholeDetail" [columns]="columns" | ||||||
|  | [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams}" | ||||||
|  | [res]="{ reName: { list: 'data.records', total: 'data.total' } }" | ||||||
|  | [page]="{}" | ||||||
|  | > | ||||||
|  | <ng-template st-row="operator" let-item> | ||||||
|  |   {{item?.operator}}/{{item.telephone}} | ||||||
|  | </ng-template> | ||||||
|  | </st> | ||||||
| <div class="modal-footer"> | <div class="modal-footer"> | ||||||
|   <button nz-button type="button" (click)="close()">关闭</button> |   <button nz-button type="button" (click)="close()">关闭</button> | ||||||
|   <button nz-button type="submit" nzType="primary" (click)="save(sf.value)">确定</button> |   <button nz-button type="submit" nzType="primary" (click)="save(sf.value)">确定</button> | ||||||
|  | |||||||
| @ -4,12 +4,13 @@ | |||||||
|  * @Author       : Shiming |  * @Author       : Shiming | ||||||
|  * @Date         : 2021-12-29 14:51:07 |  * @Date         : 2021-12-29 14:51:07 | ||||||
|  * @LastEditors  : Shiming |  * @LastEditors  : Shiming | ||||||
|  * @LastEditTime : 2022-02-24 11:10:33 |  * @LastEditTime : 2022-03-04 14:45:58 | ||||||
|  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\modify-rate\\modify-rate.component.ts |  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\order-management\\modal\\vehicle\\modify-rate\\modify-rate.component.ts | ||||||
|  * Copyright (C) 2022 huzhenhong. All rights reserved. |  * Copyright (C) 2022 huzhenhong. All rights reserved. | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| import { Component, Input, OnInit, ViewChild } from '@angular/core'; | import { Component, Input, OnInit, ViewChild } from '@angular/core'; | ||||||
|  | import { STColumn } from '@delon/abc/st'; | ||||||
| import { SFComponent, SFNumberWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; | import { SFComponent, SFNumberWidgetSchema, SFSchema, SFUISchema } from '@delon/form'; | ||||||
| import { NzMessageService } from 'ng-zorro-antd/message'; | import { NzMessageService } from 'ng-zorro-antd/message'; | ||||||
| import { NzModalRef } from 'ng-zorro-antd/modal'; | import { NzModalRef } from 'ng-zorro-antd/modal'; | ||||||
| @ -24,7 +25,11 @@ export class VehicleModifyRateComponent implements OnInit { | |||||||
|   @ViewChild('sf', { static: false }) sf!: SFComponent; |   @ViewChild('sf', { static: false }) sf!: SFComponent; | ||||||
|   schema: SFSchema = {}; |   schema: SFSchema = {}; | ||||||
|   ui: SFUISchema = {}; |   ui: SFUISchema = {}; | ||||||
|  |   columns: STColumn[] = [ | ||||||
|  |     { title: '内容', index: 'operationContent' }, | ||||||
|  |     { title: '操作人', index: 'operator' }, | ||||||
|  |     { title: '操作时间', index: 'operatorTimestamp' }, | ||||||
|  |   ]; | ||||||
|   aggreechecked = false; |   aggreechecked = false; | ||||||
|  |  | ||||||
|   @Input() |   @Input() | ||||||
| @ -36,6 +41,12 @@ export class VehicleModifyRateComponent implements OnInit { | |||||||
|     console.log(this.data); |     console.log(this.data); | ||||||
|     this.initSF(); |     this.initSF(); | ||||||
|   } |   } | ||||||
|  |   get reqParams() { | ||||||
|  |     return {  | ||||||
|  |       // operateObject: this.i?.resourceCode, | ||||||
|  |       // operateType: 4, | ||||||
|  |      }; | ||||||
|  |   } | ||||||
|   initSF() { |   initSF() { | ||||||
|     this.schema = { |     this.schema = { | ||||||
|       properties: { |       properties: { | ||||||
|  | |||||||
| @ -171,7 +171,7 @@ | |||||||
|   </nz-card> |   </nz-card> | ||||||
|   <nz-card nzTitle="操作日志"> |   <nz-card nzTitle="操作日志"> | ||||||
|     <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="logColumns" |     <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="logColumns" | ||||||
|       [page]="{ show: false, showSize: false }" |     [page]="{}" | ||||||
|       [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" |       [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" | ||||||
|       [res]="{ reName: { list: 'data.records', total: 'data.total' } }"> |       [res]="{ reName: { list: 'data.records', total: 'data.total' } }"> | ||||||
|     </st> |     </st> | ||||||
|  | |||||||
| @ -228,13 +228,15 @@ | |||||||
|     </ng-template> |     </ng-template> | ||||||
|   </sf> |   </sf> | ||||||
| </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="16"> |     <div nz-col nzSpan="16"> | ||||||
|       <sf #sf5 [schema]="schema5" [button]="'none'" [ui]="ui5" [formData]="sf5data"> |       <sf #sf5 [schema]="schema5" [button]="'none'" [ui]="ui5" [formData]="sf5data"> | ||||||
|         <ng-template sf-template="freeInsurance" let-i let-ui="ui"> |         <ng-template sf-template="freeInsurance1" let-i let-ui="ui"> | ||||||
|  |           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> | ||||||
|  |         </ng-template> | ||||||
|  |         <ng-template sf-template="freeInsurance2" let-i let-ui="ui"> | ||||||
|           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> |           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> | ||||||
|         </ng-template> |         </ng-template> | ||||||
|         <ng-template #template1>推荐投保,填写货值自动估保费,司机接单后不可退保。详见<a target="_blank" [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《投保告知》</a></ng-template> |         <ng-template #template1>推荐投保,填写货值自动估保费,司机接单后不可退保。详见<a target="_blank" [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《投保告知》</a></ng-template> | ||||||
| @ -243,10 +245,10 @@ | |||||||
|             <nz-input-number |             <nz-input-number | ||||||
|               [ngModel]="i.value" |               [ngModel]="i.value" | ||||||
|               [nzMin]="50000" |               [nzMin]="50000" | ||||||
|               [nzMax]="3000000" |               [nzMax]="2000000" | ||||||
|               [nzStep]="0.01" |               [nzStep]="0.01" | ||||||
|               (ngModelChange)="i.setValue($event);getInsurersPrice()" |               (ngModelChange)="i.setValue($event);getInsurersPrice()" | ||||||
|               nzPlaceHolder="请输入50000-3000000之间数值" |               nzPlaceHolder="请输入50000-2000000之间数值" | ||||||
|             ></nz-input-number> |             ></nz-input-number> | ||||||
|           </div> |           </div> | ||||||
|         </ng-template> |         </ng-template> | ||||||
| @ -258,9 +260,10 @@ | |||||||
|             ></span> |             ></span> | ||||||
|             <ng-template #template2> |             <ng-template #template2> | ||||||
|               <p>注意事项:</p> |               <p>注意事项:</p> | ||||||
|               <p>①请仔细阅读《投保告知》</p> |               <p>①请仔细阅读《投保告知函》;</p> | ||||||
|               <p>②港澳台、西藏不在投保范围内,不予承保</p> |               <p>②香港、澳门、台湾、西藏、新疆不在投保范围内,不予承保;</p> | ||||||
|               <p>③保价费最低收费2元,请按真实货值填写,录入的所有信息必须确保真实,不如实录入的内容,不承担对应赔偿责任。</p> |               <p>③最低保费12元/每单;单次运输保额仅限200万元以内;</p> | ||||||
|  |               <p>④本保险只限于货物起运前投保,起运后投保无效,保险人不负赔偿责任;</p> | ||||||
|             </ng-template> |             </ng-template> | ||||||
|           </div> |           </div> | ||||||
|         </ng-template> |         </ng-template> | ||||||
|  | |||||||
| @ -411,7 +411,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|       properties: { |       properties: { | ||||||
|         insuranceType: { |         insuranceType: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '增值服务套餐', |           title: '服务包', | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'select', |             widget: 'select', | ||||||
|             asyncData: () => { |             asyncData: () => { | ||||||
| @ -419,10 +419,15 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|                 map((res: any) => { |                 map((res: any) => { | ||||||
|                   return [...res]; |                   return [...res]; | ||||||
|                 }) |                 }) | ||||||
|               ); |               ) | ||||||
|             }, |             }, | ||||||
|             change: (tag: any, org: any) => { |             change: (tag: any, org: any) => { | ||||||
|               this.getInsurersPrice(tag); |               if(tag === '3'){ | ||||||
|  |                 this.sf5.setValue('/insurancePremium', null); | ||||||
|  |                 this.sf5.setValue('/insuranceRate', null); | ||||||
|  |               }else { | ||||||
|  |                 this.getInsurersPrice(tag); | ||||||
|  |               } | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           default: '3' |           default: '3' | ||||||
| @ -430,31 +435,39 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|         type1: { |         type1: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '', |           title: '', | ||||||
|           enum: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险'], |           enum: ['资源曝光率 +10', '车源匹配率 +10'], | ||||||
|  |           readOnly: true, | ||||||
|  |           ui: { | ||||||
|  |             widget: 'checkbox', | ||||||
|  |             visibleIf: { insuranceType: (value: string) => value === '0' } | ||||||
|  |           } as SFCheckboxWidgetSchema, | ||||||
|  |           default: ['资源曝光率 +10', '车源匹配率 +10'] | ||||||
|  |         }, | ||||||
|  |         type2: { | ||||||
|  |           type: 'string', | ||||||
|  |           title: '', | ||||||
|  |           enum: ['资源曝光率 +20', '车源匹配率 +20'], | ||||||
|           readOnly: true, |           readOnly: true, | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'checkbox', |             widget: 'checkbox', | ||||||
|             visibleIf: { insuranceType: (value: string) => value === '1' } |             visibleIf: { insuranceType: (value: string) => value === '1' } | ||||||
|           } as SFCheckboxWidgetSchema, |           } as SFCheckboxWidgetSchema, | ||||||
|           default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险'] |           default: ['资源曝光率 +20', '车源匹配率 +20'] | ||||||
|         }, |         }, | ||||||
|         type2: { |         freeInsurance1: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '', |           title: '赠送基本险', | ||||||
|           enum: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险'], |  | ||||||
|           readOnly: true, |  | ||||||
|           ui: { |  | ||||||
|             widget: 'checkbox', |  | ||||||
|             visibleIf: { insuranceType: (value: string) => value === '2' } |  | ||||||
|           } as SFCheckboxWidgetSchema, |  | ||||||
|           default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险'] |  | ||||||
|         }, |  | ||||||
|         freeInsurance: { |  | ||||||
|           type: 'string', |  | ||||||
|           title: '赠送保险', |  | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'custom', |             widget: 'custom', | ||||||
|             visibleIf: { insuranceType: (value: string) => value !== '3' } |             visibleIf: { insuranceType: (value: string) => value === '0' } | ||||||
|  |           } | ||||||
|  |         }, | ||||||
|  |         freeInsurance2: { | ||||||
|  |           type: 'string', | ||||||
|  |           title: '赠送综合险', | ||||||
|  |           ui: { | ||||||
|  |             widget: 'custom', | ||||||
|  |             visibleIf: { insuranceType: (value: string) => value === '1' } | ||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         insurancePackagedGoods: { |         insurancePackagedGoods: { | ||||||
| @ -480,7 +493,6 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|           title: '货物价值', |           title: '货物价值', | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'custom', |             widget: 'custom', | ||||||
|             descriptionI18n: '输入50000-3000000之间数值', |  | ||||||
|             visibleIf: { insuranceType: (value: string) => value !== '3' } |             visibleIf: { insuranceType: (value: string) => value !== '3' } | ||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
| @ -514,7 +526,10 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|       $type2: { |       $type2: { | ||||||
|         grid: { span: 24 } |         grid: { span: 24 } | ||||||
|       }, |       }, | ||||||
|       $freeInsurance: { |       $freeInsurance1: { | ||||||
|  |         grid: { span: 24 } | ||||||
|  |       }, | ||||||
|  |       $freeInsurance2: { | ||||||
|         grid: { span: 24 } |         grid: { span: 24 } | ||||||
|       } |       } | ||||||
|     }; |     }; | ||||||
| @ -1199,13 +1214,14 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|         this.validateForm1.addControl(`unloadPhone${controlId}`, new FormControl(null, Validators.required)); |         this.validateForm1.addControl(`unloadPhone${controlId}`, new FormControl(null, Validators.required)); | ||||||
|       } |       } | ||||||
|  |  | ||||||
|       // 计算里程,时间 |          // 计算里程,时间 | ||||||
|       if (this.startInfo?.[0]?.area && this.endInfo?.[0]?.area) { |          if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) { | ||||||
|         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(); //计算保费金额 | ||||||
|       } |           }); | ||||||
|  |         } | ||||||
|     }); |     }); | ||||||
|  |  | ||||||
|     this.sf3data = { |     this.sf3data = { | ||||||
| @ -1314,14 +1330,14 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|           default: |           default: | ||||||
|             break; |             break; | ||||||
|         } |         } | ||||||
|         // 计算里程,时间 |       // 计算里程,时间 | ||||||
|         if (this.startInfo[0]?.area && this.endInfo[0]?.area) { |     if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) { | ||||||
|           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(); //计算保费金额 |         this.getInsurersPrice(); //计算保费金额 | ||||||
|           }); |       }); | ||||||
|         } |     } | ||||||
|       } |       } | ||||||
|     }); |     }); | ||||||
|   } |   } | ||||||
| @ -1365,7 +1381,7 @@ export class SupplyManagementOnecarPublishComponent implements OnInit { | |||||||
|       this.validateForm1.addControl(`unloadPhone${index}`, new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')])); |       this.validateForm1.addControl(`unloadPhone${index}`, new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')])); | ||||||
|     }); |     }); | ||||||
|     // 计算里程,时间 |     // 计算里程,时间 | ||||||
|     if (this.startInfo[0]?.area && this.endInfo[0]?.area) { |     if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) { | ||||||
|       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; | ||||||
|  | |||||||
| @ -238,7 +238,10 @@ | |||||||
|   <div nz-row> |   <div nz-row> | ||||||
|     <div nz-col nzSpan="16"> |     <div nz-col nzSpan="16"> | ||||||
|       <sf #sf5 [schema]="schema5" [button]="'none'" [ui]="ui5" [formData]="sf5data"> |       <sf #sf5 [schema]="schema5" [button]="'none'" [ui]="ui5" [formData]="sf5data"> | ||||||
|         <ng-template sf-template="freeInsurance" let-i let-ui="ui"> |         <ng-template sf-template="freeInsurance1" let-i let-ui="ui"> | ||||||
|  |           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> | ||||||
|  |         </ng-template> | ||||||
|  |         <ng-template sf-template="freeInsurance2" let-i let-ui="ui"> | ||||||
|           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> |           <nz-alert nzType="warning" [nzMessage]="template1" nzShowIcon></nz-alert> | ||||||
|         </ng-template> |         </ng-template> | ||||||
|         <ng-template #template1>推荐投保,填写货值自动估保费,司机接单后不可退保。详见<a target="_blank" [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《投保告知》</a></ng-template> |         <ng-template #template1>推荐投保,填写货值自动估保费,司机接单后不可退保。详见<a target="_blank" [queryParams]="{ type: 10 }" [routerLink]="['/agreement']">《投保告知》</a></ng-template> | ||||||
| @ -247,10 +250,10 @@ | |||||||
|             <nz-input-number |             <nz-input-number | ||||||
|               [ngModel]="i.value" |               [ngModel]="i.value" | ||||||
|               [nzMin]="50000" |               [nzMin]="50000" | ||||||
|               [nzMax]="3000000" |               [nzMax]="2000000" | ||||||
|               [nzStep]="0.01" |               [nzStep]="0.01" | ||||||
|               (ngModelChange)="i.setValue($event);getInsurersPrice()" |               (ngModelChange)="i.setValue($event);getInsurersPrice()" | ||||||
|               nzPlaceHolder="请输入50000-3000000之间数值" |               nzPlaceHolder="请输入50000-2000000之间数值" | ||||||
|             ></nz-input-number> |             ></nz-input-number> | ||||||
|           </div> |           </div> | ||||||
|         </ng-template> |         </ng-template> | ||||||
| @ -262,9 +265,10 @@ | |||||||
|             ></span> |             ></span> | ||||||
|             <ng-template #template2> |             <ng-template #template2> | ||||||
|               <p>注意事项:</p> |               <p>注意事项:</p> | ||||||
|               <p>①请仔细阅读《投保告知》</p> |               <p>①请仔细阅读《投保告知函》;</p> | ||||||
|               <p>②港澳台、西藏不在投保范围内,不予承保</p> |               <p>②香港、澳门、台湾、西藏、新疆不在投保范围内,不予承保;</p> | ||||||
|               <p>③保价费最低收费2元,请按真实货值填写,录入的所有信息必须确保真实,不如实录入的内容,不承担对应赔偿责任。</p> |               <p>③最低保费12元/每单;单次运输保额仅限200万元以内;</p> | ||||||
|  |               <p>④本保险只限于货物起运前投保,起运后投保无效,保险人不负赔偿责任;</p> | ||||||
|             </ng-template> |             </ng-template> | ||||||
|           </div> |           </div> | ||||||
|         </ng-template> |         </ng-template> | ||||||
|  | |||||||
| @ -411,7 +411,7 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|       properties: { |       properties: { | ||||||
|         insuranceType: { |         insuranceType: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '增值服务套餐', |           title: '服务包', | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'select', |             widget: 'select', | ||||||
|             asyncData: () => { |             asyncData: () => { | ||||||
| @ -419,10 +419,15 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|                 map((res: any) => { |                 map((res: any) => { | ||||||
|                   return [...res]; |                   return [...res]; | ||||||
|                 }) |                 }) | ||||||
|               ); |               ) | ||||||
|             }, |             }, | ||||||
|             change: (tag: any, org: any) => { |             change: (tag: any, org: any) => { | ||||||
|               this.getInsurersPrice(tag); |               if(tag === '3'){ | ||||||
|  |                 this.sf5.setValue('/insurancePremium', null); | ||||||
|  |                 this.sf5.setValue('/insuranceRate', null); | ||||||
|  |               }else { | ||||||
|  |                 this.getInsurersPrice(tag); | ||||||
|  |               } | ||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           default: '3' |           default: '3' | ||||||
| @ -430,31 +435,39 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|         type1: { |         type1: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '', |           title: '', | ||||||
|           enum: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险'], |           enum: ['资源曝光率 +10', '车源匹配率 +10'], | ||||||
|  |           readOnly: true, | ||||||
|  |           ui: { | ||||||
|  |             widget: 'checkbox', | ||||||
|  |             visibleIf: { insuranceType: (value: string) => value === '0' } | ||||||
|  |           } as SFCheckboxWidgetSchema, | ||||||
|  |           default: ['资源曝光率 +10', '车源匹配率 +10'] | ||||||
|  |         }, | ||||||
|  |         type2: { | ||||||
|  |           type: 'string', | ||||||
|  |           title: '', | ||||||
|  |           enum: ['资源曝光率 +20', '车源匹配率 +20'], | ||||||
|           readOnly: true, |           readOnly: true, | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'checkbox', |             widget: 'checkbox', | ||||||
|             visibleIf: { insuranceType: (value: string) => value === '1' } |             visibleIf: { insuranceType: (value: string) => value === '1' } | ||||||
|           } as SFCheckboxWidgetSchema, |           } as SFCheckboxWidgetSchema, | ||||||
|           default: ['车辆实时定位', '轨迹查询', '数据保护', '赠送基本险'] |           default: ['资源曝光率 +20', '车源匹配率 +20'] | ||||||
|         }, |         }, | ||||||
|         type2: { |         freeInsurance1: { | ||||||
|           type: 'string', |           type: 'string', | ||||||
|           title: '', |           title: '赠送基本险', | ||||||
|           enum: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险'], |  | ||||||
|           readOnly: true, |  | ||||||
|           ui: { |  | ||||||
|             widget: 'checkbox', |  | ||||||
|             visibleIf: { insuranceType: (value: string) => value === '2' } |  | ||||||
|           } as SFCheckboxWidgetSchema, |  | ||||||
|           default: ['车辆实时定位', '轨迹查询', '数据保护', '专属技术服务', '赠送综合险'] |  | ||||||
|         }, |  | ||||||
|         freeInsurance: { |  | ||||||
|           type: 'string', |  | ||||||
|           title: '赠送保险', |  | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'custom', |             widget: 'custom', | ||||||
|             visibleIf: { insuranceType: (value: string) => value !== '3' } |             visibleIf: { insuranceType: (value: string) => value === '0' } | ||||||
|  |           } | ||||||
|  |         }, | ||||||
|  |         freeInsurance2: { | ||||||
|  |           type: 'string', | ||||||
|  |           title: '赠送综合险', | ||||||
|  |           ui: { | ||||||
|  |             widget: 'custom', | ||||||
|  |             visibleIf: { insuranceType: (value: string) => value === '1' } | ||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         insurancePackagedGoods: { |         insurancePackagedGoods: { | ||||||
| @ -480,7 +493,6 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|           title: '货物价值', |           title: '货物价值', | ||||||
|           ui: { |           ui: { | ||||||
|             widget: 'custom', |             widget: 'custom', | ||||||
|             descriptionI18n: '输入50000-3000000之间数值', |  | ||||||
|             visibleIf: { insuranceType: (value: string) => value !== '3' } |             visibleIf: { insuranceType: (value: string) => value !== '3' } | ||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
| @ -514,7 +526,10 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|       $type2: { |       $type2: { | ||||||
|         grid: { span: 24 } |         grid: { span: 24 } | ||||||
|       }, |       }, | ||||||
|       $freeInsurance: { |       $freeInsurance1: { | ||||||
|  |         grid: { span: 24 } | ||||||
|  |       }, | ||||||
|  |       $freeInsurance2: { | ||||||
|         grid: { span: 24 } |         grid: { span: 24 } | ||||||
|       } |       } | ||||||
|     }; |     }; | ||||||
| @ -1176,14 +1191,14 @@ export class SupplyManagementReleasePublishComponent implements OnInit { | |||||||
|       this.validateForm1.addControl(`unloadName${index}`, new FormControl(null, Validators.required)); |       this.validateForm1.addControl(`unloadName${index}`, new FormControl(null, Validators.required)); | ||||||
|       this.validateForm1.addControl(`unloadPhone${index}`, new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')])); |       this.validateForm1.addControl(`unloadPhone${index}`, new FormControl(null, [Validators.required, Validators.pattern('^[0-9]*$')])); | ||||||
|     }); |     }); | ||||||
|     // 计算里程,时间 |       // 计算里程,时间 | ||||||
|     if (this.startInfo[0]?.area && this.endInfo[0]?.area) { |       if (this.startInfo[0]?.detailedAddress && this.endInfo[0]?.detailedAddress) { | ||||||
|       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(); //计算保费金额 |           this.getInsurersPrice(); //计算保费金额 | ||||||
|       }); |         }); | ||||||
|     } |       } | ||||||
|   } |   } | ||||||
|   // 计算保价费金额 |   // 计算保价费金额 | ||||||
|   getInsurersPrice(insuranceType = this.sf5.value.insuranceType) { |   getInsurersPrice(insuranceType = this.sf5.value.insuranceType) { | ||||||
|  | |||||||
| @ -4,7 +4,7 @@ | |||||||
|  * @Author       : Shiming |  * @Author       : Shiming | ||||||
|  * @Date         : 2021-12-03 11:10:14 |  * @Date         : 2021-12-03 11:10:14 | ||||||
|  * @LastEditors  : Shiming |  * @LastEditors  : Shiming | ||||||
|  * @LastEditTime : 2022-03-04 14:34:57 |  * @LastEditTime : 2022-03-04 14:37:19 | ||||||
|  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\update-price\\update-price.component.html |  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\supply-management\\components\\update-price\\update-price.component.html | ||||||
|  * Copyright (C) 2022 huzhenhong. All rights reserved. |  * Copyright (C) 2022 huzhenhong. All rights reserved. | ||||||
| --> | --> | ||||||
| @ -25,18 +25,11 @@ | |||||||
| </div> | </div> | ||||||
| <div> | <div> | ||||||
|   <h4>变更日志</h4> |   <h4>变更日志</h4> | ||||||
|   <!-- <st #st [data]="service.$api_getOperationLogRecordsList" [bordered]="true" [columns]="columns" [page]="{ show: false }"     [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }"> |  | ||||||
|     <ng-template st-row="operator" let-item let-index="index"> |  | ||||||
|       <span>{{item.operator}}</span>/ |  | ||||||
|       <span>{{item.telephone}}</span> |  | ||||||
|     </ng-template> |  | ||||||
|   </st> --> |  | ||||||
|   <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="columns" |   <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="columns" | ||||||
|   [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams}" |   [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams}" | ||||||
|   [res]="{ reName: { list: 'data.records', total: 'data.total' } }" |   [res]="{ reName: { list: 'data.records', total: 'data.total' } }" | ||||||
|   [page]="{}" |   [page]="{}" | ||||||
|   > |   > | ||||||
|    |  | ||||||
|   <ng-template st-row="operator" let-item> |   <ng-template st-row="operator" let-item> | ||||||
|     {{item?.operator}}/{{item.telephone}} |     {{item?.operator}}/{{item.telephone}} | ||||||
|   </ng-template> |   </ng-template> | ||||||
|  | |||||||
| @ -213,7 +213,7 @@ | |||||||
|   </nz-card> |   </nz-card> | ||||||
|   <nz-card nzTitle="操作日志"> |   <nz-card nzTitle="操作日志"> | ||||||
|     <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="logColumns" |     <st #st [data]="service.$api_getOperationLogRecordsList" [columns]="logColumns" | ||||||
|     [page]="{ show: false, showSize: false }" |     [page]="{}" | ||||||
|     [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" |     [req]="{ method: 'POST', allInBody: true, reName: { pi: 'pageIndex', ps: 'pageSize' }, params: reqParams }" | ||||||
|     [res]="{ reName: { list: 'data.records', total: 'data.total' } }"> |     [res]="{ reName: { list: 'data.records', total: 'data.total' } }"> | ||||||
|   </st> |   </st> | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user