| | |
| | | Long userId = tokenService.getLoginUserApplet().getUserid(); |
| | | //当前用户信息 |
| | | AppUser user = appUserService.getById(userId); |
| | | if(StringUtils.isEmpty(user.getQrCode())){ |
| | | //获取微信推广二维码 |
| | | String fileName = UUID.randomUUID() + ".jpg"; |
| | | String getwxacodeunlimit = weChatUtil.getwxacodeunlimit("pages/start/start", "id=" + user.getId(), EnvVersion.RELEASE, filePath + fileName); |
| | | user.setQrCode(getwxacodeunlimit); |
| | | appUserService.updateById(user); |
| | | } |
| | | |
| | | //当前用户的推荐人信息 |
| | | if (user.getInviteUserId() != null) { |
| | | AppUser inviteUser = appUserService.getById(user.getInviteUserId()); |
| | |
| | | } |
| | | return R.ok(user); |
| | | } |
| | | |
| | | |
| | | public void getUserAncestorList(AppUser user,List<Long> userIds, List<AppUser> children,List<AppUser> list) { |
| | | children = list.stream().filter(u -> userIds.contains(u.getInviteUserId()) || userIds.contains(u.getTopInviteId())).collect(Collectors.toList()); |
| | | if(!CollectionUtils.isEmpty(children)){ |