|
@@ -75,6 +75,12 @@ public class JyUserPlatformServiceImpl extends ServiceImpl<IJyUserPlatformMapper
|
|
|
}
|
|
|
|
|
|
JyUser jyUser = jyUserService.getById(param.getId());
|
|
|
+ if(jyUser!= null && jyUser.getStatus() !=1){
|
|
|
+ throw new BusinessException(ResultCode.JY_ID_NO_EXIST);
|
|
|
+ }
|
|
|
+ if(jyUser == null){
|
|
|
+ throw new BusinessException(ResultCode.USER_BAN);
|
|
|
+ }
|
|
|
SysUser byId = sysUserService.getById(jyUser.getSysUserId());
|
|
|
if(byId.getRoleId() != 47L ){
|
|
|
throw new BusinessException(ResultCode.PLATFORM_USER_ADDERROR);
|
|
@@ -293,15 +299,7 @@ public class JyUserPlatformServiceImpl extends ServiceImpl<IJyUserPlatformMapper
|
|
|
throw new BusinessException(ResultCode.ID_CARD_EXIT);
|
|
|
}
|
|
|
JyUser byIdCard1 = jyUserService.getByIdCard(param.getIdCard());
|
|
|
- if(byIdCard1 != null && byIdCard1.getPlatformId()!=null ){
|
|
|
- SysUser byId = sysUserService.getById(byIdCard1.getSysUserId());
|
|
|
- if(byId.getRoleId() == 48L){
|
|
|
- throw new BusinessException(ResultCode.PLATFORM_USER_ADDERROR);
|
|
|
- }
|
|
|
- }
|
|
|
- if(byIdCard1!= null && byIdCard1.getStatus() !=1){
|
|
|
- throw new BusinessException(ResultCode.USER_BAN);
|
|
|
- }
|
|
|
+
|
|
|
if(byIdCard1 != null){
|
|
|
JyUserPlatformAddParam param1 = new JyUserPlatformAddParam();
|
|
|
param1.setId(byIdCard1.getId());
|