| | |
| | | //@PreAuthorize("@ss.hasPermi('system:user:query')") |
| | | @GetMapping("/getInfo/{userId}") |
| | | public AjaxResult getInfo(@PathVariable(value = "userId", required = false) Long userId) { |
| | | log.info("--------userId的值为:{}",userId); |
| | | userService.checkUserDataScope(userId); |
| | | AjaxResult ajax = AjaxResult.success(); |
| | | List<SysRole> roles = roleService.selectRoleAll(); |
| | |
| | | SysUserDept sysUserDept = new SysUserDept(); |
| | | sysUserDept.setUserId(userId); |
| | | sysUserDept.setDeptType("1"); |
| | | LoginUser loginUser = getLoginUser(); |
| | | SysUser user = loginUser.getUser(); |
| | | log.info("--------user的值为:{}",user); |
| | | sysUserDept.setOrgid(user.getOrgid()); |
| | | sysUserDeptKSs = sysUserDeptMapper.selectSysUserDeptList(sysUserDept); |
| | | ajax.put("belongDepts", sysUserDeptKSs); |
| | | |
| | |
| | | @Log(title = "用户管理", businessType = BusinessType.GRANT) |
| | | @PostMapping("/authRole/insertAuthRole") |
| | | public AjaxResult insertAuthRole(@RequestBody AuthRole authRole) { |
| | | log.error("-----用户授权角色的入参为:userId={},roleIds={}", authRole.getUserId(), authRole.getRoleIds()); |
| | | log.info("-----用户授权角色的入参为:userId={},roleIds={}", authRole.getUserId(), authRole.getRoleIds()); |
| | | if (ObjectUtils.isEmpty(authRole.getRoleIds())) { |
| | | throw new BaseException("角色为空,请检查之后再次尝试"); |
| | | } |