上级 Id
This commit is contained in:
@@ -35,11 +35,6 @@ public class MkDistributionUserDTO extends TimeQueryParam implements Serializabl
|
|||||||
*/
|
*/
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|
||||||
/**
|
|
||||||
* 上级ID 关联本表id字段,无上级时为NULL
|
|
||||||
*/
|
|
||||||
private Long parentId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 店铺id
|
* 店铺id
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -37,11 +37,6 @@ public class MkDistributionUser implements Serializable {
|
|||||||
@Id
|
@Id
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|
||||||
/**
|
|
||||||
* 上级ID 关联本表id字段,无上级时为NULL
|
|
||||||
*/
|
|
||||||
private Long parentId;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 店铺id
|
* 店铺id
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -275,8 +275,8 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
|
|||||||
//更新自己的上级
|
//更新自己的上级
|
||||||
ShopUser newShopUser = new ShopUser();
|
ShopUser newShopUser = new ShopUser();
|
||||||
newShopUser.setId(shopUser.getId());
|
newShopUser.setId(shopUser.getId());
|
||||||
newShopUser.setDistributionUserId(parent.getId());
|
newShopUser.setDistributionUserId(parentShopUser.getId());
|
||||||
newShopUser.setDistributionUserParentId(parent.getParentId());
|
newShopUser.setDistributionUserParentId(parentShopUser.getDistributionUserId());
|
||||||
newShopUser.setInviteTime(LocalDateTime.now());
|
newShopUser.setInviteTime(LocalDateTime.now());
|
||||||
shopUserService.updateById(newShopUser);
|
shopUserService.updateById(newShopUser);
|
||||||
if (parentShopUser.getDistributionUserParentId() != null) {
|
if (parentShopUser.getDistributionUserParentId() != null) {
|
||||||
@@ -369,7 +369,6 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
|
|||||||
QueryWrapper queryWrapper = new QueryWrapper();
|
QueryWrapper queryWrapper = new QueryWrapper();
|
||||||
queryWrapper.eq(MkDistributionUser::getId, param.getId());
|
queryWrapper.eq(MkDistributionUser::getId, param.getId());
|
||||||
queryWrapper.eq(MkDistributionUser::getShopId, param.getShopId());
|
queryWrapper.eq(MkDistributionUser::getShopId, param.getShopId());
|
||||||
queryWrapper.eq(MkDistributionUser::getParentId, param.getParentId());
|
|
||||||
queryWrapper.eq(MkDistributionUser::getDistributionLevelId, param.getDistributionLevelId());
|
queryWrapper.eq(MkDistributionUser::getDistributionLevelId, param.getDistributionLevelId());
|
||||||
queryWrapper.ge(MkDistributionUser::getCreateTime, param.getStartTime());
|
queryWrapper.ge(MkDistributionUser::getCreateTime, param.getStartTime());
|
||||||
queryWrapper.le(MkDistributionUser::getCreateTime, param.getEndTime());
|
queryWrapper.le(MkDistributionUser::getCreateTime, param.getEndTime());
|
||||||
@@ -539,7 +538,7 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
|
|||||||
.setType(TableValueConstant.DistributionAmountFlow.Type.OPEN.getCode())
|
.setType(TableValueConstant.DistributionAmountFlow.Type.OPEN.getCode())
|
||||||
.setMainShopId(mainShopId).setShopId(shopId).setAmount(finalAmount).setChangeAmount(amount).setSourceId(sourceId)
|
.setMainShopId(mainShopId).setShopId(shopId).setAmount(finalAmount).setChangeAmount(amount).setSourceId(sourceId)
|
||||||
.setRemark("分销员购买"));
|
.setRemark("分销员购买"));
|
||||||
addDistributionUser(new MkDistributionUser().setParentId(null).setShopId(shopId)
|
addDistributionUser(new MkDistributionUser().setShopId(shopId)
|
||||||
.setUserId(shopUserInfo.getUserId())
|
.setUserId(shopUserInfo.getUserId())
|
||||||
.setId(shopUserInfo.getId()).setOpeningMethod("付费开通"));
|
.setId(shopUserInfo.getId()).setOpeningMethod("付费开通"));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user