Merge remote-tracking branch 'origin/test' into test

This commit is contained in:
张松
2025-10-29 17:21:23 +08:00

View File

@@ -275,10 +275,12 @@ public class MkDistributionUserServiceImpl extends ServiceImpl<MkDistributionUse
newShopUser.setDistributionUserParentId(parent.getParentId());
newShopUser.setInviteTime(LocalDateTime.now());
shopUserService.updateById(newShopUser);
//更新自己的下级 的上级的上级 为自己的上级
ShopUser childShopUser = new ShopUser();
childShopUser.setDistributionUserParentId(parent.getParentId());
shopUserService.update(childShopUser, QueryWrapper.create().eq(ShopUser::getDistributionUserId, shopUser.getId()));
if (parent.getParentId() != null) {
//更新自己的下级 的上级的上级 为自己的上级
ShopUser childShopUser = new ShopUser();
childShopUser.setDistributionUserParentId(parent.getParentId());
shopUserService.update(childShopUser, QueryWrapper.create().eq(ShopUser::getDistributionUserId, shopUser.getId()));
}
MkDistributionUser newDistributionUser = new MkDistributionUser();
newDistributionUser.setId(parent.getId());