fix bug
This commit is contained in:
		| @ -31,7 +31,7 @@ | ||||
|       </div> | ||||
|       <div nz-col [nzSpan]="_$expand ? 24 : 6" class="text-right"> | ||||
|         <button nz-button nzType="primary" [nzLoading]="false" (click)="search()"  acl  [acl-ability]="['WAYBILL-BULK-search']">查询</button> | ||||
|         <button nz-button nzType="primary" [disabled]="false" acl  [acl-ability]="['WAYBILL-BULK-export']">导出</button> | ||||
|         <button nz-button nzType="primary" [disabled]="false" acl  [acl-ability]="['WAYBILL-BULK-export']" (click)="exprot()">导出</button> | ||||
|         <button nz-button [disabled]="false" (click)="resetSF()">重置</button> | ||||
|         <button nz-button nzType="link" (click)="expandToggle()"> | ||||
|           {{ !_$expand ? '展开' : '收起' }} | ||||
|  | ||||
| @ -473,4 +473,12 @@ export class WaybillManagementBulkComponent implements OnInit { | ||||
|       this.getGoodsSourceStatistical() | ||||
|     }); | ||||
|   } | ||||
|      // 导出 | ||||
|      exprot() { | ||||
|       this.service.request(this.service.$api_asyncExportBulkList, this.reqParams).subscribe((res: any) => { | ||||
|         if (res) { | ||||
|           this.service.msgSrv.success('导出成功,请去下载中心下载!'); | ||||
|         } | ||||
|       }); | ||||
|     } | ||||
| } | ||||
|  | ||||
| @ -1,7 +1,7 @@ | ||||
| <!-- | ||||
|  * @Author: your name | ||||
|  * @Date: 2021-12-03 11:10:14 | ||||
|  * @LastEditTime : 2022-03-24 17:32:49 | ||||
|  * @LastEditTime : 2022-03-28 11:15:15 | ||||
|  * @LastEditors  : Shiming | ||||
|  * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE | ||||
|  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\waybill-management\\components\\vehicle\\vehicle.component.html | ||||
| @ -31,7 +31,7 @@ | ||||
|       </div> | ||||
|       <div nz-col [nzSpan]="_$expand ? 24 : 6" [class.expend-options]="_$expand" class="text-right"> | ||||
|         <button nz-button nzType="primary" [nzLoading]="false" (click)="search()"  acl  [acl-ability]="['WAYBILL-VEHICLE-search']">查询</button> | ||||
|         <button nz-button nzType="primary" [disabled]="false"  acl  [acl-ability]="['WAYBILL-VEHICLE-export']">导出</button> | ||||
|         <button nz-button nzType="primary" [disabled]="false"  acl  [acl-ability]="['WAYBILL-VEHICLE-export']" (click)="exprot()">导出</button> | ||||
|         <button nz-button [disabled]="false" (click)="resetSF()">重置</button> | ||||
|         <button nz-button nzType="link" (click)="expandToggle()"> | ||||
|           {{ !_$expand ? '展开' : '收起' }} | ||||
|  | ||||
| @ -35,10 +35,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|     compolatelQuantity: 0, | ||||
|     deltQuantity: 0 | ||||
|   }; | ||||
|   constructor( | ||||
|     public service: WaybillManagementServe, | ||||
|     private modal: NzModalService, | ||||
|     public shipperservice: ShipperBaseService) { } | ||||
|   constructor(public service: WaybillManagementServe, private modal: NzModalService, public shipperservice: ShipperBaseService) {} | ||||
|  | ||||
|   /** | ||||
|    * 查询参数 | ||||
| @ -55,8 +52,8 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|       ...params, | ||||
|       createTime: { | ||||
|         start: this.sf?.value?.createTime?.[0] || '', | ||||
|         end: this.sf?.value?.createTime?.[1] || '', | ||||
|       }, | ||||
|         end: this.sf?.value?.createTime?.[1] || '' | ||||
|       } | ||||
|     }; | ||||
|   } | ||||
|   get selectedRows() { | ||||
| @ -103,11 +100,11 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|             searchLoadingText: '搜索中...', | ||||
|             allowClear: true, | ||||
|             onSearch: (q: any) => { | ||||
|               let str =q.replace(/^\s+|\s+$/g,""); | ||||
|               let str = q.replace(/^\s+|\s+$/g, ''); | ||||
|               if (str) { | ||||
|                 return this.service | ||||
|                   .request(this.service.$api_enterpriceList, { enterpriseName: str}) | ||||
|                   .pipe(map((res: any) => (res as any[]).map((i) => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum)))) | ||||
|                   .request(this.service.$api_enterpriceList, { enterpriseName: str }) | ||||
|                   .pipe(map((res: any) => (res as any[]).map(i => ({ label: i.enterpriseName, value: i.id } as SFSchemaEnum)))) | ||||
|                   .toPromise(); | ||||
|               } else { | ||||
|                 return of([]); | ||||
| @ -116,7 +113,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|             change: (q: any) => { | ||||
|               this.getRegionCode(q); | ||||
|             } | ||||
|           } as SFSelectWidgetSchema, | ||||
|           } as SFSelectWidgetSchema | ||||
|         }, | ||||
|         enterpriseProjectId: { | ||||
|           type: 'string', | ||||
| @ -126,7 +123,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|             placeholder: '请先选择货主', | ||||
|             visibleIf: { | ||||
|               _$expand: (value: boolean) => value | ||||
|             }, | ||||
|             } | ||||
|           } as SFSelectWidgetSchema | ||||
|         }, | ||||
|         loadingPlace: { | ||||
| @ -171,8 +168,8 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|           type: 'string', | ||||
|           ui: { | ||||
|             visibleIf: { | ||||
|               _$expand: (value: boolean) => value, | ||||
|             }, | ||||
|               _$expand: (value: boolean) => value | ||||
|             } | ||||
|           } | ||||
|         }, | ||||
|         paymentstatus: { | ||||
| @ -242,7 +239,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|               _$expand: (value: boolean) => value | ||||
|             } | ||||
|           } as SFDateWidgetSchema | ||||
|         }, | ||||
|         } | ||||
|       }, | ||||
|       type: 'object' | ||||
|     }; | ||||
| @ -328,7 +325,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|         title: '收款人', | ||||
|         className: 'text-left', | ||||
|         width: '200px', | ||||
|         render: 'payeeName', | ||||
|         render: 'payeeName' | ||||
|       }, | ||||
|       { | ||||
|         title: '装卸货时间', | ||||
| @ -352,13 +349,13 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|             text: '确认发车', | ||||
|             click: _record => this.sureDepart(_record), | ||||
|             iif: item => item.wayBillStatus == '2', | ||||
|             acl: { ability: ['WAYBILL-VEHICLE-wholeStartCarInfo'] }, | ||||
|             acl: { ability: ['WAYBILL-VEHICLE-wholeStartCarInfo'] } | ||||
|           }, | ||||
|           { | ||||
|             text: '确认到车', | ||||
|             click: _record => this.sureArrive(_record), | ||||
|             iif: item => item.wayBillStatus == '3', | ||||
|             acl: { ability: ['WAYBILL-VEHICLE-wholeUnloadCarInfo'] }, | ||||
|             acl: { ability: ['WAYBILL-VEHICLE-wholeUnloadCarInfo'] } | ||||
|           } | ||||
|         ] | ||||
|       } | ||||
| @ -389,7 +386,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|   } | ||||
|   search() { | ||||
|     this.st?.load(1); | ||||
|     this.getGoodsSourceStatistical() | ||||
|     this.getGoodsSourceStatistical(); | ||||
|   } | ||||
|   selectChange(e: number) { | ||||
|     console.log(e); | ||||
| @ -402,7 +399,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|   /** | ||||
|    * 导入货源 | ||||
|    */ | ||||
|   importGoodsSource() { } | ||||
|   importGoodsSource() {} | ||||
|   /** | ||||
|    *查看评价 | ||||
|    */ | ||||
| @ -421,7 +418,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|       deltQuantity: 0 | ||||
|     }; | ||||
|     const params: any = Object.assign({}, this.reqParams || {}); | ||||
|     delete params.wayBillStatus | ||||
|     delete params.wayBillStatus; | ||||
|     this.service.request(this.service.$api_get_getWholeStatistics, params).subscribe(res => { | ||||
|       if (res) { | ||||
|         let totalCount = 0; | ||||
| @ -446,9 +443,9 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|               this.tabs.deltQuantity = ele?.count; | ||||
|               break; | ||||
|           } | ||||
|           totalCount += ele.count | ||||
|           totalCount += ele.count; | ||||
|         }); | ||||
|         this.tabs.totalQuantity = totalCount | ||||
|         this.tabs.totalQuantity = totalCount; | ||||
|       } | ||||
|     }); | ||||
|   } | ||||
| @ -467,7 +464,7 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|     }); | ||||
|     modalRef.afterClose.subscribe((result: any) => { | ||||
|       this.st.load(1); | ||||
|       this.getGoodsSourceStatistical() | ||||
|       this.getGoodsSourceStatistical(); | ||||
|     }); | ||||
|   } | ||||
|   // 确认到车 | ||||
| @ -484,7 +481,15 @@ export class WaybillManagementVehicleComponent implements OnInit { | ||||
|     }); | ||||
|     modalRef.afterClose.subscribe((result: any) => { | ||||
|       this.st.load(1); | ||||
|       this.getGoodsSourceStatistical() | ||||
|       this.getGoodsSourceStatistical(); | ||||
|     }); | ||||
|   } | ||||
|   // 导出 | ||||
|   exprot() { | ||||
|     this.service.request(this.service.$api_asyncExportWholeList, this.reqParams).subscribe((res: any) => { | ||||
|       if (res) { | ||||
|         this.service.msgSrv.success('导出成功,请去下载中心下载!'); | ||||
|       } | ||||
|     }); | ||||
|   } | ||||
| } | ||||
|  | ||||
| @ -2,7 +2,7 @@ import { WaybillManagementBulkComponent } from './../components/bulk/bulk.compon | ||||
| /* | ||||
|  * @Author: your name | ||||
|  * @Date: 2021-12-07 14:52:29 | ||||
|  * @LastEditTime : 2022-03-24 15:17:57 | ||||
|  * @LastEditTime : 2022-03-28 11:13:50 | ||||
|  * @LastEditors  : Shiming | ||||
|  * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE | ||||
|  * @FilePath     : \\tms-obc-web\\src\\app\\routes\\waybill-management\\services\\waybill-management.service.ts | ||||
| @ -61,6 +61,11 @@ export class WaybillManagementServe extends BaseService { | ||||
|  $api_get_getAppDriverPosition = `/api/sdc/wayBillOperate/getAppDriverPosition`; | ||||
|   // 获取货主企业列表 | ||||
|   public $api_enterpriceList = '/api/mdc/cuc/enterpriseInfo/operate/enterpriceList'; | ||||
|  | ||||
|   // 异步导出运营后台大宗运单列表 | ||||
|   public $api_asyncExportBulkList = '/api/sdc/wayBillOperate/asyncExportBulkList'; | ||||
|   // 异步导出运营后台整车运单列表 | ||||
|   public $api_asyncExportWholeList = '/api/sdc/wayBillOperate/asyncExportWholeList'; | ||||
|   constructor(public injector: Injector) { | ||||
|     super(injector); | ||||
|   } | ||||
|  | ||||
		Reference in New Issue
	
	Block a user