分销充值修改
This commit is contained in:
parent
9a99cc6e1d
commit
993b65caae
|
|
@ -97,7 +97,7 @@ public class NotifyController {
|
|||
payment.setPayTime(DateUtil.date().toLocalDateTime());
|
||||
payment.setRespJson(plainTextJson.toJSONString());
|
||||
paymentService.updateById(payment);
|
||||
distributionUserService.rechargeCallBack(payment.getSourceId(), payment.getShopId(), payment.getAmount(), payment.getId());
|
||||
distributionUserService.rechargeCallBack(payment.getShopId(), payment.getAmount(), payment.getId());
|
||||
}catch (Exception e) {
|
||||
log.error("充值回调失败", e);
|
||||
return "SUCCESS";
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ public interface MkDistributionUserService extends IService<MkDistributionUser>
|
|||
/**
|
||||
* 分销商户运营余额充值回调
|
||||
*/
|
||||
void rechargeCallBack(Long userId, Long shopId, BigDecimal amount, Long paymentId);
|
||||
void rechargeCallBack(Long shopId, BigDecimal amount, Long paymentId);
|
||||
|
||||
/**
|
||||
* 发放分销奖励
|
||||
|
|
|
|||
|
|
@ -453,7 +453,7 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
|
|||
|
||||
|
||||
@Override
|
||||
public void rechargeCallBack(Long userId, Long shopId, BigDecimal amount, Long paymentId) {
|
||||
public void rechargeCallBack(Long shopId, BigDecimal amount, Long paymentId) {
|
||||
Long mainShopId = shopInfoService.getMainIdByShopId(shopId);
|
||||
BigDecimal finalAmount = shopInfoService.updateAmount(shopId, amount);
|
||||
distributionAmountFlowService.save(new MkDistributionAmountFlow()
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ public class DistributionPayServiceImpl implements DistributionPayService {
|
|||
|
||||
@Override
|
||||
public Map<String, String> mchRecharge(String clientIP, MkDistributionPayDTO payParam) {
|
||||
InitInfo initInfo = initPayment(payParam.getUserId(), payParam, true);
|
||||
InitInfo initInfo = initPayment(payParam.getUserId() == null ? payParam.getShopId() : payParam.getUserId(), payParam, true);
|
||||
return wxService.v3Pay(initInfo.openId, payParam.getAmount(), "商户运营余额充值", initInfo.payment.getOrderNo(), initInfo.payment.getPayType());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue