| | |
| | | if(null != appUser1 && appUser1.getStatus() == 2){ |
| | | return R.fail("手机号已注册,请直接登录!"); |
| | | } |
| | | |
| | | String avatar = registerAccount.getAvatar(); |
| | | if (StringUtils.isEmpty(avatar)){ |
| | | avatar = "http://qijishenghuiyuan.obs.cn-southwest-2.myhuaweicloud.com/admin/aedfbbb41280471f8d9fa7905298b65f.png"; |
| | | } |
| | | |
| | | //如果手机号已注册,但是没有微信号,则将微信号添加到已有账户上 |
| | | if(null != appUser1 && StringUtils.isEmpty(appUser1.getWxOpenid())){ |
| | | appUser1.setWxOpenid(openid); |
| | |
| | | appUser = appUser1; |
| | | }else if(null == appUser){ |
| | | appUser = new AppUser(); |
| | | appUser.setAvatar(registerAccount.getAvatar()); |
| | | appUser.setAvatar(avatar); |
| | | appUser.setName(registerAccount.getName()); |
| | | appUser.setPhone(registerAccount.getPhone()); |
| | | appUser.setWxOpenid(openid); |
| | |
| | | .eq(AppUser::getStatus, 1).in(AppUser::getId, replaceable)); |
| | | for (AppUser appUser : list) { |
| | | Long data = orderClient.getOrderCountByAppUserId(appUser.getId()).getData(); |
| | | if(data == 0){ |
| | | if(data == 0L){ |
| | | appUser.setChangePromoter(1); |
| | | this.updateById(appUser); |
| | | } |
| | |
| | | Set<Integer> shopIds = shopR.getData(); |
| | | if (!CollectionUtils.isEmpty(shopIds)){ |
| | | appUser.setShopIds(shopIds); |
| | | }else { |
| | | return new Page<>(); |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public List<AppUser> getAppUserByPhoneNoFilter(String phone) { |
| | | return this.baseMapper.getAppUserByPhoneNoFilter(phone); |
| | | } |
| | | } |