From 8626dcaabf011323410a45719c02e37c6914cc16 Mon Sep 17 00:00:00 2001 From: wangshiming Date: Fri, 22 Apr 2022 17:16:01 +0800 Subject: [PATCH] fix bug --- .../receipts-audit.component.ts | 3 +- .../voucher-view/voucher-view.component.ts | 29 ++----------------- .../services/order-management.service.ts | 8 +++-- 3 files changed, 8 insertions(+), 32 deletions(-) diff --git a/src/app/routes/order-management/components/receipts-audit/receipts-audit.component.ts b/src/app/routes/order-management/components/receipts-audit/receipts-audit.component.ts index c3ddd93f..d8c217a8 100644 --- a/src/app/routes/order-management/components/receipts-audit/receipts-audit.component.ts +++ b/src/app/routes/order-management/components/receipts-audit/receipts-audit.component.ts @@ -547,8 +547,7 @@ export class OrderManagementReceiptsAuditComponent implements OnInit { nzContent: `确认后单据不可修改,请谨慎操作。`, nzOnOk: () => { - this.service.downloadFile(this.service.$api_createBillTakeGoods,params) - this.service.downloadFile(this.service.$api_createBillDischargeGoods,params) + this.service.downloadFile(this.service.$api_createBillEsignGoods,params) this.service.msgSrv.success('生成成功!'); this.st?.reload() // this.getGoodsSourceStatistical(); diff --git a/src/app/routes/order-management/modal/audit/voucher-view/voucher-view.component.ts b/src/app/routes/order-management/modal/audit/voucher-view/voucher-view.component.ts index 80ec4a45..cb1704bb 100644 --- a/src/app/routes/order-management/modal/audit/voucher-view/voucher-view.component.ts +++ b/src/app/routes/order-management/modal/audit/voucher-view/voucher-view.component.ts @@ -523,38 +523,13 @@ export class orderManagementVoucherViewComponent implements OnInit { 请等待${time}秒后自动关闭 ` }); - this.service.request(this.service.$api_createBillTakeGoods, [this.datas?.id]).subscribe(res => { + this.service.request(this.service.$api_createBillEsignGoods, [this.datas?.id]).subscribe(res => { if (res) { switch (res[0]?.esignFlowStatus) { case 1: case '1': setTimeout(() => { - this.service.request(this.service.$api_getBillTakeEsignFile, [this.datas?.id]).subscribe(res => { - if (res[0]?.esignFlowStatus == '2') { - } - }); - }, 9000); - return; - case 2: - return; - case '13': - default: - this.service.msgSrv.error('电子装货单签署异常!'); - modal.destroy(); - return; - } - } else { - this.service.msgSrv.error('电子装货单签署异常!'); - modal.destroy(); - } - }); - this.service.request(this.service.$api_createBillDischargeGoods, [this.datas?.id]).subscribe(res => { - if (res) { - switch (res[0]?.esignFlowStatus) { - case 1: - case '1': - setTimeout(() => { - this.service.request(this.service.$api_getBillDischargeEsignFile, [this.datas?.id]).subscribe(res => { + this.service.request(this.service.$api_getBillGoodsEsignFile, [this.datas?.id]).subscribe(res => { if (res[0]?.esignFlowStatus == '2') { this.service.msgSrv.success('生成电子单据成功!'); this.modal.destroy(true); diff --git a/src/app/routes/order-management/services/order-management.service.ts b/src/app/routes/order-management/services/order-management.service.ts index 3df90939..087d7a70 100644 --- a/src/app/routes/order-management/services/order-management.service.ts +++ b/src/app/routes/order-management/services/order-management.service.ts @@ -4,7 +4,7 @@ * @Author : Shiming * @Date : 2021-12-03 15:31:52 * @LastEditors : Shiming - * @LastEditTime : 2022-04-22 10:54:29 + * @LastEditTime : 2022-04-22 17:14:39 * @FilePath : \\tms-obc-web\\src\\app\\routes\\order-management\\services\\order-management.service.ts * Copyright (C) 2022 huzhenhong. All rights reserved. */ @@ -163,8 +163,8 @@ export class OrderManagementService extends ShipperBaseService { // 异常预警 public $api_getAbnormalWarningByBillId = '/api/sdc/abnormalWarning/getAbnormalWarningByBillId'; - // 生成卸货单 - public $api_createBillDischargeGoods = '/api/sdc/billOperate/createBillDischargeGoods'; + // 获取电子提/卸货单签章附件 + public $api_getBillGoodsEsignFile = '/api/sdc/billOperate/getBillGoodsEsignFile'; // 生成提货单 public $api_createBillTakeGoods = '/api/sdc/billOperate/createBillTakeGoods'; // 生成卸货单-页面展示 @@ -217,6 +217,8 @@ export class OrderManagementService extends ShipperBaseService { public $api_getBillDischargeGoods = `/api/sdc/billOperate/getBillDischargeGoods`; // 预览提货单 public $api_getBillTakeGoods = `/api/sdc/billOperate/getBillTakeGoods`; + // 生成提/卸货单 + public $api_createBillEsignGoods = `/api/sdc/billOperate/createBillEsignGoods`; // // 生成卸货单 // public $api_createBillDischargeGoods = `/api/sdc/billOperate/createBillDischargeGoods`;