From 53d149f491dba554ee035599059a1bf65ea92df2 Mon Sep 17 00:00:00 2001
From: zhaowenxuan <chacca165@163.com>
Date: 星期三, 12 二月 2025 17:36:13 +0800
Subject: [PATCH] 增加手动同步lis接口

---
 ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysRoleController.java |   38 +++++++++++++++++++++++---------------
 1 files changed, 23 insertions(+), 15 deletions(-)

diff --git a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysRoleController.java b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysRoleController.java
index 9086d81..7d4215e 100644
--- a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysRoleController.java
+++ b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysRoleController.java
@@ -56,7 +56,7 @@
     @Autowired
     private ISysDeptService deptService;
 
-    @PreAuthorize("@ss.hasPermi('system:role:list')")
+//    @PreAuthorize("@ss.hasPermi('system:role:list')")
     @GetMapping("/list")
     public TableDataInfo list(SysRole role) {
         startPage();
@@ -65,7 +65,7 @@
     }
 
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.EXPORT)
-    @PreAuthorize("@ss.hasPermi('system:role:export')")
+//    @PreAuthorize("@ss.hasPermi('system:role:export')")
     @PostMapping("/export")
     public void export(HttpServletResponse response, SysRole role) {
         List<SysRole> list = roleService.selectRoleList(role);
@@ -76,7 +76,7 @@
     /**
      * 鏍规嵁瑙掕壊缂栧彿鑾峰彇璇︾粏淇℃伅
      */
-    @PreAuthorize("@ss.hasPermi('system:role:query')")
+//    @PreAuthorize("@ss.hasPermi('system:role:query')")
     @GetMapping(value = "/{roleId}")
     public AjaxResult getInfo(@PathVariable Long roleId) {
         roleService.checkRoleDataScope(roleId);
@@ -86,7 +86,7 @@
     /**
      * 鏂板瑙掕壊
      */
-    @PreAuthorize("@ss.hasPermi('system:role:add')")
+//    @PreAuthorize("@ss.hasPermi('system:role:add')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.INSERT)
     @PostMapping
     public AjaxResult add(@Validated @RequestBody SysRole role) {
@@ -103,7 +103,7 @@
     /**
      * 淇敼淇濆瓨瑙掕壊
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping
     public AjaxResult edit(@Validated @RequestBody SysRole role) {
@@ -132,7 +132,7 @@
     /**
      * 淇敼淇濆瓨鏁版嵁鏉冮檺
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping("/dataScope")
     public AjaxResult dataScope(@RequestBody SysRole role) {
@@ -144,7 +144,7 @@
     /**
      * 鐘舵�佷慨鏀�
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping("/changeStatus")
     public AjaxResult changeStatus(@RequestBody SysRole role) {
@@ -157,7 +157,7 @@
     /**
      * 鍒犻櫎瑙掕壊
      */
-    @PreAuthorize("@ss.hasPermi('system:role:remove')")
+//    @PreAuthorize("@ss.hasPermi('system:role:remove')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.DELETE)
     @DeleteMapping("/{roleIds}")
     public AjaxResult remove(@PathVariable Long[] roleIds) {
@@ -167,7 +167,7 @@
     /**
      * 鑾峰彇瑙掕壊閫夋嫨妗嗗垪琛�
      */
-    @PreAuthorize("@ss.hasPermi('system:role:query')")
+//    @PreAuthorize("@ss.hasPermi('system:role:query')")
     @GetMapping("/optionselect")
     public AjaxResult optionselect() {
         return success(roleService.selectRoleAll());
@@ -176,29 +176,37 @@
     /**
      * 鏌ヨ宸插垎閰嶇敤鎴疯鑹插垪琛�
      */
-    @PreAuthorize("@ss.hasPermi('system:role:list')")
+//    @PreAuthorize("@ss.hasPermi('system:role:list')")
     @GetMapping("/authUser/allocatedList")
     public TableDataInfo allocatedList(SysUser user) {
         startPage();
         List<SysUser> list = userService.selectAllocatedList(user);
+        for (SysUser sysUser : list) {
+            SysDept dept = deptService.getById(sysUser.getDeptId());
+            sysUser.setDept(dept);
+        }
         return getDataTable(list);
     }
 
     /**
      * 鏌ヨ鏈垎閰嶇敤鎴疯鑹插垪琛�
      */
-    @PreAuthorize("@ss.hasPermi('system:role:list')")
+//    @PreAuthorize("@ss.hasPermi('system:role:list')")
     @GetMapping("/authUser/unallocatedList")
     public TableDataInfo unallocatedList(SysUser user) {
         startPage();
         List<SysUser> list = userService.selectUnallocatedList(user);
+        for (SysUser sysUser : list) {
+            SysDept dept = deptService.getById(sysUser.getDeptId());
+            sysUser.setDept(dept);
+        }
         return getDataTable(list);
     }
 
     /**
      * 鍙栨秷鎺堟潈鐢ㄦ埛
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.GRANT)
     @PutMapping("/authUser/cancel")
     public AjaxResult cancelAuthUser(@RequestBody SysUserRole userRole) {
@@ -208,7 +216,7 @@
     /**
      * 鎵归噺鍙栨秷鎺堟潈鐢ㄦ埛
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.GRANT)
     @PutMapping("/authUser/cancelAll")
     public AjaxResult cancelAuthUserAll(Long roleId, Long[] userIds) {
@@ -218,7 +226,7 @@
     /**
      * 鎵归噺閫夋嫨鐢ㄦ埛鎺堟潈
      */
-    @PreAuthorize("@ss.hasPermi('system:role:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:role:edit')")
     @Log(title = "瑙掕壊绠$悊", businessType = BusinessType.GRANT)
     @PutMapping("/authUser/selectAll")
     public AjaxResult selectAuthUserAll(Long roleId, Long[] userIds) {
@@ -229,7 +237,7 @@
     /**
      * 鑾峰彇瀵瑰簲瑙掕壊閮ㄩ棬鏍戝垪琛�
      */
-    @PreAuthorize("@ss.hasPermi('system:role:query')")
+//    @PreAuthorize("@ss.hasPermi('system:role:query')")
     @GetMapping(value = "/deptTree/{roleId}")
     public AjaxResult deptTree(@PathVariable("roleId") Long roleId) {
         AjaxResult ajax = AjaxResult.success();

--
Gitblit v1.8.0