|
@@ -447,6 +447,42 @@ public class WxPayController {
|
|
|
}
|
|
|
/**
|
|
|
* 添加分账接收方
|
|
|
+ * http://127.0.0.1:8082/charging-parking/wxPay/profitSharingAddReceiverCompany?merchantId=1&type=MERCHANT_ID&account=1642663845
|
|
|
+ * 荆鹏开发加鹏育
|
|
|
+ */
|
|
|
+// @PostMapping(value = "/profitSharingAddReceiverCompany")
|
|
|
+// public String profitSharingAddReceiverCompany(String merchantId,String type,String account) {
|
|
|
+// try {
|
|
|
+//
|
|
|
+// ParkingMerchant parkingMerchant = parkingMerchantService.getById(merchantId);
|
|
|
+// ReceiverModel receiver = ReceiverModel.builder()
|
|
|
+// .type(type)
|
|
|
+// .account(account).name("湖北鹏育优电新能源科技有限公司")
|
|
|
+// .relation_type("SUPPLIER")
|
|
|
+// .build();
|
|
|
+//
|
|
|
+// Map<String, String> params = ProfitSharingModel.builder()
|
|
|
+// .mch_id(wxPayProperties.getMchId())
|
|
|
+// .sub_mch_id(parkingMerchant.getSubMchId())
|
|
|
+// .appid(wxPayProperties.getAppId())
|
|
|
+// .sub_appid(wxPayProperties.getSubAppId())
|
|
|
+// .nonce_str(WxPayKit.generateStr())
|
|
|
+// .receiver(JSONObject.toJSONString(receiver))
|
|
|
+// .build()
|
|
|
+// .createSign(wxPayProperties.getMchKey(), SignType.HMACSHA256);
|
|
|
+// log.info("请求参数:{}", WxPayKit.toXml(params));
|
|
|
+// String result = WxPayApi.profitSharingAddReceiver(params);
|
|
|
+// log.info("请求结果:{}", result);
|
|
|
+// return JSONObject.toJSONString(WxPayKit.xmlToMap(result));
|
|
|
+// } catch (Exception e) {
|
|
|
+// e.printStackTrace();
|
|
|
+// }
|
|
|
+// return null;
|
|
|
+// }
|
|
|
+ /**
|
|
|
+ * 添加分账接收方
|
|
|
+ * http://127.0.0.1:8082/charging-parking/wxPay/profitSharingAddReceiverCompany?merchantId=74155261-5a96-4659-87b7-ed23e318fda0&type=MERCHANT_ID&account=1621835993
|
|
|
+ * 汇居物业加荆鹏开发
|
|
|
*/
|
|
|
@PostMapping(value = "/profitSharingAddReceiverCompany")
|
|
|
public String profitSharingAddReceiverCompany(String merchantId,String type,String account) {
|
|
@@ -455,7 +491,7 @@ public class WxPayController {
|
|
|
ParkingMerchant parkingMerchant = parkingMerchantService.getById(merchantId);
|
|
|
ReceiverModel receiver = ReceiverModel.builder()
|
|
|
.type(type)
|
|
|
- .account(account).name("湖北鹏育优电新能源科技有限公司")
|
|
|
+ .account(account).name("湖北荆鹏软件开发有限公司")
|
|
|
.relation_type("SUPPLIER")
|
|
|
.build();
|
|
|
|