From 3870728572b1aca27bf20031ccb2ab4b976959cb Mon Sep 17 00:00:00 2001 From: Taric Xin Date: Thu, 24 Mar 2022 16:14:03 +0800 Subject: [PATCH] edit --- .../cancellation-invoice.component.html | 29 +++++++--- .../cancellation-invoice.component.ts | 58 ++++++++++--------- .../requested-invoice-modal.component.html | 2 +- .../services/ticket.service.ts | 2 + 4 files changed, 57 insertions(+), 34 deletions(-) diff --git a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html index 42bc22e2..c2b8daca 100644 --- a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html +++ b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.html @@ -57,13 +57,28 @@
- + +

公司名: {{openInfo?.artoname}}

+

税号: {{openInfo?.artotaxno}}

+

注册地址: {{openInfo?.artoadd}}

+

注册电话: {{openInfo?.artotel}}

+

开户行: {{openInfo?.artobank}}

+
+ + {{openInfo?.vatname}} + + + {{openInfo?.vatremarks}} + + + {{openInfo?.otherremarks}} + + + {{openInfo?.isdetail?'需要':'不需要'}} + + + {{openInfo?.vatnotax | currency}} + diff --git a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts index b394a349..e2e9009e 100644 --- a/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts +++ b/src/app/routes/ticket-management/components/cancellation-invoice/cancellation-invoice.component.ts @@ -79,34 +79,40 @@ export class CancellationInvoiceComponent implements OnInit { */ requestedAction(item: any) { this.openInfo = { invoicedate: null, invoiceno: null, invoiceno2: null }; - const modal = this.nzModalService.create({ - nzTitle: '发票确认', - nzContent: this.requestedModal, - nzOnOk: () => { - if (!this.openInfo?.invoicedate || !this.openInfo?.invoiceno) { - this.service.msgSrv.warning('请填开票信息'); - return false; - } - const params = { - invoiceno: this.openInfo.invoiceno, - invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate), - invoiceno2: this.openInfo.invoiceno2 - }; - this.service - .request(this.service.$api_apply_fico_invoic, { - id: item.id, - vatinvcode: item.vatinvcode, - ...params - }) - .subscribe(res => { - if (res) { - this.service.msgSrv.success('开票成功'); - this.st.load(1); - modal.destroy(); + this.service.request(this.service.$api_get_apply_fico_info, { id: item.vatappHId }).subscribe(info => { + if (info) { + console.log(info); + Object.assign(this.openInfo, { ...info }); + const modal = this.nzModalService.create({ + nzTitle: '发票确认', + nzContent: this.requestedModal, + nzOnOk: () => { + if (!this.openInfo?.invoicedate || !this.openInfo?.invoiceno) { + this.service.msgSrv.warning('请填开票信息'); + return false; } - }); + const params = { + invoiceno: this.openInfo.invoiceno, + invoicedate: dateTimePickerUtil.format(this.openInfo.invoicedate), + invoiceno2: this.openInfo.invoiceno2 + }; + this.service + .request(this.service.$api_apply_fico_invoic, { + id: item.id, + vatinvcode: item.vatinvcode, + ...params + }) + .subscribe(res => { + if (res) { + this.service.msgSrv.success('开票成功'); + this.st.load(1); + modal.destroy(); + } + }); - return false; + return false; + } + }); } }); } diff --git a/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.html b/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.html index acde105a..9fa49838 100644 --- a/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.html +++ b/src/app/routes/ticket-management/components/invoice-requested/requested-invoice-modal/requested-invoice-modal.component.html @@ -32,5 +32,5 @@ diff --git a/src/app/routes/ticket-management/services/ticket.service.ts b/src/app/routes/ticket-management/services/ticket.service.ts index d2d66aa4..68508f5a 100644 --- a/src/app/routes/ticket-management/services/ticket.service.ts +++ b/src/app/routes/ticket-management/services/ticket.service.ts @@ -32,6 +32,8 @@ export class TicketService extends ShipperBaseService { $api_ficoVatinv_Detail = '/api/fcc/ficoVatinvL/getDetailByVatinvHId'; // 运营端订单明细开票处理 $api_apply_fico = '/api/fcc/ficoVatinvH/crmPushInvo'; + // 手工开票获取开票申请信息展示 + $api_get_apply_fico_info = '/api/fcc/ficoVatappH/get'; // 运营端手工开票/确认/E税云开票成功后的回调 $api_apply_fico_invoic = '/api/fcc/ficoVatinvH/operateAffirmVatinv'; // 运营端推送开票-E税云开票