From 2f4b216e881e1a819ce3c108fdb013575f01731e Mon Sep 17 00:00:00 2001 From: hu177768073 <177768073@qq.com> Date: Fri, 20 Sep 2024 10:47:48 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=80=80=E6=AC=BE=E8=AE=B0?= =?UTF-8?q?=E5=BD=95=E5=AF=BC=E5=87=BA=E3=80=81=E5=94=AE=E5=90=8E=E5=AF=BC?= =?UTF-8?q?=E5=87=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../order-after-sales.component.html | 1 + .../order-after-sales.component.ts | 17 +++++++++++++++++ .../order-refund/order-refund.component.html | 1 + .../order-refund/order-refund.component.ts | 17 +++++++++++++++++ .../services/trade/order-after-sales.service.ts | 14 ++++++++++++++ src/app/services/trade/order-refund.service.ts | 12 ++++++++++++ 6 files changed, 62 insertions(+) diff --git a/src/app/pages/trade/order-after-sales/order-after-sales.component.html b/src/app/pages/trade/order-after-sales/order-after-sales.component.html index 2cde752..10328f3 100644 --- a/src/app/pages/trade/order-after-sales/order-after-sales.component.html +++ b/src/app/pages/trade/order-after-sales/order-after-sales.component.html @@ -84,6 +84,7 @@
+ 更多查询条件 diff --git a/src/app/pages/trade/order-after-sales/order-after-sales.component.ts b/src/app/pages/trade/order-after-sales/order-after-sales.component.ts index 79cdb45..4331ba0 100644 --- a/src/app/pages/trade/order-after-sales/order-after-sales.component.ts +++ b/src/app/pages/trade/order-after-sales/order-after-sales.component.ts @@ -36,6 +36,7 @@ import {NzTypographyComponent} from "ng-zorro-antd/typography"; import {environment} from "../../../../environments/environment"; import {NzSpinComponent} from "ng-zorro-antd/spin"; import {NzAlertComponent} from "ng-zorro-antd/alert"; +import {CommunicationService} from "../../../services/common/communication.service"; @Component({ selector: 'app-order-after-sales', @@ -132,6 +133,7 @@ export class OrderAfterSalesComponent { isCollapse = false; constructor(private fb: NonNullableFormBuilder, private orderAfterSalesService : OrderAfterSalesService, + private communicationService: CommunicationService, private message: NzMessageService, private modal: NzModalService) { // 初始化搜索框 @@ -313,4 +315,19 @@ export class OrderAfterSalesComponent { }); } + + /** + * 导出订单 + */ + export() { + this.orderAfterSalesService.export(this.searchForm.value, (data: any) => { + if (data['return_code'] == '000000') { + if (data['return_code'] == '000000') { + this.communicationService.sendMessage(data['return_data']); + } else { + this.message.error(data['return_msg']); + } + } + }); + } } diff --git a/src/app/pages/trade/order-refund/order-refund.component.html b/src/app/pages/trade/order-refund/order-refund.component.html index 52c1dfe..d3443f4 100644 --- a/src/app/pages/trade/order-refund/order-refund.component.html +++ b/src/app/pages/trade/order-refund/order-refund.component.html @@ -56,6 +56,7 @@
+
diff --git a/src/app/pages/trade/order-refund/order-refund.component.ts b/src/app/pages/trade/order-refund/order-refund.component.ts index 3abd2f3..9a4e0ea 100644 --- a/src/app/pages/trade/order-refund/order-refund.component.ts +++ b/src/app/pages/trade/order-refund/order-refund.component.ts @@ -34,6 +34,7 @@ import {NzTabComponent, NzTabSetComponent, NzTabsModule} from "ng-zorro-antd/tab import {NzTimelineModule} from "ng-zorro-antd/timeline"; import {NzImageDirective, NzImageModule} from "ng-zorro-antd/image"; import {NzTypographyComponent} from "ng-zorro-antd/typography"; +import {CommunicationService} from "../../../services/common/communication.service"; @Component({ selector: 'app-order-refund', @@ -118,6 +119,7 @@ export class OrderRefundComponent { }; constructor(private fb: NonNullableFormBuilder, private orderRefundService : OrderRefundService, + private communicationService: CommunicationService, private message: NzMessageService, private modal: NzModalService) { // 初始化搜索框 @@ -210,4 +212,19 @@ export class OrderRefundComponent { this.refundDetailVisible = false; } + /** + * 导出订单 + */ + export() { + this.orderRefundService.export(this.searchForm.value, (data: any) => { + if (data['return_code'] == '000000') { + if (data['return_code'] == '000000') { + this.communicationService.sendMessage(data['return_data']); + } else { + this.message.error(data['return_msg']); + } + } + }); + } + } diff --git a/src/app/services/trade/order-after-sales.service.ts b/src/app/services/trade/order-after-sales.service.ts index 60191aa..ec9355b 100644 --- a/src/app/services/trade/order-after-sales.service.ts +++ b/src/app/services/trade/order-after-sales.service.ts @@ -22,6 +22,19 @@ export class OrderAfterSalesService { }); } + + /** + * 导出 + * @param param + * @param callBack + */ + public export(param: any, callBack:any) { + param.time = new Date().getTime(); + this.http.get(environment.orderUrl + 'afterSales/export?'+ObjectData.objectByString(param)).subscribe(data => { + callBack(data); + }); + } + /** * 查询订单详情 * @param applyNo @@ -61,4 +74,5 @@ export class OrderAfterSalesService { }); } + } diff --git a/src/app/services/trade/order-refund.service.ts b/src/app/services/trade/order-refund.service.ts index dfbff44..82794af 100644 --- a/src/app/services/trade/order-refund.service.ts +++ b/src/app/services/trade/order-refund.service.ts @@ -22,6 +22,18 @@ export class OrderRefundService { }); } + /** + * 查询退款订单列表 + * @param param + * @param callBack + */ + public export(param: any, callBack:any) { + param.time = new Date().getTime(); + this.http.get(environment.orderUrl + 'refund/export?'+ObjectData.objectByString(param)).subscribe(data => { + callBack(data); + }); + } + /** * 查询退款订单 * @param param