分销员开通回调修改
This commit is contained in:
parent
55360f22ef
commit
82d675a2c5
|
|
@ -57,8 +57,8 @@ public class NotifyController {
|
|||
|
||||
@GetMapping("testOpen")
|
||||
public JSONObject test1(String code) throws Exception {
|
||||
JSONObject jsonObject = wxService.transferBalance("or1l86yipGvwyfPhrKIAcQuSfAV8", "叶明飞", new BigDecimal("0.01"), "转账测试", "testTranymf0001");
|
||||
return jsonObject;
|
||||
distributionUserService.distribute(54659L, "WX1983728389726539776", BigDecimal.valueOf(1), 474L, 122L, "order");
|
||||
return null;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -103,11 +103,11 @@ public interface MkDistributionUserService extends IService<MkDistributionUser>
|
|||
/**
|
||||
* 分销员开通
|
||||
*
|
||||
* @param userId 用户
|
||||
* @param shopUserId 用户
|
||||
* @param amount 金额
|
||||
* @param shopId 店铺id
|
||||
*/
|
||||
void open(Long userId, BigDecimal amount, Long shopId, Long sourceId);
|
||||
void open(Long shopUserId, BigDecimal amount, Long shopId, Long sourceId);
|
||||
|
||||
/**
|
||||
* 分销商户运营余额充值回调
|
||||
|
|
|
|||
|
|
@ -533,8 +533,8 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
|
|||
}
|
||||
|
||||
@Override
|
||||
public void open(Long userId, BigDecimal amount, Long shopId, Long sourceId) {
|
||||
ShopUser shopUserInfo = shopUserService.getShopUserInfo(shopId, userId);
|
||||
public void open(Long shopUserId, BigDecimal amount, Long shopId, Long sourceId) {
|
||||
ShopUser shopUserInfo = shopUserService.getById(shopUserId);
|
||||
Long mainShopId = shopInfoService.getMainIdByShopId(shopId);
|
||||
BigDecimal finalAmount = shopInfoService.updateAmount(shopId, amount);
|
||||
distributionAmountFlowService.save(new MkDistributionAmountFlow()
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
left join mk_distribution_user as d on d.id=a.distribution_user_id
|
||||
left join tb_shop_info as e on e.id=a.shop_id
|
||||
left join tb_shop_user as b on a.shop_user_id=b.id
|
||||
left join tb_shop_user as c on c.id=a.shop_user_id
|
||||
left join tb_shop_user as c on c.id=a.source_shop_user_id
|
||||
<where>
|
||||
<if test="shopId != null">
|
||||
and a.shop_id=#{shopId}
|
||||
|
|
|
|||
Loading…
Reference in New Issue