| | |
| | | import com.xinquan.common.core.utils.page.CollUtils; |
| | | import com.xinquan.common.security.service.TokenService; |
| | | import com.xinquan.common.security.utils.SecurityUtils; |
| | | import com.xinquan.meditation.api.feign.RemoteMeditationService; |
| | | import com.xinquan.system.api.RemoteUserService; |
| | | import com.xinquan.system.api.domain.SysUser; |
| | | import com.xinquan.system.api.feignClient.SysUserClient; |
| | |
| | | import org.springframework.transaction.annotation.Transactional; |
| | | import org.springframework.util.StringUtils; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | /** |
| | | * <p> |
| | | * 用户信息表 服务实现类 |
| | |
| | | private final AppUserTreeService appUserTreeService; |
| | | private final AppUserQuestionService appUserQuestionService; |
| | | private final TagService tagService; |
| | | @Resource |
| | | private RemoteMeditationService remoteMeditationService; |
| | | /** |
| | | * 获取用户信息 |
| | | * |
| | |
| | | .ne(AppUser::getUserStatus,3).oneOpt(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * app用户注册 |
| | | * @param appUserDTO |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH"+format+randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | initUserTree(appUser.getId()); |
| | | return appUser; |
| | | }else{ |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH"+format+randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | initUserTree(appUser.getId()); |
| | | return appUser; |
| | | } |
| | |
| | | appUser.setLevelSettingId(TreeLevelEnum.SEED.getCode()); |
| | | appLoginUser.setBindStatus(DisabledEnum.YES.getCode()); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |
| | |
| | | appUser.setLevelSettingId(TreeLevelEnum.SEED.getCode()); |
| | | appLoginUser.setBindStatus(DisabledEnum.YES.getCode()); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH" + format + randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH" + format + randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH" + format + randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |
| | |
| | | String randomCode = String.valueOf((int) ((Math.random() * 9 + 1) * 1000)); |
| | | appUser.setCode("YH" + format + randomCode); |
| | | this.save(appUser); |
| | | remoteMeditationService.addHomeBackgroundMusicDefault(appUser.getId()); |
| | | |
| | | // 初始化用户树苗 |
| | | initUserTree(appUser.getId()); |
| | | } |