feat(trade): connect WeChat refund API and callback flow
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import { loadAppConfig } from '@dukang/shared-types';
|
||||
import type { IPayProvider, PayMethod, PayOrderResult } from './pay.interface';
|
||||
import type { IPayProvider, PayMethod, PayOrderResult, RefundOrderResult } from './pay.interface';
|
||||
import { PayMockProvider } from './pay.mock.provider';
|
||||
import { PayWechatProvider } from './pay.wechat.provider';
|
||||
|
||||
@@ -24,4 +24,12 @@ export class PayRouterProvider implements IPayProvider {
|
||||
): Promise<PayOrderResult> {
|
||||
return this.resolve().payOrder(orderId, openId, platform, payMethod);
|
||||
}
|
||||
|
||||
refundOrder(
|
||||
orderId: bigint,
|
||||
outRefundNo: string,
|
||||
reason?: string,
|
||||
): Promise<RefundOrderResult> {
|
||||
return this.resolve().refundOrder(orderId, outRefundNo, reason);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user