|
|
@ -31,7 +31,6 @@ import com.huoran.iasf.vo.req.ExcelImpUserReq; |
|
|
|
import com.huoran.iasf.vo.req.UserListReq; |
|
|
|
import com.huoran.iasf.vo.req.UserListReq; |
|
|
|
import com.huoran.iasf.vo.req.UserRoleOperationReqVO; |
|
|
|
import com.huoran.iasf.vo.req.UserRoleOperationReqVO; |
|
|
|
import com.huoran.iasf.vo.resp.LoginRespVO; |
|
|
|
import com.huoran.iasf.vo.resp.LoginRespVO; |
|
|
|
import com.huoran.iasf.vo.resp.PermissionRespNode; |
|
|
|
|
|
|
|
import com.huoran.iasf.vo.resp.UserListResp; |
|
|
|
import com.huoran.iasf.vo.resp.UserListResp; |
|
|
|
import com.huoran.iasf.vo.resp.UserOwnRoleRespVO; |
|
|
|
import com.huoran.iasf.vo.resp.UserOwnRoleRespVO; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
@ -132,11 +131,11 @@ public class UserServiceImpl extends ServiceImpl<SysUserMapper, SysUser> impleme |
|
|
|
if (!allowMultipleLogin) { |
|
|
|
if (!allowMultipleLogin) { |
|
|
|
httpSessionService.abortUserById(sysUser.getId()); |
|
|
|
httpSessionService.abortUserById(sysUser.getId()); |
|
|
|
} |
|
|
|
} |
|
|
|
List<PermissionRespNode> menus = permissionService.permissionTreeList(sysUser.getId()); |
|
|
|
List<SysPermission> menus = permissionService.permissionList(sysUser.getId()); |
|
|
|
|
|
|
|
|
|
|
|
String token = httpSessionService.createTokenAndUser(sysUser, roleService.getRoleNames(sysUser.getId()), permissionService.getPermissionsByUserId(sysUser.getId())); |
|
|
|
String token = httpSessionService.createTokenAndUser(sysUser, roleService.getRoleNames(sysUser.getId()), permissionService.getPermissionsByUserId(sysUser.getId())); |
|
|
|
respVO.setAccessToken(token); |
|
|
|
respVO.setAccessToken(token); |
|
|
|
respVO.setList(menus); |
|
|
|
respVO.setPermissionList(menus); |
|
|
|
return respVO; |
|
|
|
return respVO; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -655,6 +654,11 @@ public class UserServiceImpl extends ServiceImpl<SysUserMapper, SysUser> impleme |
|
|
|
SysUser vo = new SysUser(); |
|
|
|
SysUser vo = new SysUser(); |
|
|
|
vo.setSalt(PasswordUtils.getSalt()); |
|
|
|
vo.setSalt(PasswordUtils.getSalt()); |
|
|
|
String encode = PasswordUtils.encode("111aaa", vo.getSalt()); |
|
|
|
String encode = PasswordUtils.encode("111aaa", vo.getSalt()); |
|
|
|
|
|
|
|
vo.setRealName(realName); |
|
|
|
|
|
|
|
vo.setPhone(getPhone); |
|
|
|
|
|
|
|
vo.setJobNumber(jobNumber); |
|
|
|
|
|
|
|
vo.setEmail(getEmail); |
|
|
|
|
|
|
|
vo.setUsername(username); |
|
|
|
vo.setPassword(encode); |
|
|
|
vo.setPassword(encode); |
|
|
|
vo.setStatus(1); |
|
|
|
vo.setStatus(1); |
|
|
|
vo.setCreateWhere(1); |
|
|
|
vo.setCreateWhere(1); |
|
|
|