From 9ea8edde96272e14b0deacb81996a65c4fcb5285 Mon Sep 17 00:00:00 2001
From: lige <bestlige@outlook.com>
Date: 星期三, 13 九月 2023 16:49:18 +0800
Subject: [PATCH] 修改接口权限

---
 ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysUserController.java |   25 +++++++++++++------------
 1 files changed, 13 insertions(+), 12 deletions(-)

diff --git a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysUserController.java b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysUserController.java
index 6c1acc6..5f84df5 100644
--- a/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysUserController.java
+++ b/ltkj-admin/src/main/java/com/ltkj/web/controller/system/SysUserController.java
@@ -85,7 +85,7 @@
     /**
      * 鑾峰彇鐢ㄦ埛鍒楄〃
      */
-    @PreAuthorize("@ss.hasPermi('system:user:list')")
+//    @PreAuthorize("@ss.hasPermi('system:user:list')")
     @GetMapping("/list")
     @ApiOperation("鑾峰彇鐢ㄦ埛")
     public TableDataInfo list(@ApiParam(value = "鐢ㄦ埛瀵硅薄") SysUser user) {
@@ -134,7 +134,7 @@
     }
 
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.EXPORT)
-    @PreAuthorize("@ss.hasPermi('system:user:export')")
+//    @PreAuthorize("@ss.hasPermi('system:user:export')")
     @PostMapping("/export")
     public void export(HttpServletResponse response, SysUser user) {
         List<SysUser> list = userService.selectUserList(user);
@@ -143,7 +143,7 @@
     }
 
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.IMPORT)
-    @PreAuthorize("@ss.hasPermi('system:user:import')")
+//    @PreAuthorize("@ss.hasPermi('system:user:import')")
     @PostMapping("/importData")
     public AjaxResult importData(MultipartFile file, boolean updateSupport) throws Exception {
         ExcelUtil<SysUser> util = new ExcelUtil<SysUser>(SysUser.class);
@@ -162,7 +162,7 @@
     /**
      * 鏍规嵁鐢ㄦ埛id鑾峰彇璇︾粏淇℃伅
      */
-    @PreAuthorize("@ss.hasPermi('system:user:query')")
+//    @PreAuthorize("@ss.hasPermi('system:user:query')")
     @GetMapping("/{userId}")
     @ApiOperation("鏍规嵁鐢ㄦ埛id鑾峰彇璇︾粏淇℃伅")
     public AjaxResult getInfo(@PathVariable(value = "userId") @ApiParam(value = "鐢ㄦ埛id") @RequestParam Long userId) {
@@ -187,7 +187,7 @@
     /**
      * 鏂板鐢ㄦ埛
      */
-    @PreAuthorize("@ss.hasPermi('system:user:add')")
+//    @PreAuthorize("@ss.hasPermi('system:user:add')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.INSERT)
     @PostMapping
     @ApiOperation(value = "鏂板鐢ㄦ埛")
@@ -216,7 +216,7 @@
     /**
      * 淇敼鐢ㄦ埛
      */
-    @PreAuthorize("@ss.hasPermi('system:user:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:user:edit')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping
     @ApiOperation(value = "淇敼鐢ㄦ埛")
@@ -261,7 +261,7 @@
     /**
      * 鍒犻櫎鐢ㄦ埛
      */
-    @PreAuthorize("@ss.hasPermi('system:user:remove')")
+//    @PreAuthorize("@ss.hasPermi('system:user:remove')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.DELETE)
     @DeleteMapping("/{userIds}")
     @ApiOperation("鍒犻櫎鐢ㄦ埛")
@@ -283,12 +283,13 @@
     /**
      * 閲嶇疆瀵嗙爜
      */
-    @PreAuthorize("@ss.hasPermi('system:user:resetPwd')")
+//    @PreAuthorize("@ss.hasPermi('system:user:resetPwd')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping("/resetPwd")
     public AjaxResult resetPwd(@RequestBody SysUser user) {
         userService.checkUserAllowed(user);
         userService.checkUserDataScope(user.getUserId());
+        System.out.println(user.getPassword());
         user.setPassword(SecurityUtils.encryptPassword(user.getPassword()));
         user.setUpdateBy(getUsername());
         return toAjax(userService.resetPwd(user));
@@ -297,7 +298,7 @@
     /**
      * 鐘舵�佷慨鏀�
      */
-    @PreAuthorize("@ss.hasPermi('system:user:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:user:edit')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.UPDATE)
     @PutMapping("/changeStatus")
     public AjaxResult changeStatus(@RequestBody SysUser user) {
@@ -310,7 +311,7 @@
     /**
      * 鏍规嵁鐢ㄦ埛缂栧彿鑾峰彇鎺堟潈瑙掕壊
      */
-    @PreAuthorize("@ss.hasPermi('system:user:query')")
+//    @PreAuthorize("@ss.hasPermi('system:user:query')")
     @GetMapping("/authRole/{userId}")
     @ApiOperation(value = "鏍规嵁鐢ㄦ埛缂栧彿鑾峰彇鎺堟潈瑙掕壊")
     public AjaxResult authRole(@PathVariable("userId") Long userId) {
@@ -325,7 +326,7 @@
     /**
      * 鐢ㄦ埛鎺堟潈瑙掕壊
      */
-    @PreAuthorize("@ss.hasPermi('system:user:edit')")
+//    @PreAuthorize("@ss.hasPermi('system:user:edit')")
     @Log(title = "鐢ㄦ埛绠$悊", businessType = BusinessType.GRANT)
     @PutMapping("/authRole")
     @ApiOperation(value = "鐢ㄦ埛鎺堟潈瑙掕壊")
@@ -338,7 +339,7 @@
     /**
      * 鑾峰彇閮ㄩ棬鏍戝垪琛�
      */
-    @PreAuthorize("@ss.hasPermi('system:user:list')")
+//    @PreAuthorize("@ss.hasPermi('system:user:list')")
     @GetMapping("/deptTree")
     public AjaxResult deptTree(SysDept dept) {
         return success(deptService.selectDeptTreeList(dept));

--
Gitblit v1.8.0