FrameExclusiveUserController.java 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. package com.idea.oa.searchuser;
  2. import com.rockstar.common.base.BaseController;
  3. import com.rockstar.shiro.util.ShiroUtils;
  4. import com.rockstar.util.ResponseUtil;
  5. import io.swagger.annotations.Api;
  6. import org.springframework.beans.factory.annotation.Autowired;
  7. import org.springframework.stereotype.Controller;
  8. import org.springframework.web.bind.annotation.PostMapping;
  9. import org.springframework.web.bind.annotation.RequestMapping;
  10. import org.springframework.web.bind.annotation.ResponseBody;
  11. /**
  12. * 2021.7.15
  13. */
  14. @Controller
  15. @RequestMapping(value = "FrameExclusiveUserController")
  16. @Api(value="用户页面专属配置")
  17. public class FrameExclusiveUserController extends BaseController {
  18. //主表
  19. @Autowired
  20. private FrameExclusiveUserService modelService;
  21. @Autowired
  22. private FrameRoleDataUserExtendService frameRoleDataUserExtendService;
  23. @PostMapping(value = "getUserListGroupType",produces = {"application/json;charset=UTF-8"})
  24. @ResponseBody
  25. public Object getUserListGroupType(String groupType,String groupId) {
  26. // if(!frameRoleDataUserExtendService.userHasRole(ShiroUtils.getUserId(),"GROUPCG")){
  27. // groupId = ShiroUtils.getUser().getGroupId();
  28. // }
  29. groupId=null;
  30. return ResponseUtil.ok(modelService.getUserListGroupType(groupType,groupId));
  31. }
  32. @PostMapping(value = "getBizUserList",produces = {"application/json;charset=UTF-8"})
  33. @ResponseBody
  34. public Object getBizUserList() {
  35. return ResponseUtil.ok(modelService.getBizUserList());
  36. }
  37. @PostMapping(value = "getUserBranch",produces = {"application/json;charset=UTF-8"})
  38. @ResponseBody
  39. public Object getUserBranch() {
  40. return ResponseUtil.ok(modelService.getUserBranch(ShiroUtils.getUserId()));
  41. }
  42. }