Ver a proveniência

fix bug

release_toaliyun_real
winter há 4 anos
ascendente
cometimento
ae768be164
3 ficheiros alterados com 34 adições e 3 eliminações
  1. +2
    -2
      mallinkSchedule/src/main/java/com/iformall/schedule/CouponOrderExpiringSchedule.java
  2. +12
    -0
      mallinkService/src/main/java/com/iformall/pay/WxProfitSharing.java
  3. +20
    -1
      mallinkService/src/main/java/com/iformall/service/pay/service/share/wx/WxPayShareService.java

+ 2
- 2
mallinkSchedule/src/main/java/com/iformall/schedule/CouponOrderExpiringSchedule.java Ver ficheiro

@@ -86,8 +86,8 @@ public class CouponOrderExpiringSchedule {


} }


@Scheduled(cron = "0 0/5 * * * ?") // 每天凌晨00:05
//@Scheduled(cron = "0 0 5 * * ?") // 每天凌晨00:05
//@Scheduled(cron = "0 0/5 * * * ?") // 每天凌晨00:05
@Scheduled(cron = "0 0 5 * * ?") // 每天凌晨00:05
// @Scheduled(cron = "*/10 * * * * ?") // 测试10秒中一次 // @Scheduled(cron = "*/10 * * * * ?") // 测试10秒中一次
public void couponOrderRefundSchedule() { public void couponOrderRefundSchedule() {
CouponOrderExpiringSchedule proxy = (CouponOrderExpiringSchedule) AopContext.currentProxy(); CouponOrderExpiringSchedule proxy = (CouponOrderExpiringSchedule) AopContext.currentProxy();


+ 12
- 0
mallinkService/src/main/java/com/iformall/pay/WxProfitSharing.java Ver ficheiro

@@ -21,6 +21,8 @@ public class WxProfitSharing {
private static final String RPOFIT_SHARING_ADD_RECEIVER_URL = "https://api.mch.weixin.qq.com/pay/profitsharingaddreceiver"; private static final String RPOFIT_SHARING_ADD_RECEIVER_URL = "https://api.mch.weixin.qq.com/pay/profitsharingaddreceiver";
// 删除分账账户 // 删除分账账户
private static final String RPOFIT_SHARING_REMOVE_RECEIVER_URL = "https://api.mch.weixin.qq.com/pay/profitsharingremovereceiver"; private static final String RPOFIT_SHARING_REMOVE_RECEIVER_URL = "https://api.mch.weixin.qq.com/pay/profitsharingremovereceiver";
//查询订单待分账金额
private static final String RPOFIT_SHARING_ORDER_SHAREMENT_URL = "https://api.mch.weixin.qq.com/pay/profitsharingorderamountquery";




private WxProfitSharing() { private WxProfitSharing() {
@@ -69,6 +71,16 @@ public class WxProfitSharing {
* @return * @return
*/ */
public static String addReceiver(Map<String, String> params) {return doPost(RPOFIT_SHARING_ADD_RECEIVER_URL, params); } public static String addReceiver(Map<String, String> params) {return doPost(RPOFIT_SHARING_ADD_RECEIVER_URL, params); }
/**
* 查询订单待分账金额
* @param params
* @return
*/
public static String queryOrderShareAmount(Map<String, String> params) {
return doPost(RPOFIT_SHARING_ORDER_SHAREMENT_URL, params);
}


/** /**
* 分账接收方删除 * 分账接收方删除


+ 20
- 1
mallinkService/src/main/java/com/iformall/service/pay/service/share/wx/WxPayShareService.java Ver ficheiro

@@ -429,5 +429,24 @@ public class WxPayShareService extends PayShareBaseAdapterService{
return new ShareAccountResult(true, null, "success", returnMap); return new ShareAccountResult(true, null, "success", returnMap);
} }



private static String queryOrderShareAmount(String mchId,String transcationId,String apiKey) {
WxProfitSharingP psCmd = new WxProfitSharingP();
psCmd.setMch_id(mchId);//服务商商户id
psCmd.setNonce_str(Utility.generate32UUID());
psCmd.setTransaction_id(transcationId);
psCmd.setSign_type("HMAC-SHA256");
try {
psCmd.setSign(WxPayment.createSignHMAC(BeanUtils.toStringMap(psCmd), apiKey));
return WxProfitSharing.queryOrderShareAmount(BeanUtils.toStringMap(psCmd));
} catch (Exception e) {
e.printStackTrace();
}
return null;
}
public static void main(String[] args) {
System.out.println(queryOrderShareAmount("1511925291","4200001450202205126591001698","XHZfpVA0NzoXgLEjsujctUTcyj8Zur2C"));
}
} }

Carregando…
Cancelar
Guardar