瀏覽代碼

解决PUT和DELETE方法的CORS跨域:把项目中多有的put改为Post,delete改为get

csg6 1 天之前
父節點
當前提交
0e86859d7d
共有 35 個文件被更改,包括 273 次插入119 次删除
  1. 6 3
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysConfigController.java
  2. 4 2
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java
  3. 5 3
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDictDataController.java
  4. 7 4
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDictTypeController.java
  5. 2 2
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysLoginController.java
  6. 4 2
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysMenuController.java
  7. 4 2
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysPostController.java
  8. 5 3
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java
  9. 14 7
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysRoleController.java
  10. 10 5
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysUserController.java
  11. 29 0
      ruoyi-admin/src/test/java/com/post/Test04.java
  12. 43 4
      ruoyi-common/src/main/java/com/ruoyi/common/filter/RestCorsFilter.java
  13. 2 2
      ruoyi-framework/src/main/java/com/ruoyi/framework/interceptor/cas/CasConfigure.java
  14. 6 4
      ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java
  15. 11 10
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRatingOtherController.java
  16. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRatingOtherInfoController.java
  17. 10 5
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRulesController.java
  18. 6 3
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedController.java
  19. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedItemsController.java
  20. 20 10
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedProblemController.java
  21. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedReportController.java
  22. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostHighlightsController.java
  23. 6 3
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostListController.java
  24. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanCheckUserController.java
  25. 10 5
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanController.java
  26. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanInfoController.java
  27. 5 6
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanJoinCheckedController.java
  28. 8 4
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostProgrammeController.java
  29. 6 3
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostProgrammeTemplateController.java
  30. 4 2
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamController.java
  31. 2 1
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamDeptController.java
  32. 2 1
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamUserController.java
  33. 6 5
      ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/service/impl/PostProgrammeServiceImpl.java
  34. 8 4
      ruoyi-quartz/src/main/java/com/ruoyi/quartz/controller/SysJobController.java
  35. 4 2
      ruoyi-quartz/src/main/java/com/ruoyi/quartz/controller/SysJobLogController.java

+ 6 - 3
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysConfigController.java

