userexamine

master
20918 12 months ago
parent 3b15d1ccf0
commit 0a1f5f5706

@ -96,9 +96,13 @@ public class SysUserExamineController extends BaseController {
@Log(title = "用户审核", businessType = BusinessType.PRINT) @Log(title = "用户审核", businessType = BusinessType.PRINT)
@GetMapping("/examineprint/{userId}") @GetMapping("/examineprint/{userId}")
@ResponseBody @ResponseBody
public SysUser paint(@PathVariable("userId") Long userId) public String paint(@PathVariable("userId") Long userId,ModelMap mmap)
{ {
return userService.selectUserById(userId); List<SysRole> roles = roleService.selectRolesByUserId(userId);
mmap.put("user",userService.selectUserById(userId));
mmap.put("roles", SysUser.isAdmin(userId) ? roles : roles.stream().filter(r -> !r.isAdmin()).collect(Collectors.toList()));
mmap.put("posts", postService.selectPostsByUserId(userId));
return prefix + "/examineprint";
} }
} }

Loading…
Cancel
Save