From f5da8524d93f618e9d40d1fa52a78539e44690db Mon Sep 17 00:00:00 2001 From: Fang Date: Sat, 11 Jun 2022 22:39:24 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=95=86=E5=AE=B6=E5=88=B8=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E6=9F=A5=E8=AF=A2=E8=90=A5=E9=94=80=E8=A1=A5=E5=B7=AE?= =?UTF-8?q?=E4=BB=98=E6=AC=BE=E5=8D=95=E8=AF=A6=E6=83=85API?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../wechat/enumeration/WechatPayV3Type.java | 6 +++++ .../v3/WechatMarketingBusiFavorApi.java | 24 +++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/enumeration/WechatPayV3Type.java b/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/enumeration/WechatPayV3Type.java index 9ff15a4..03bab5d 100644 --- a/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/enumeration/WechatPayV3Type.java +++ b/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/enumeration/WechatPayV3Type.java @@ -450,6 +450,12 @@ public enum WechatPayV3Type { * @since 1.0.13.RELEASES */ MARKETING_BUSI_FAVOR_SUBSIDY(HttpMethod.POST, "%s/v3/marketing/busifavor/subsidy/pay-receipts"), + /** + * 查询营销补差付款单详情API. + * + * @since 1.0.13.RELEASES + */ + MARKETING_BUSI_FAVOR_SUBSIDY_QUERY(HttpMethod.POST, "%s/v3/marketing/busifavor/subsidy/pay-receipts/{subsidy_receipt_id}"), //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /** * 发起批量转账API. diff --git a/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/v3/WechatMarketingBusiFavorApi.java b/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/v3/WechatMarketingBusiFavorApi.java index b7954c7..7a7fe0a 100644 --- a/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/v3/WechatMarketingBusiFavorApi.java +++ b/payment-spring-boot-autoconfigure/src/main/java/cn/felord/payment/wechat/v3/WechatMarketingBusiFavorApi.java @@ -459,5 +459,29 @@ public class WechatMarketingBusiFavorApi extends AbstractApi { .request(); return wechatResponseEntity; } + /** + * 查询营销补差付款单详情API + *

+ * 查询商家券营销补差付款单详情 + * + * @param subsidyReceiptId the subsidyReceiptId + * @return the wechat response entity + * @since 1.0.13.RELEASE + */ + public WechatResponseEntity queryMakeup(String subsidyReceiptId){ + WechatResponseEntity wechatResponseEntity = new WechatResponseEntity<>(); + this.client().withType(WechatPayV3Type.MARKETING_BUSI_FAVOR_SUBSIDY_QUERY, subsidyReceiptId) + .function((type, receiptId) -> { + URI uri = UriComponentsBuilder.fromHttpUrl(type.uri(WeChatServer.CHINA)) + .build() + .expand(receiptId) + .toUri(); + return Get(uri); + }) + .consumer(wechatResponseEntity::convert) + .request(); + return wechatResponseEntity; + } + }