@@ -90,7 +90,8 @@ public class SysConfigController extends BaseController {
90 90
      */
91 91
     @PreAuthorize("@ss.hasPermi('system:config:edit')")
92 92
     @Log(title = "参数管理", businessType = BusinessType.UPDATE)
93
-    @PutMapping
93
+//    @PutMapping
94
+    @PostMapping("/edit")
94 95
     public AjaxResult edit(@Validated @RequestBody SysConfig config) {
95 96
         if (!configService.checkConfigKeyUnique(config)) {
96 97
             return error("修改参数'" + config.getConfigName() + "'失败,参数键名已存在");
@@ -104,7 +105,8 @@ public class SysConfigController extends BaseController {
104 105
      */
105 106
     @PreAuthorize("@ss.hasPermi('system:config:remove')")
106 107
     @Log(title = "参数管理", businessType = BusinessType.DELETE)
107
-    @DeleteMapping("/{configIds}")
108
+//    @DeleteMapping("/{configIds}")
109
+    @GetMapping("/remove/{configIds}")
108 110
     public AjaxResult remove(@PathVariable Long[] configIds) {
109 111
         configService.deleteConfigByIds(configIds);
110 112
         return success();
@@ -115,7 +117,8 @@ public class SysConfigController extends BaseController {
115 117
      */
116 118
     @PreAuthorize("@ss.hasPermi('system:config:remove')")
117 119
     @Log(title = "参数管理", businessType = BusinessType.CLEAN)
118
-    @DeleteMapping("/refreshCache")
120
+//    @DeleteMapping("/refreshCache")
121
+    @GetMapping("/remove/refreshCache")
119 122
     public AjaxResult refreshCache() {
120 123
         configService.resetConfigCache();
121 124
         return success();

+ 4 - 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDeptController.java

@@ -101,7 +101,8 @@ public class SysDeptController extends BaseController {
101 101
     })
102 102
     @PreAuthorize("@ss.hasPermi('system:dept:edit')")
103 103
     @Log(title = "部门管理", businessType = BusinessType.UPDATE)
104
-    @PutMapping
104
+//    @PutMapping
105
+    @PostMapping("/edit")
105 106
     public AjaxResult edit(@Validated @RequestBody SysDept dept) {
106 107
         Long deptId = dept.getDeptId();
107 108
         deptService.checkDeptDataScope(deptId);
@@ -121,7 +122,8 @@ public class SysDeptController extends BaseController {
121 122
      */
122 123
     @PreAuthorize("@ss.hasPermi('system:dept:remove')")
123 124
     @Log(title = "部门管理", businessType = BusinessType.DELETE)
124
-    @DeleteMapping("/{deptId}")
125
+//    @DeleteMapping("/{deptId}")
126
+    @GetMapping("/remove/{deptId}")
125 127
     public AjaxResult remove(@PathVariable Long deptId) {
126 128
         if (deptService.hasChildByDeptId(deptId)) {
127 129
             return warn("存在下级部门,不允许删除");

+ 5 - 3
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDictDataController.java

@@ -27,7 +27,7 @@ import com.ruoyi.system.service.ISysDictTypeService;
27 27
 
28 28
 /**
29 29
  * 数据字典信息
30
- * 
30
+ *
31 31
  * @author ruoyi
32 32
  */
33 33
 @RestController
@@ -100,7 +100,8 @@ public class SysDictDataController extends BaseController
100 100
      */
101 101
     @PreAuthorize("@ss.hasPermi('system:dict:edit')")
102 102
     @Log(title = "字典数据", businessType = BusinessType.UPDATE)
103
-    @PutMapping
103
+//    @PutMapping
104
+    @PostMapping("/edit")
104 105
     public AjaxResult edit(@Validated @RequestBody SysDictData dict)
105 106
     {
106 107
         dict.setUpdateBy(getUsername());
@@ -112,7 +113,8 @@ public class SysDictDataController extends BaseController
112 113
      */
113 114
     @PreAuthorize("@ss.hasPermi('system:dict:remove')")
114 115
     @Log(title = "字典类型", businessType = BusinessType.DELETE)
115
-    @DeleteMapping("/{dictCodes}")
116
+//    @DeleteMapping("/{dictCodes}")
117
+    @GetMapping("/remove/{dictCodes}")
116 118
     public AjaxResult remove(@PathVariable Long[] dictCodes)
117 119
     {
118 120
         dictDataService.deleteDictDataByIds(dictCodes);

+ 7 - 4
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysDictTypeController.java

@@ -24,7 +24,7 @@ import com.ruoyi.system.service.ISysDictTypeService;
24 24
 
25 25
 /**
26 26
  * 数据字典信息
27
- * 
27
+ *
28 28
  * @author ruoyi
29 29
  */
30 30
 @RestController
@@ -84,7 +84,8 @@ public class SysDictTypeController extends BaseController
84 84
      */
85 85
     @PreAuthorize("@ss.hasPermi('system:dict:edit')")
86 86
     @Log(title = "字典类型", businessType = BusinessType.UPDATE)
87
-    @PutMapping
87
+//    @PutMapping
88
+    @PostMapping("/edit")
88 89
     public AjaxResult edit(@Validated @RequestBody SysDictType dict)
89 90
     {
90 91
         if (!dictTypeService.checkDictTypeUnique(dict))
@@ -100,7 +101,8 @@ public class SysDictTypeController extends BaseController
100 101
      */
101 102
     @PreAuthorize("@ss.hasPermi('system:dict:remove')")
102 103
     @Log(title = "字典类型", businessType = BusinessType.DELETE)
103
-    @DeleteMapping("/{dictIds}")
104
+//    @DeleteMapping("/{dictIds}")
105
+    @GetMapping("/remove/{dictIds}")
104 106
     public AjaxResult remove(@PathVariable Long[] dictIds)
105 107
     {
106 108
         dictTypeService.deleteDictTypeByIds(dictIds);
@@ -112,7 +114,8 @@ public class SysDictTypeController extends BaseController
112 114
      */
113 115
     @PreAuthorize("@ss.hasPermi('system:dict:remove')")
114 116
     @Log(title = "字典类型", businessType = BusinessType.CLEAN)
115
-    @DeleteMapping("/refreshCache")
117
+//    @DeleteMapping("/refreshCache")
118
+    @GetMapping("/remove/refreshCache")
116 119
     public AjaxResult refreshCache()
117 120
     {
118 121
         dictTypeService.resetDictCache();

+ 2 - 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysLoginController.java

@@ -43,7 +43,7 @@ public class SysLoginController {
43 43
      * @return 结果
44 44
      */
45 45
     //TODO 打包屏蔽-甲方部署时注释:甲方不需要本地登录功能采用单点登录
46
-  /*  @PostMapping("/login")
46
+    @PostMapping("/login")
47 47
     public AjaxResult login(@RequestBody LoginBody loginBody) {
48 48
         AjaxResult ajax = AjaxResult.success();
49 49
 
@@ -51,7 +51,7 @@ public class SysLoginController {
51 51
         String token = loginService.login(loginBody.getUsername(), loginBody.getPassword(), loginBody.getCode(), loginBody.getUuid(), true);
52 52
         ajax.put(Constants.TOKEN, token);
53 53
         return ajax;
54
-    }*/
54
+    }
55 55
 
56 56
     /**
57 57
      * 获取用户信息

+ 4 - 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysMenuController.java

@@ -106,7 +106,8 @@ public class SysMenuController extends BaseController {
106 106
     @ApiOperation("修改菜单")
107 107
     @PreAuthorize("@ss.hasPermi('system:menu:edit')")
108 108
     @Log(title = "菜单管理", businessType = BusinessType.UPDATE)
109
-    @PutMapping
109
+//    @PutMapping
110
+    @PostMapping("/edit")
110 111
     public AjaxResult edit(@Validated @RequestBody SysMenu menu) {
111 112
         if (!menuService.checkMenuNameUnique(menu)) {
112 113
             return error("修改菜单'" + menu.getMenuName() + "'失败,菜单名称已存在");
@@ -125,7 +126,8 @@ public class SysMenuController extends BaseController {
125 126
     @ApiOperation("删除菜单")
126 127
     @PreAuthorize("@ss.hasPermi('system:menu:remove')")
127 128
     @Log(title = "菜单管理", businessType = BusinessType.DELETE)
128
-    @DeleteMapping("/{menuId}")
129
+//    @DeleteMapping("/{menuId}")
130
+    @GetMapping("/remove/{menuId}")
129 131
     public AjaxResult remove(
130 132
             @ApiParam(name = "menuId", value = "菜单ID", required = true)
131 133
             @PathVariable("menuId") Long menuId) {

+ 4 - 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysPostController.java

@@ -113,7 +113,8 @@ public class SysPostController extends BaseController {
113 113
     })
114 114
     @PreAuthorize("@ss.hasPermi('system:post:edit')")
115 115
     @Log(title = "岗位管理", businessType = BusinessType.UPDATE)
116
-    @PutMapping
116
+//    @PutMapping
117
+    @PostMapping("/edit")
117 118
     public AjaxResult edit(@Validated @RequestBody SysPost post) {
118 119
         if (!postService.checkPostNameUnique(post)) {
119 120
             return error("修改岗位'" + post.getPostName() + "'失败,岗位名称已存在");
@@ -129,7 +130,8 @@ public class SysPostController extends BaseController {
129 130
     @ApiOperation("删除岗位")
130 131
     @PreAuthorize("@ss.hasPermi('system:post:remove')")
131 132
     @Log(title = "岗位管理", businessType = BusinessType.DELETE)
132
-    @DeleteMapping("/{postIds}")
133
+//    @DeleteMapping("/{postIds}")
134
+    @GetMapping("/remove/{postIds}")
133 135
     public AjaxResult remove(
134 136
             @ApiParam(name = "postIds", value = "岗位ID数组", required = true)
135 137
             @PathVariable Long[] postIds) {

+ 5 - 3
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysProfileController.java

@@ -25,7 +25,7 @@ import com.ruoyi.system.service.ISysUserService;
25 25
 
26 26
 /**
27 27
  * 个人信息 业务处理
28
- * 
28
+ *
29 29
  * @author ruoyi
30 30
  */
31 31
 @RestController
@@ -56,7 +56,8 @@ public class SysProfileController extends BaseController
56 56
      * 修改用户
57 57
      */
58 58
     @Log(title = "个人信息", businessType = BusinessType.UPDATE)
59
-    @PutMapping
59
+//    @PutMapping
60
+    @PostMapping("/edit")
60 61
     public AjaxResult updateProfile(@RequestBody SysUser user)
61 62
     {
62 63
         LoginUser loginUser = getLoginUser();
@@ -86,7 +87,8 @@ public class SysProfileController extends BaseController
86 87
      * 重置密码
87 88
      */
88 89
     @Log(title = "个人信息", businessType = BusinessType.UPDATE)
89
-    @PutMapping("/updatePwd")
90
+//    @PutMapping("/updatePwd")
91
+    @PostMapping("/updatePwd/edit")
90 92
     public AjaxResult updatePwd(String oldPassword, String newPassword)
91 93
     {
92 94
         LoginUser loginUser = getLoginUser();

+ 14 - 7
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysRoleController.java

@@ -107,7 +107,8 @@ public class SysRoleController extends BaseController {
107 107
     @ApiOperation("修改角色")
108 108
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
109 109
     @Log(title = "角色管理", businessType = BusinessType.UPDATE)
110
-    @PutMapping
110
+//    @PutMapping
111
+    @PostMapping("/edit")
111 112
     public AjaxResult edit(@Validated @RequestBody SysRole role) {
112 113
         roleService.checkRoleAllowed(role);
113 114
         roleService.checkRoleDataScope(role.getRoleId());
@@ -136,7 +137,8 @@ public class SysRoleController extends BaseController {
136 137
      */
137 138
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
138 139
     @Log(title = "角色管理", businessType = BusinessType.UPDATE)
139
-    @PutMapping("/dataScope")
140
+//    @PutMapping("/dataScope")
141
+    @PostMapping("/dataScope/edit")
140 142
     public AjaxResult dataScope(@RequestBody SysRole role) {
141 143
         roleService.checkRoleAllowed(role);
142 144
         roleService.checkRoleDataScope(role.getRoleId());
@@ -149,7 +151,8 @@ public class SysRoleController extends BaseController {
149 151
     @ApiOperation("角色状态修改")
150 152
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
151 153
     @Log(title = "角色管理", businessType = BusinessType.UPDATE)
152
-    @PutMapping("/changeStatus")
154
+//    @PutMapping("/changeStatus")
155
+    @PostMapping("/changeStatus/edit")
153 156
     public AjaxResult changeStatus(@RequestBody SysRole role) {
154 157
         roleService.checkRoleAllowed(role);
155 158
         roleService.checkRoleDataScope(role.getRoleId());
@@ -163,7 +166,8 @@ public class SysRoleController extends BaseController {
163 166
     @ApiOperation("删除角色")
164 167
     @PreAuthorize("@ss.hasPermi('system:role:remove')")
165 168
     @Log(title = "角色管理", businessType = BusinessType.DELETE)
166
-    @DeleteMapping("/{roleIds}")
169
+//    @DeleteMapping("/{roleIds}")
170
+    @GetMapping("/remove/{roleIds}")
167 171
     public AjaxResult remove(@PathVariable Long[] roleIds) {
168 172
         return toAjax(roleService.deleteRoleByIds(roleIds));
169 173
     }
@@ -209,7 +213,8 @@ public class SysRoleController extends BaseController {
209 213
     @ApiOperation("取消授权用户")
210 214
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
211 215
     @Log(title = "角色管理", businessType = BusinessType.GRANT)
212
-    @PutMapping("/authUser/cancel")
216
+//    @PutMapping("/authUser/cancel")
217
+    @PostMapping("/authUser/cancel/edit")
213 218
     public AjaxResult cancelAuthUser(@RequestBody SysUserRole userRole) {
214 219
         return toAjax(roleService.deleteAuthUser(userRole));
215 220
     }
@@ -224,7 +229,8 @@ public class SysRoleController extends BaseController {
224 229
     })
225 230
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
226 231
     @Log(title = "角色管理", businessType = BusinessType.GRANT)
227
-    @PutMapping("/authUser/cancelAll")
232
+//    @PutMapping("/authUser/cancelAll")
233
+    @PostMapping("/authUser/cancelAll/edit")
228 234
     public AjaxResult cancelAuthUserAll(Long roleId, Long[] userIds) {
229 235
         return toAjax(roleService.deleteAuthUsers(roleId, userIds));
230 236
     }
@@ -239,7 +245,8 @@ public class SysRoleController extends BaseController {
239 245
     })
240 246
     @PreAuthorize("@ss.hasPermi('system:role:edit')")
241 247
     @Log(title = "角色管理", businessType = BusinessType.GRANT)
242
-    @PutMapping("/authUser/selectAll")
248
+//    @PutMapping("/authUser/selectAll")
249
+    @PostMapping("/authUser/selectAll/edit")
243 250
     public AjaxResult selectAuthUserAll(Long roleId, Long[] userIds) {
244 251
         roleService.checkRoleDataScope(roleId);
245 252
         return toAjax(roleService.insertAuthUsers(roleId, userIds));

+ 10 - 5
ruoyi-admin/src/main/java/com/ruoyi/web/controller/system/SysUserController.java

@@ -168,7 +168,8 @@ public class SysUserController extends BaseController {
168 168
      */
169 169
     @PreAuthorize("@ss.hasPermi('system:user:edit')")
170 170
     @Log(title = "用户管理", businessType = BusinessType.UPDATE)
171
-    @PutMapping
171
+//    @PutMapping
172
+    @PostMapping("/edit")
172 173
     @ApiOperation("用户修改")
173 174
     @ApiImplicitParams({
174 175
             @ApiImplicitParam(name = "userId", value = "主键", dataType = "Long", dataTypeClass = Long.class),
@@ -196,7 +197,8 @@ public class SysUserController extends BaseController {
196 197
      */
197 198
     @PreAuthorize("@ss.hasPermi('system:user:remove')")
198 199
     @Log(title = "用户管理", businessType = BusinessType.DELETE)
199
-    @DeleteMapping("/{userIds}")
200
+//    @DeleteMapping("/{userIds}")
201
+    @GetMapping("/remove/{userIds}")
200 202
     public AjaxResult remove(@PathVariable Long[] userIds) {
201 203
         if (ArrayUtils.contains(userIds, getUserId())) {
202 204
             return error("当前用户不能删除");
@@ -209,7 +211,8 @@ public class SysUserController extends BaseController {
209 211
      */
210 212
     @PreAuthorize("@ss.hasPermi('system:user:resetPwd')")
211 213
     @Log(title = "用户管理", businessType = BusinessType.UPDATE)
212
-    @PutMapping("/resetPwd")
214
+//    @PutMapping("/resetPwd")
215
+    @PostMapping("/resetPwd/edit")
213 216
     public AjaxResult resetPwd(@RequestBody SysUser user) {
214 217
         userService.checkUserAllowed(user);
215 218
         userService.checkUserDataScope(user.getUserId());
@@ -223,7 +226,8 @@ public class SysUserController extends BaseController {
223 226
      */
224 227
     @PreAuthorize("@ss.hasPermi('system:user:edit')")
225 228
     @Log(title = "用户管理", businessType = BusinessType.UPDATE)
226
-    @PutMapping("/changeStatus")
229
+//    @PutMapping("/changeStatus")
230
+    @PostMapping("/changeStatus/edit")
227 231
     @ApiOperation("用户状态修改")
228 232
     @ApiImplicitParams({
229 233
             @ApiImplicitParam(name = "userId", value = "主键", dataType = "Long", dataTypeClass = Long.class),
@@ -256,7 +260,8 @@ public class SysUserController extends BaseController {
256 260
      */
257 261
     @PreAuthorize("@ss.hasPermi('system:user:edit')")
258 262
     @Log(title = "用户管理", businessType = BusinessType.GRANT)
259
-    @PutMapping("/authRole")
263
+//    @PutMapping("/authRole")
264
+    @PostMapping("/authRole/edit")
260 265
     @ApiOperation("用户授权角色")
261 266
     @ApiImplicitParams({
262 267
             @ApiImplicitParam(name = "userId", value = "用户ID", dataType = "Long", dataTypeClass = Long.class),

+ 29 - 0
ruoyi-admin/src/test/java/com/post/Test04.java

@@ -0,0 +1,29 @@
1
+package com.post;
2
+
3
+import com.ruoyi.common.core.domain.entity.SysUser;
4
+
5
+import java.math.BigDecimal;
6
+import java.util.*;
7
+import java.util.stream.Collectors;
8
+
9
+public class Test04 {
10
+    public static void main(String[] args) {
11
+//        "http://10.152.70.21:8080", // CAS服务器
12
+//        "http://10.152.72.7:8181" // 岗检前端Nginx
13
+        String url1 = "http://10.152.70.21:8080/cas/login";
14
+
15
+
16
+        int index = url1.indexOf("//");
17
+        System.out.println("index = " + index);
18
+        String url1Sub = url1.substring(index + 2);
19
+        System.out.println("url1Sub = " + url1Sub);
20
+
21
+        int index1 = url1Sub.indexOf("/");
22
+        System.out.println("index1 = " + index1);
23
+
24
+        url1Sub = url1Sub.substring(0,index1);
25
+
26
+        System.out.println("url1Sub = " + url1Sub);
27
+
28
+    }
29
+}

+ 43 - 4
ruoyi-common/src/main/java/com/ruoyi/common/filter/RestCorsFilter.java

@@ -1,6 +1,9 @@
1 1
 package com.ruoyi.common.filter;
2 2
 
3
+import com.ruoyi.common.config.CasConfig;
3 4
 import com.ruoyi.common.utils.StringUtils;
5
+import lombok.extern.slf4j.Slf4j;
6
+import org.springframework.beans.factory.annotation.Autowired;
4 7
 import org.springframework.core.Ordered;
5 8
 import org.springframework.core.annotation.Order;
6 9
 import org.springframework.stereotype.Component;
@@ -13,47 +16,83 @@ import java.util.Arrays;
13 16
 import java.util.HashSet;
14 17
 import java.util.Set;
15 18
 
19
+@Slf4j
16 20
 @Component
17 21
 @Order(Ordered.HIGHEST_PRECEDENCE)
18 22
 public class RestCorsFilter implements Filter {
19 23
 
24
+    //配置文件:application-cas-test.yml -> caseitc:
25
+//    @Autowired
26
+//    private CasConfig casConfig;
27
+
28
+
20 29
     public RestCorsFilter() {
21 30
     }
22 31
 
23 32
     @Override
24 33
     public void doFilter(ServletRequest req, ServletResponse res, FilterChain chain) throws IOException, ServletException {
34
+        log.info("");
25 35
         HttpServletResponse response = (HttpServletResponse) res;
26 36
         HttpServletRequest request = (HttpServletRequest) req;
27 37
 
38
+        log.info("【跨域过滤器】request.getMethod() = " + request.getMethod());
39
+//        log.info("【跨域过滤器】request.getContextPath() = " + request.getContextPath());
40
+//        log.info("【跨域过滤器】request.getServletPath() = " + request.getServletPath());///system/role/41749924753409
41
+        log.info("【跨域过滤器】request.getRequestURI() = " + request.getRequestURI());///system/role/41749924753409
42
+        log.info("【跨域过滤器】request.getRequestURL() = " + request.getRequestURL());//http://192.168.3.200:8180/system/role/41749924753409
43
+//        log.info("【跨域过滤器】request.getServletContext().getRealPath(\"/\") = " + request.getServletContext().getRealPath("/"));//获取“/”在机器中的实际地址 C:\Users\15753\AppData\Local\Temp\tomcat-docbase.8180.7251487789088039644\
44
+
45
+//        String serverLoginUrl = casConfig.getServerLoginUrl();
46
+//        String webStartPage = casConfig.getWebStartPage();
47
+//        log.info("【跨域过滤器】serverLoginUrl = " + serverLoginUrl);
48
+//        log.info("【跨域过滤器】webStartPage = " + webStartPage);
49
+
28 50
         // 允许的来源
29 51
         String[] allowDomain = {
30 52
                 "http://10.152.70.21:8080", // CAS服务器
31
-                "http://10.152.72.7:8181" // 岗检前端Nginx
53
+                "http://10.152.72.7:8181", // 岗检前端Nginx
54
+                "http://10.152.72.7:8180" // 岗检JAVA接口
32 55
                 // "*.cnooc.*"
33 56
                 // TODO 打包屏蔽-甲方部署时注释:甲方不需要本地登录功能采用单点登录
34
-//                , "http://192.168.3.32:81"  // 前端开发
57
+                , "http://192.168.3.187:8181"  // 前端开发-王宇
58
+                , "http://192.168.3.32:81"  // 前端开发-李帅
59
+                , "http://192.168.3.200:8181"  // 前端开发
35 60
         };
36 61
         Set<String> allowedOrigins = new HashSet<>(Arrays.asList(allowDomain));
37 62
         String originHeader = request.getHeader("Origin");
63
+        log.info("【跨域过滤器】拿到请求中的request.getHeader(\"Origin\") = {}", originHeader);
38 64
 
39 65
         //前端的头Origin为空时设置为前端Nginx的地址
40 66
         //前端跳转方式:src/views/postcheck.vue -> window.location.href = `${this.getBaseUrl()}/redirectpostcheck`;
41 67
         if (StringUtils.isBlank(originHeader)) {
42
-//            originHeader = "http://192.168.3.32:81";
43
-            originHeader = "http://10.152.72.7:8181";
68
+//            originHeader = "http://10.152.72.7:8181";//岗检前端Nginx
69
+//            originHeader = "http://10.152.72.7:8180";//岗检JAVA接口
70
+            originHeader = "http://192.168.3.32:81";//李帅
71
+//            originHeader = "http://192.168.3.187:8181";//王宇
72
+            log.info("【跨域过滤器】拿到请求中的request.getHeader(\"Origin\") 等于空,服务器设置默认值后 = {}", originHeader);
44 73
         }
45 74
 
75
+        //全部设置为JAVA地址
76
+//        originHeader = "http://10.152.72.7:8180";//岗检JAVA接口
77
+//        log.info("【跨域过滤器】Access-Control-Allow-Origin全部设置为JAVA地址 = {}", originHeader);
78
+
46 79
         if (allowedOrigins.contains(originHeader)) {
80
+            log.info("【跨域过滤器】设置响应头-开始");
47 81
             response.setHeader("Access-Control-Allow-Origin", originHeader);
48 82
             response.setHeader("Access-Control-Allow-Credentials", "true");
49 83
             response.setHeader("Access-Control-Allow-Methods", "POST,GET,DELETE,PUT,OPTIONS");
84
+//            response.setHeader("Access-Control-Allow-Methods", "POST,GET,DELETE,PUT");
50 85
             response.setHeader("Access-Control-Max-Age", "31536000");
51 86
             response.setHeader("Access-Control-Allow-Headers", "*");
52 87
             response.setStatus(HttpServletResponse.SC_OK);
88
+            log.info("【跨域过滤器】设置响应头-结束");
53 89
         } else {
90
+            log.info("【跨域过滤器】终止本次请求,返回给客户端的状态码是403");
54 91
             response.setStatus(HttpServletResponse.SC_FORBIDDEN);
55 92
             return;
56 93
         }
94
+        log.info("【跨域过滤器】验证通过,放行本次请求。");
95
+        log.info("");
57 96
         chain.doFilter(req, res);
58 97
     }
59 98
 

+ 2 - 2
ruoyi-framework/src/main/java/com/ruoyi/framework/interceptor/cas/CasConfigure.java

@@ -9,8 +9,8 @@ import net.unicon.cas.client.configuration.EnableCasClient;
9 9
 /**
10 10
  * TODO 甲方部署时打开:CAS统一认证拦截器
11 11
  */
12
-@EnableCasClient
13
-@Configuration
12
+//@EnableCasClient
13
+//@Configuration
14 14
 public class CasConfigure extends CasClientConfigurerAdapter {
15 15
     @Override
16 16
     public void configureAuthenticationFilter(FilterRegistrationBean authenticationFilter) {

+ 6 - 4
ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java

@@ -30,7 +30,7 @@ import com.ruoyi.generator.service.IGenTableService;
30 30
 
31 31
 /**
32 32
  * 代码生成 操作处理
33
- * 
33
+ *
34 34
  * @author ruoyi
35 35
  */
36 36
 @RestController
@@ -118,7 +118,8 @@ public class GenController extends BaseController
118 118
      */
119 119
     @PreAuthorize("@ss.hasPermi('tool:gen:edit')")
120 120
     @Log(title = "代码生成", businessType = BusinessType.UPDATE)
121
-    @PutMapping
121
+//    @PutMapping
122
+    @PostMapping("/edit")
122 123
     public AjaxResult editSave(@Validated @RequestBody GenTable genTable)
123 124
     {
124 125
         genTableService.validateEdit(genTable);
@@ -131,7 +132,8 @@ public class GenController extends BaseController
131 132
      */
132 133
     @PreAuthorize("@ss.hasPermi('tool:gen:remove')")
133 134
     @Log(title = "代码生成", businessType = BusinessType.DELETE)
134
-    @DeleteMapping("/{tableIds}")
135
+//    @DeleteMapping("/{tableIds}")
136
+    @GetMapping("/remove/{tableIds}")
135 137
     public AjaxResult remove(@PathVariable Long[] tableIds)
136 138
     {
137 139
         genTableService.deleteGenTableByIds(tableIds);
@@ -211,4 +213,4 @@ public class GenController extends BaseController
211 213
         response.setContentType("application/octet-stream; charset=UTF-8");
212 214
         IOUtils.write(data, response.getOutputStream());
213 215
     }
214
-}
216
+}

+ 11 - 10
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRatingOtherController.java

@@ -159,16 +159,17 @@ public class PostAssessmentRatingOtherController extends BaseController {
159 159
      */
160 160
 
161 161
     /**
162
-     * 删除打分表(职能互评生产日常)
163
-     *
164
-     * @ApiOperation("删除打分表(职能互评生产日常)")
165
-     * @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
166
-     * @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRatingOther:remove')")
167
-     * @Log(title = "打分表(职能互评生产日常)", businessType = BusinessType.DELETE)
168
-     * @DeleteMapping("/{ids}") public AjaxResult remove(@PathVariable Long[] ids)
169
-     * {
170
-     * return toAjax(postAssessmentRatingOtherService.deletePostAssessmentRatingOtherByIds(ids));
171
-     * }
162
+      删除打分表(职能互评生产日常)
163
+
164
+      @ApiOperation("删除打分表(职能互评生产日常)")
165
+      @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
166
+      @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRatingOther:remove')")
167
+      @Log(title = "打分表(职能互评生产日常)", businessType = BusinessType.DELETE)
168
+      @DeleteMapping("/{ids}")
169
+      public AjaxResult remove(@PathVariable Long[] ids)
170
+      {
171
+      return toAjax(postAssessmentRatingOtherService.deletePostAssessmentRatingOtherByIds(ids));
172
+      }
172 173
      */
173 174
 
174 175
 

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRatingOtherInfoController.java

@@ -132,7 +132,8 @@ public class PostAssessmentRatingOtherInfoController extends BaseController {
132 132
     })
133 133
     @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRatingOtherInfo:edit')")
134 134
     @Log(title = "打分表明细(职能互评生产日常)", businessType = BusinessType.UPDATE)
135
-    @PutMapping
135
+//    @PutMapping
136
+    @PostMapping("/edit")
136 137
     public AjaxResult edit(@RequestBody PostAssessmentRatingOtherInfo postAssessmentRatingOtherInfo) {
137 138
         return toAjax(postAssessmentRatingOtherInfoService.updatePostAssessmentRatingOtherInfo(postAssessmentRatingOtherInfo));
138 139
     }
@@ -144,7 +145,8 @@ public class PostAssessmentRatingOtherInfoController extends BaseController {
144 145
     @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
145 146
     @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRatingOtherInfo:remove')")
146 147
     @Log(title = "打分表明细(职能互评生产日常)", businessType = BusinessType.DELETE)
147
-    @DeleteMapping("/{ids}")
148
+//    @DeleteMapping("/{ids}")
149
+    @GetMapping("/remove/{ids}")
148 150
     public AjaxResult remove(@PathVariable Long[] ids) {
149 151
         return toAjax(postAssessmentRatingOtherInfoService.deletePostAssessmentRatingOtherInfoByIds(ids));
150 152
     }

+ 10 - 5
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRulesController.java

@@ -156,7 +156,8 @@ public class PostAssessmentRulesController extends BaseController
156 156
     })
157 157
     @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRules:edit')")
158 158
     @Log(title = "考核规则", businessType = BusinessType.UPDATE)
159
-    @PutMapping
159
+//    @PutMapping
160
+    @PostMapping("/edit")
160 161
     public AjaxResult edit(@RequestBody PostAssessmentRules postAssessmentRules)
161 162
     {
162 163
         return toAjax(postAssessmentRulesService.updatePostAssessmentRules(postAssessmentRules));
@@ -169,7 +170,8 @@ public class PostAssessmentRulesController extends BaseController
169 170
     @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
170 171
     @PreAuthorize("@ss.hasPermi('postCheck:postAssessmentRules:remove')")
171 172
     @Log(title = "考核规则", businessType = BusinessType.DELETE)
172
-	@DeleteMapping("/{ids}")
173
+//	@DeleteMapping("/{ids}")
174
+    @GetMapping("/remove/{ids}")
173 175
     public AjaxResult remove(@PathVariable Long[] ids)
174 176
     {
175 177
         return toAjax(postAssessmentRulesService.deletePostAssessmentRulesByIds(ids));
@@ -182,7 +184,8 @@ public class PostAssessmentRulesController extends BaseController
182 184
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
183 185
     })
184 186
     @Log(title = "考核规则审核", businessType = BusinessType.UPDATE)
185
-    @PutMapping("/statusApprove")
187
+//    @PutMapping("/statusApprove")
188
+    @PostMapping("/statusApprove/edit")
186 189
     public AjaxResult statusApprove(Long id, Integer status, String statusReason) {
187 190
 
188 191
         // 判断审核的权限
@@ -212,7 +215,8 @@ public class PostAssessmentRulesController extends BaseController
212 215
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
213 216
     })
214 217
     @Log(title = "考核规则审核-职能", businessType = BusinessType.UPDATE)
215
-    @PutMapping("/statusFunctions")
218
+//    @PutMapping("/statusFunctions")
219
+    @PostMapping("/statusFunctions/edit")
216 220
     public AjaxResult statusFunctions(Long id, Integer status, String statusReason) {
217 221
 
218 222
         // 判断审核的权限
@@ -242,7 +246,8 @@ public class PostAssessmentRulesController extends BaseController
242 246
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
243 247
     })
244 248
     @Log(title = "考核规则审核-生产", businessType = BusinessType.UPDATE)
245
-    @PutMapping("/statusProduction")
249
+//    @PutMapping("/statusProduction")
250
+    @PostMapping("/statusProduction/edit")
246 251
     public AjaxResult statusProduction(Long id, Integer status, String statusReason) {
247 252
 
248 253
         // 判断审核的权限

+ 6 - 3
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedController.java

@@ -146,7 +146,8 @@ public class PostCheckedController extends BaseController {
146 146
     })*/
147 147
     @PreAuthorize("@ss.hasPermi('postCheck:postChecked:edit')")
148 148
     @Log(title = "岗检表管理", businessType = BusinessType.UPDATE)
149
-    @PutMapping
149
+//    @PutMapping
150
+    @PostMapping("/edit")
150 151
     public AjaxResult edit(@RequestBody PostChecked postChecked) {
151 152
         return toAjax(postCheckedService.updatePostChecked(postChecked));
152 153
     }
@@ -158,7 +159,8 @@ public class PostCheckedController extends BaseController {
158 159
 //    @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
159 160
     @PreAuthorize("@ss.hasPermi('postCheck:postChecked:remove')")
160 161
     @Log(title = "岗检表管理", businessType = BusinessType.DELETE)
161
-    @DeleteMapping("/{ids}")
162
+//    @DeleteMapping("/{ids}")
163
+    @GetMapping("/remove/{ids}")
162 164
     public AjaxResult remove(
163 165
             @ApiParam(name = "ids", value = "岗检表ids", required = true)
164 166
             @PathVariable Long[] ids) {
@@ -182,7 +184,8 @@ public class PostCheckedController extends BaseController {
182 184
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
183 185
     })
184 186
     @Log(title = "岗检表审核", businessType = BusinessType.UPDATE)
185
-    @PutMapping("/statusApprove")
187
+//    @PutMapping("/statusApprove")
188
+    @PostMapping("/statusApprove/edit")
186 189
     public AjaxResult statusApprove(String ids, Integer status, String reason) {
187 190
 
188 191
         // 判断审核的权限

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedItemsController.java

@@ -128,7 +128,8 @@ public class PostCheckedItemsController extends BaseController
128 128
     */
129 129
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedItems:edit')")
130 130
     @Log(title = "岗检表管理明细", businessType = BusinessType.UPDATE)
131
-    @PutMapping
131
+//    @PutMapping
132
+    @PostMapping("/edit")
132 133
     public AjaxResult edit(@RequestBody PostCheckedItems postCheckedItems)
133 134
     {
134 135
         return toAjax(postCheckedItemsService.updatePostCheckedItems(postCheckedItems));
@@ -143,7 +144,8 @@ public class PostCheckedItemsController extends BaseController
143 144
     */
144 145
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedItems:remove')")
145 146
     @Log(title = "岗检表管理明细", businessType = BusinessType.DELETE)
146
-	@DeleteMapping("/{ids}")
147
+//	@DeleteMapping("/{ids}")
148
+    @GetMapping("/remove/{ids}")
147 149
     public AjaxResult remove(@PathVariable Long[] ids)
148 150
     {
149 151
         return toAjax(postCheckedItemsService.deletePostCheckedItemsByIds(ids));

+ 20 - 10
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedProblemController.java

@@ -464,7 +464,8 @@ public class PostCheckedProblemController extends BaseController {
464 464
     })
465 465
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedProblem:edit')")
466 466
     @Log(title = "岗检问题表", businessType = BusinessType.UPDATE)
467
-    @PutMapping
467
+//    @PutMapping
468
+    @PostMapping("/edit")
468 469
     public AjaxResult edit(@RequestBody List<PostCheckedProblem> postCheckedProblemList) {
469 470
         return toAjax(postCheckedProblemService.updatePostCheckedProblem(postCheckedProblemList));
470 471
     }
@@ -476,7 +477,8 @@ public class PostCheckedProblemController extends BaseController {
476 477
 //    @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
477 478
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedProblem:remove')")
478 479
     @Log(title = "岗检问题表", businessType = BusinessType.DELETE)
479
-    @DeleteMapping("/{ids}")
480
+//    @DeleteMapping("/{ids}")
481
+    @GetMapping("/remove/{ids}")
480 482
     public AjaxResult remove(
481 483
             @ApiParam(name = "ids", value = "删除岗检问题ids", required = true)
482 484
             @PathVariable Long[] ids) {
@@ -496,7 +498,8 @@ public class PostCheckedProblemController extends BaseController {
496 498
             @ApiImplicitParam(name = "rectificationResponsibleUserId", value = "整改责任人ID", dataType = "Long", dataTypeClass = Long.class)
497 499
     })
498 500
     @Log(title = "指定方案填写人", businessType = BusinessType.UPDATE)
499
-    @PutMapping("/setRectificationResponsibleUserId")
501
+//    @PutMapping("/setRectificationResponsibleUserId")
502
+    @PostMapping("/setRectificationResponsibleUserId/edit")
500 503
 //    public AjaxResult setRectificationResponsibleUserId(Long id, Long rectificationResponsibleUserId) {
501 504
     public AjaxResult setRectificationResponsibleUserId(String ids, Long rectificationResponsibleUserId) {
502 505
         return toAjax(postCheckedProblemService.setRectificationResponsibleUserId(ids, rectificationResponsibleUserId));
@@ -521,7 +524,8 @@ public class PostCheckedProblemController extends BaseController {
521 524
             @ApiImplicitParam(name = "rectificationPeriod", value = "整改期限", dataType = "Date", dataTypeClass = Date.class),
522 525
     })
523 526
     @Log(title = "岗检问题整改责任人填写整改方案", businessType = BusinessType.UPDATE)
524
-    @PutMapping("/updateRectificationMeasure")
527
+//    @PutMapping("/updateRectificationMeasure")
528
+    @PostMapping("/updateRectificationMeasure/edit")
525 529
     public AjaxResult updateRectificationMeasure(Long id, String problemCause, Integer isImmediatelyCorrected, String rectificationMeasure, Date rectificationPeriod) {
526 530
         return toAjax(postCheckedProblemService.updateRectificationMeasure(id, problemCause, isImmediatelyCorrected, rectificationMeasure, rectificationPeriod));
527 531
     }
@@ -539,7 +543,8 @@ public class PostCheckedProblemController extends BaseController {
539 543
             @ApiImplicitParam(name = "specialityDepartmentReviewerId", value = "专业部门的审核人ID", dataType = "Long", dataTypeClass = Long.class)
540 544
     })
541 545
     @Log(title = "岗检问题整改责任人指定专业部门的审核人", businessType = BusinessType.UPDATE)
542
-    @PutMapping("/setSpecialityDepartmentReviewerId")
546
+//    @PutMapping("/setSpecialityDepartmentReviewerId")
547
+    @PostMapping("/setSpecialityDepartmentReviewerId/edit")
543 548
     public AjaxResult setSpecialityDepartmentReviewerId(Long id, Long specialityDepartmentReviewerId) {
544 549
         return toAjax(postCheckedProblemService.setSpecialityDepartmentReviewerId(id, specialityDepartmentReviewerId));
545 550
     }
@@ -559,7 +564,8 @@ public class PostCheckedProblemController extends BaseController {
559 564
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
560 565
     })
561 566
     @Log(title = "部门经理批量审核", businessType = BusinessType.UPDATE)
562
-    @PutMapping("/setDeptApproveTime")
567
+//    @PutMapping("/setDeptApproveTime")
568
+    @PostMapping("/setDeptApproveTime/edit")
563 569
 //    public AjaxResult setDeptApproveTime(Long id, Integer status, String reason) {
564 570
     public AjaxResult setDeptApproveTime(String ids, Integer status, String reason) {
565 571
         String errorMsg = "";
@@ -597,7 +603,8 @@ public class PostCheckedProblemController extends BaseController {
597 603
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
598 604
     })
599 605
     @Log(title = "审核2:专业部门审核人批量审核", businessType = BusinessType.UPDATE)
600
-    @PutMapping("/setSpecialityDepartmentReviewTime")
606
+//    @PutMapping("/setSpecialityDepartmentReviewTime")
607
+    @PostMapping("/setSpecialityDepartmentReviewTime/edit")
601 608
     public AjaxResult setSpecialityDepartmentReviewTime(String ids, Integer status, String reason) {
602 609
         int count = 0;
603 610
         String[] idArr = ids.split(",");
@@ -631,7 +638,8 @@ public class PostCheckedProblemController extends BaseController {
631 638
             @ApiImplicitParam(name = "rectificationCompletionImg", value = "整改完成图片磁盘路径", dataType = "String", dataTypeClass = String.class),
632 639
     })
633 640
     @Log(title = "实施整改", businessType = BusinessType.UPDATE)
634
-    @PutMapping("/updateRectificationCompletionImg")
641
+//    @PutMapping("/updateRectificationCompletionImg")
642
+    @PostMapping("/updateRectificationCompletionImg/edit")
635 643
     public AjaxResult updateRectificationCompletionImg(Long id, Integer isRectificationCompleted, Date rectificationCompletionTime, String rectificationCompletionImg) {
636 644
         return toAjax(postCheckedProblemService.updateRectificationCompletionImg(id, isRectificationCompleted, rectificationCompletionTime, rectificationCompletionImg));
637 645
     }
@@ -649,7 +657,8 @@ public class PostCheckedProblemController extends BaseController {
649 657
             @ApiImplicitParam(name = "reviewDepartmentReviewerId", value = "复查人ID", dataType = "Long", dataTypeClass = Long.class)
650 658
     })
651 659
     @Log(title = "岗检问题指定复查人", businessType = BusinessType.UPDATE)
652
-    @PutMapping("/setReviewDepartmentReviewerId")
660
+//    @PutMapping("/setReviewDepartmentReviewerId")
661
+    @PostMapping("/setReviewDepartmentReviewerId/edit")
653 662
     public AjaxResult setReviewDepartmentReviewerId(Long id, Long reviewDepartmentReviewerId) {
654 663
         return toAjax(postCheckedProblemService.setReviewDepartmentReviewerId(id, reviewDepartmentReviewerId));
655 664
     }
@@ -671,7 +680,8 @@ public class PostCheckedProblemController extends BaseController {
671 680
             @ApiImplicitParam(name = "reason", value = "未通过理由", dataType = "String", dataTypeClass = String.class),
672 681
     })
673 682
     @Log(title = "岗检问题复查部门审核人批量复查", businessType = BusinessType.UPDATE)
674
-    @PutMapping("/setReviewDepartmentReviewerTime")
683
+//    @PutMapping("/setReviewDepartmentReviewerTime")
684
+    @PostMapping("/setReviewDepartmentReviewerTime/edit")
675 685
     public AjaxResult setReviewDepartmentReviewerTime(String ids, Integer status, String reviewConclusion, String reason) {
676 686
         int count = 0;
677 687
         String[] idArr = ids.split(",");

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostCheckedReportController.java

@@ -183,7 +183,8 @@ public class PostCheckedReportController extends BaseController {
183 183
     })
184 184
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedReport:edit')")
185 185
     @Log(title = "岗检报告管理", businessType = BusinessType.UPDATE)
186
-    @PutMapping
186
+//    @PutMapping
187
+    @PostMapping("/edit")
187 188
     public AjaxResult edit(@RequestBody PostCheckedReport postCheckedReport) {
188 189
         return toAjax(postCheckedReportService.updatePostCheckedReport(postCheckedReport));
189 190
     }
@@ -195,7 +196,8 @@ public class PostCheckedReportController extends BaseController {
195 196
     @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
196 197
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckedReport:remove')")
197 198
     @Log(title = "岗检报告管理", businessType = BusinessType.DELETE)
198
-    @DeleteMapping("/{ids}")
199
+//    @DeleteMapping("/{ids}")
200
+    @GetMapping("/remove/{ids}")
199 201
     public AjaxResult remove(@PathVariable Long[] ids) {
200 202
         return toAjax(postCheckedReportService.deletePostCheckedReportByIds(ids));
201 203
     }

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostHighlightsController.java

@@ -120,7 +120,8 @@ public class PostHighlightsController extends BaseController {
120 120
     })
121 121
     @PreAuthorize("@ss.hasPermi('postCheck:postHighlights:edit')")
122 122
     @Log(title = "岗检亮点", businessType = BusinessType.UPDATE)
123
-    @PutMapping
123
+//    @PutMapping
124
+    @PostMapping("/edit")
124 125
     public AjaxResult edit(@RequestBody PostHighlights postHighlights) {
125 126
         return toAjax(postHighlightsService.updatePostHighlights(postHighlights));
126 127
     }
@@ -132,7 +133,8 @@ public class PostHighlightsController extends BaseController {
132 133
 //    @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
133 134
     @PreAuthorize("@ss.hasPermi('postCheck:postHighlights:remove')")
134 135
     @Log(title = "岗检亮点", businessType = BusinessType.DELETE)
135
-    @DeleteMapping("/{ids}")
136
+//    @DeleteMapping("/{ids}")
137
+    @GetMapping("/remove/{ids}")
136 138
     public AjaxResult remove(
137 139
             @ApiParam(name = "ids", value = "岗检亮点ids", required = true)
138 140
             @PathVariable Long[] ids) {

+ 6 - 3
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostListController.java

@@ -136,7 +136,8 @@ public class PostListController extends BaseController {
136 136
     @ApiOperation("修改岗位责任制清单")
137 137
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckList:edit')")
138 138
     @Log(title = "岗位责任制清单", businessType = BusinessType.UPDATE)
139
-    @PutMapping
139
+//    @PutMapping
140
+    @PostMapping("/edit")
140 141
     public AjaxResult edit(@RequestBody PostList postList) {
141 142
         return toAjax(postListService.updatePostList(postList));
142 143
     }
@@ -175,7 +176,8 @@ public class PostListController extends BaseController {
175 176
     @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
176 177
     @PreAuthorize("@ss.hasPermi('postCheck:postCheckList:remove')")
177 178
     @Log(title = "岗位责任制清单", businessType = BusinessType.DELETE)
178
-    @DeleteMapping("/{ids}")
179
+//    @DeleteMapping("/{ids}")
180
+    @GetMapping("/remove/{ids}")
179 181
     public AjaxResult remove(@PathVariable Long[] ids) {
180 182
         return toAjax(postListService.deletePostListByIds(ids));
181 183
     }
@@ -251,7 +253,8 @@ public class PostListController extends BaseController {
251 253
             @ApiImplicitParam(name = "reason", value = "未通过理由(驳回时必选)", dataType = "String", dataTypeClass = String.class),
252 254
     })
253 255
     @Log(title = "岗位责任制清单审核", businessType = BusinessType.UPDATE)
254
-    @PutMapping("/approve")
256
+//    @PutMapping("/approve")
257
+    @PostMapping("/approve/edit")
255 258
     public AjaxResult approve(Integer type, Long id, Integer status, String reason) {
256 259
         return toAjax(postListService.approve(type, id, status, reason));
257 260
     }

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanCheckUserController.java

@@ -103,7 +103,8 @@ public class PostPlanCheckUserController extends BaseController {
103 103
     @ApiOperation("修改岗检计划检查人员")
104 104
     @PreAuthorize("@ss.hasPermi('postCheck:planInfoUser:edit')")
105 105
     @Log(title = "岗检计划明细检查人表", businessType = BusinessType.UPDATE)
106
-    @PutMapping
106
+//    @PutMapping
107
+    @PostMapping("/edit")
107 108
     public AjaxResult edit(@RequestBody PostPlanCheckUser postPlanCheckUser) {
108 109
         return toAjax(postPlanInfoUserService.updatePostPlanInfoUser(postPlanCheckUser));
109 110
     }
@@ -114,7 +115,8 @@ public class PostPlanCheckUserController extends BaseController {
114 115
     @ApiOperation("删除岗检计划检查人员")
115 116
     @PreAuthorize("@ss.hasPermi('postCheck:planInfoUser:remove')")
116 117
     @Log(title = "岗检计划明细检查人表", businessType = BusinessType.DELETE)
117
-    @DeleteMapping("/{ids}")
118
+//    @DeleteMapping("/{ids}")
119
+    @GetMapping("/remove/{ids}")
118 120
     public AjaxResult remove(
119 121
             @ApiParam(name = "ids", value = "岗检计划检查人员ids", required = true)
120 122
             @PathVariable Long[] ids) {

+ 10 - 5
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanController.java

@@ -317,7 +317,8 @@ public class PostPlanController extends BaseController {
317 317
     */
318 318
     @PreAuthorize("@ss.hasPermi('postCheck:postPlan:edit')")
319 319
     @Log(title = "岗检计划", businessType = BusinessType.UPDATE)
320
-    @PutMapping
320
+//    @PutMapping
321
+    @PostMapping("/edit")
321 322
     public AjaxResult edit(@RequestBody PostPlan postPlan) {
322 323
         return toAjax(postPlanService.updatePostPlan(postPlan));
323 324
     }
@@ -329,7 +330,8 @@ public class PostPlanController extends BaseController {
329 330
 //    @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
330 331
     @PreAuthorize("@ss.hasPermi('postCheck:postPlan:remove')")
331 332
     @Log(title = "岗检计划", businessType = BusinessType.DELETE)
332
-    @DeleteMapping("/{ids}")
333
+//    @DeleteMapping("/{ids}")
334
+    @GetMapping("/remove/{ids}")
333 335
     public AjaxResult remove(
334 336
             @ApiParam(name = "ids", value = "岗检计划ids", required = true)
335 337
             @PathVariable Long[] ids) {
@@ -344,7 +346,8 @@ public class PostPlanController extends BaseController {
344 346
             @ApiImplicitParam(name = "reasonIcfa", value = "2-内控法务部审批-未通过理由", dataType = "String", dataTypeClass = String.class),
345 347
     })
346 348
     @Log(title = "岗检计划审核-Icfa", businessType = BusinessType.UPDATE)
347
-    @PutMapping("/approveIcfa")
349
+//    @PutMapping("/approveIcfa")
350
+    @PostMapping("/approveIcfa/edit")
348 351
     public AjaxResult approveIcfa(Long id, Integer statusIcfa, String reasonIcfa) {
349 352
         // 判断审核的权限
350 353
         LoginUser loginUser = SecurityUtils.getLoginUser();
@@ -375,7 +378,8 @@ public class PostPlanController extends BaseController {
375 378
 
376 379
     })
377 380
     @Log(title = "岗检计划审核-HR", businessType = BusinessType.UPDATE)
378
-    @PutMapping("/approveHr")
381
+//    @PutMapping("/approveHr")
382
+    @PostMapping("/approveHr/edit")
379 383
     public AjaxResult approveHr(Long id, Integer statusHr, String reasonHr) {
380 384
         // 判断审核的权限
381 385
         LoginUser loginUser = SecurityUtils.getLoginUser();
@@ -404,7 +408,8 @@ public class PostPlanController extends BaseController {
404 408
             @ApiImplicitParam(name = "id", value = "岗检计划ID", dataType = "Long", dataTypeClass = Long.class),
405 409
     })
406 410
     @Log(title = "岗检计划发布", businessType = BusinessType.UPDATE)
407
-    @PutMapping("/publish")
411
+//    @PutMapping("/publish")
412
+    @PostMapping("/publish/edit")
408 413
     public AjaxResult publish(Long id) {
409 414
 
410 415
 

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanInfoController.java

@@ -102,7 +102,8 @@ public class PostPlanInfoController extends BaseController {
102 102
     @ApiOperation("修改岗检计划明细表")
103 103
     @PreAuthorize("@ss.hasPermi('postCheck:postPlanInfo:edit')")
104 104
     @Log(title = "岗检计划明细表", businessType = BusinessType.UPDATE)
105
-    @PutMapping
105
+//    @PutMapping
106
+    @PostMapping("/edit")
106 107
     public AjaxResult edit(@RequestBody PostPlanInfo postPlanInfo) {
107 108
         return toAjax(postPlanInfoService.updatePostPlanInfo(postPlanInfo));
108 109
     }
@@ -111,7 +112,8 @@ public class PostPlanInfoController extends BaseController {
111 112
     @ApiOperation("删除岗检计划明细表")
112 113
     @PreAuthorize("@ss.hasPermi('postCheck:postPlanInfo:remove')")
113 114
     @Log(title = "岗检计划明细表", businessType = BusinessType.DELETE)
114
-    @DeleteMapping("/{ids}")
115
+//    @DeleteMapping("/{ids}")
116
+    @GetMapping("/remove/{ids}")
115 117
     public AjaxResult remove(
116 118
             @ApiParam(name = "ids", value = "岗检计划明细ids", required = true)
117 119
             @PathVariable Long[] ids) {

+ 5 - 6
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanJoinCheckedController.java

@@ -8,10 +8,7 @@ import com.ruoyi.common.constant.PostPlanEnum;
8 8
 import io.swagger.annotations.*;
9 9
 import org.springframework.security.access.prepost.PreAuthorize;
10 10
 import org.springframework.beans.factory.annotation.Autowired;
11
-import org.springframework.web.bind.annotation.GetMapping;
12
-import org.springframework.web.bind.annotation.PutMapping;
13
-import org.springframework.web.bind.annotation.RequestMapping;
14
-import org.springframework.web.bind.annotation.RestController;
11
+import org.springframework.web.bind.annotation.*;
15 12
 import com.ruoyi.common.annotation.Log;
16 13
 import com.ruoyi.common.core.controller.BaseController;
17 14
 import com.ruoyi.common.core.domain.AjaxResult;
@@ -72,7 +69,8 @@ public class PostPlanJoinCheckedController extends BaseController {
72 69
 
73 70
     })
74 71
     @Log(title = "岗检完成确认", businessType = BusinessType.UPDATE)
75
-    @PutMapping("/checked")
72
+//    @PutMapping("/checked")
73
+    @PostMapping("/checked/edit")
76 74
     public AjaxResult checked(Long planInfoId, String checkedUserName, Date checkedTime, String checkedImg) {
77 75
         return toAjax(postPlanJoinCheckedService.checked(planInfoId, checkedUserName, checkedTime, checkedImg));
78 76
     }
@@ -83,7 +81,8 @@ public class PostPlanJoinCheckedController extends BaseController {
83 81
             @ApiImplicitParam(name = "checkedImg", value = "检查表照片(图片上传后的相对路径)", dataType = "String", dataTypeClass = String.class),
84 82
     })
85 83
     @Log(title = "岗检完成确认后重新上传检查表照片", businessType = BusinessType.UPDATE)
86
-    @PutMapping("imgReUpload")
84
+//    @PutMapping("imgReUpload")
85
+    @PostMapping("/imgReUpload/edit")
87 86
     public AjaxResult imgReUpload(Long planInfoId, String checkedImg) {
88 87
         return toAjax(postPlanJoinCheckedService.imgReUpload(planInfoId, checkedImg));
89 88
     }

+ 8 - 4
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostProgrammeController.java

@@ -147,7 +147,8 @@ public class PostProgrammeController extends BaseController {
147 147
 
148 148
     @PreAuthorize("@ss.hasPermi('postCheck:programme:edit')")
149 149
     @Log(title = "岗检方案", businessType = BusinessType.UPDATE)
150
-    @PutMapping
150
+//    @PutMapping
151
+    @PostMapping("/edit")
151 152
     public AjaxResult edit(@RequestBody PostProgramme postProgramme) {
152 153
         return toAjax(postProgrammeService.updatePostProgramme(postProgramme));
153 154
     }
@@ -159,7 +160,8 @@ public class PostProgrammeController extends BaseController {
159 160
     @ApiImplicitParam(name = "ids", value = "Long类型的主键数组", dataType = "Long[]", dataTypeClass = Long[].class)
160 161
     @PreAuthorize("@ss.hasPermi('postCheck:programme:remove')")
161 162
     @Log(title = "岗检方案", businessType = BusinessType.DELETE)
162
-    @DeleteMapping("/{ids}")
163
+//    @DeleteMapping("/{ids}")
164
+    @GetMapping("/remove/{ids}")
163 165
     public AjaxResult remove(
164 166
             @ApiParam(name = "ids", value = "岗检方案ids", required = true)
165 167
             @PathVariable Long[] ids) {
@@ -174,7 +176,8 @@ public class PostProgrammeController extends BaseController {
174 176
             @ApiImplicitParam(name = "reasonIcfa", value = "2-内控法务部审批-未通过理由", dataType = "String", dataTypeClass = String.class),
175 177
     })
176 178
     @Log(title = "岗检方案审核-Icfa", businessType = BusinessType.UPDATE)
177
-    @PutMapping("/approveIcfa")
179
+//    @PutMapping("/approveIcfa")
180
+    @PostMapping("/approveIcfa/edit")
178 181
     public AjaxResult approveIcfa(Long id, Integer statusIcfa, String reasonIcfa) {
179 182
         // 判断审核的权限
180 183
         LoginUser loginUser = SecurityUtils.getLoginUser();
@@ -202,7 +205,8 @@ public class PostProgrammeController extends BaseController {
202 205
             @ApiImplicitParam(name = "reasonHr", value = "1-人力资源审批-未通过理由", dataType = "String", dataTypeClass = String.class),
203 206
     })
204 207
     @Log(title = "岗检方案审核-HR", businessType = BusinessType.UPDATE)
205
-    @PutMapping("/approveHr")
208
+//    @PutMapping("/approveHr")
209
+    @PostMapping("/approveHr/edit")
206 210
     public AjaxResult approveHr(Long id, Integer statusHr, String reasonHr) {
207 211
         LoginUser loginUser = SecurityUtils.getLoginUser();
208 212
         if (SecurityUtils.isAdmin(loginUser.getUserId())) {

+ 6 - 3
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostProgrammeTemplateController.java

@@ -90,7 +90,8 @@ public class PostProgrammeTemplateController extends BaseController {
90 90
     @ApiOperation("修改岗检方案模板")
91 91
     @PreAuthorize("@ss.hasPermi('postCheck:programmeTemplate:edit')")
92 92
     @Log(title = "岗检方案模板", businessType = BusinessType.UPDATE)
93
-    @PutMapping
93
+//    @PutMapping
94
+    @PostMapping("/edit")
94 95
     public AjaxResult edit(@RequestBody PostProgrammeTemplate postProgrammeTemplate) {
95 96
         return toAjax(postProgrammeTemplateService.updatePostProgrammeTemplate(postProgrammeTemplate));
96 97
     }
@@ -101,7 +102,8 @@ public class PostProgrammeTemplateController extends BaseController {
101 102
     @ApiOperation("删除岗检方案模板")
102 103
     @PreAuthorize("@ss.hasPermi('postCheck:programmeTemplate:remove')")
103 104
     @Log(title = "岗检方案模板", businessType = BusinessType.DELETE)
104
-    @DeleteMapping("/{ids}")
105
+//    @DeleteMapping("/{ids}")
106
+    @GetMapping("/remove/{ids}")
105 107
     public AjaxResult remove(
106 108
             @ApiParam(name = "ids", value = "岗检方案模板ids", required = true)
107 109
             @PathVariable Long[] ids) {
@@ -115,7 +117,8 @@ public class PostProgrammeTemplateController extends BaseController {
115 117
             @ApiImplicitParam(name = "status", value = "状态(1-启动;2-作废)", dataType = "Long", dataTypeClass = Long.class)
116 118
     })
117 119
     @Log(title = "岗检方案模板启用/禁用", businessType = BusinessType.UPDATE)
118
-    @PutMapping("/approve")
120
+//    @PutMapping("/approve")
121
+    @PostMapping("/approve/edit")
119 122
     public AjaxResult approveHr(Long id, Integer status) {
120 123
 
121 124
         int updateCount = postProgrammeTemplateService.approve(id, status);

+ 4 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamController.java

@@ -145,7 +145,8 @@ public class PostTeamController extends BaseController {
145 145
     @ApiOperation("修改岗检小组")
146 146
     @PreAuthorize("@ss.hasPermi('postCheck:team:edit')")
147 147
     @Log(title = "岗检小组", businessType = BusinessType.UPDATE)
148
-    @PutMapping
148
+//    @PutMapping
149
+    @PostMapping("/edit")
149 150
     public AjaxResult edit(@RequestBody PostTeam postTeam) {
150 151
         return toAjax(postTeamService.updatePostTeam(postTeam));
151 152
     }
@@ -156,7 +157,8 @@ public class PostTeamController extends BaseController {
156 157
     @ApiOperation("删除岗检小组")
157 158
     @PreAuthorize("@ss.hasPermi('postCheck:team:remove')")
158 159
     @Log(title = "岗检小组", businessType = BusinessType.DELETE)
159
-    @DeleteMapping("/{ids}")
160
+//    @DeleteMapping("/{ids}")
161
+    @GetMapping("/remove/{ids}")
160 162
     public AjaxResult remove(
161 163
             @ApiParam(name = "ids", value = "岗检小组ids", required = true)
162 164
             @PathVariable Long[] ids) {

+ 2 - 1
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamDeptController.java

@@ -100,7 +100,8 @@ public class PostTeamDeptController extends BaseController {
100 100
     @ApiOperation("删除岗检工作组关联部门")
101 101
 //    @PreAuthorize("@ss.hasPermi('postCheck:teamDept:remove')")
102 102
     @Log(title = "岗检工作组关联部门", businessType = BusinessType.DELETE)
103
-    @DeleteMapping("/{ids}")
103
+//    @DeleteMapping("/{ids}")
104
+    @GetMapping("/remove/{ids}")
104 105
     public AjaxResult remove(
105 106
             @ApiParam(name = "ids", value = "岗检工作组关联部门表ids", required = true)
106 107
             @PathVariable Long[] ids) {

+ 2 - 1
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostTeamUserController.java

@@ -100,7 +100,8 @@ public class PostTeamUserController extends BaseController {
100 100
     @ApiOperation("删除岗检小组关联成员")
101 101
 //    @PreAuthorize("@ss.hasPermi('postCheck:teamUser:remove')")
102 102
     @Log(title = "岗检小组关联成员", businessType = BusinessType.DELETE)
103
-    @DeleteMapping("/{ids}")
103
+//    @DeleteMapping("/{ids}")
104
+    @GetMapping("/remove/{ids}")
104 105
     public AjaxResult remove(@PathVariable Long[] ids) {
105 106
         return toAjax(postTeamUserService.deletePostTeamUserByIds(ids));
106 107
     }

+ 6 - 5
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/service/impl/PostProgrammeServiceImpl.java

@@ -131,10 +131,9 @@ public class PostProgrammeServiceImpl extends ServiceImpl<PostProgrammeMapper, P
131 131
      *
132 132
      * @param id 岗检方案主键
133 133
      * @return 结果
134
-    @Override
135
-    public int deletePostProgrammeById(Long id) {
136
-        return postProgrammeMapper.deletePostProgrammeById(id);
137
-    }
134
+     @Override public int deletePostProgrammeById(Long id) {
135
+     return postProgrammeMapper.deletePostProgrammeById(id);
136
+     }
138 137
      */
139 138
 
140 139
 
@@ -176,7 +175,9 @@ public class PostProgrammeServiceImpl extends ServiceImpl<PostProgrammeMapper, P
176 175
         // PostProgrammeEnum.STATUS_ICFA_WAIT
177 176
         //审核
178 177
         if (statusIcfa == PostProgrammeEnum.STATUS_ICFA_PASS.getValue()) {
179
-            throw new BaseException("已审核通过的记录不允许重复操作,请刷新页面再试!");
178
+            if (statusIcfaDB == PostProgrammeEnum.STATUS_ICFA_PASS.getValue()) {
179
+                throw new BaseException("已审核通过的记录不允许重复操作,请刷新页面再试!");
180
+            }
180 181
         }
181 182
         //驳回
182 183
         else if (statusIcfa == PostProgrammeEnum.STATUS_ICFA_BACK.getValue()) {

+ 8 - 4
ruoyi-quartz/src/main/java/com/ruoyi/quartz/controller/SysJobController.java

@@ -102,7 +102,8 @@ public class SysJobController extends BaseController {
102 102
     @ApiOperation("修改定时任务")
103 103
     @PreAuthorize("@ss.hasPermi('monitor:job:edit')")
104 104
     @Log(title = "定时任务", businessType = BusinessType.UPDATE)
105
-    @PutMapping
105
+//    @PutMapping
106
+    @PostMapping("/edit")
106 107
     public AjaxResult edit(@RequestBody SysJob job) throws SchedulerException, TaskException {
107 108
         if (!CronUtils.isValid(job.getCronExpression())) {
108 109
             return error("修改任务'" + job.getJobName() + "'失败,Cron表达式不正确");
@@ -125,7 +126,8 @@ public class SysJobController extends BaseController {
125 126
     @ApiOperation("定时任务状态修改")
126 127
     @PreAuthorize("@ss.hasPermi('monitor:job:changeStatus')")
127 128
     @Log(title = "定时任务", businessType = BusinessType.UPDATE)
128
-    @PutMapping("/changeStatus")
129
+//    @PutMapping("/changeStatus")
130
+    @PostMapping("/changeStatus/edit")
129 131
     public AjaxResult changeStatus(@RequestBody SysJob job) throws SchedulerException {
130 132
         SysJob newJob = jobService.selectJobById(job.getJobId());
131 133
         newJob.setStatus(job.getStatus());
@@ -136,7 +138,8 @@ public class SysJobController extends BaseController {
136 138
     @ApiOperation("定时任务立即执行一次")
137 139
     @PreAuthorize("@ss.hasPermi('monitor:job:changeStatus')")
138 140
     @Log(title = "定时任务", businessType = BusinessType.UPDATE)
139
-    @PutMapping("/run")
141
+//    @PutMapping("/run")
142
+    @PostMapping("/run/edit")
140 143
     public AjaxResult run(@RequestBody SysJob job) throws SchedulerException {
141 144
         boolean result = jobService.run(job);
142 145
         return result ? success() : error("任务不存在或已过期!");
@@ -146,7 +149,8 @@ public class SysJobController extends BaseController {
146 149
     @ApiOperation("删除定时任务")
147 150
     @PreAuthorize("@ss.hasPermi('monitor:job:remove')")
148 151
     @Log(title = "定时任务", businessType = BusinessType.DELETE)
149
-    @DeleteMapping("/{jobIds}")
152
+//    @DeleteMapping("/{jobIds}")
153
+    @GetMapping("/remove/{jobIds}")
150 154
     public AjaxResult remove(
151 155
             @ApiParam(name = "id", value = "定时任务id", required = true)
152 156
             @PathVariable Long[] jobIds) throws SchedulerException, TaskException {

+ 4 - 2
ruoyi-quartz/src/main/java/com/ruoyi/quartz/controller/SysJobLogController.java

@@ -72,7 +72,8 @@ public class SysJobLogController extends BaseController
72 72
      */
73 73
     @PreAuthorize("@ss.hasPermi('monitor:job:remove')")
74 74
     @Log(title = "定时任务调度日志", businessType = BusinessType.DELETE)
75
-    @DeleteMapping("/{jobLogIds}")
75
+//    @DeleteMapping("/{jobLogIds}")
76
+    @GetMapping("/remove/{jobLogIds}")
76 77
     public AjaxResult remove(@PathVariable Long[] jobLogIds)
77 78
     {
78 79
         return toAjax(jobLogService.deleteJobLogByIds(jobLogIds));
@@ -83,7 +84,8 @@ public class SysJobLogController extends BaseController
83 84
      */
84 85
     @PreAuthorize("@ss.hasPermi('monitor:job:remove')")
85 86
     @Log(title = "调度日志", businessType = BusinessType.CLEAN)
86
-    @DeleteMapping("/clean")
87
+//    @DeleteMapping("/clean")
88
+    @GetMapping("/remove/clean")
87 89
     public AjaxResult clean()
88 90
     {
89 91
         jobLogService.cleanJobLog();