Browse Source

Merge remote-tracking branch 'origin/master'

csg6 10 months ago
parent
commit
4d7506bcf6

+ 4 - 0
ruoyi-common/src/main/java/com/ruoyi/common/constant/PostPlanEnum.java

@@ -16,6 +16,10 @@ public enum PostPlanEnum {
16
     STATUS_HR_PASS("通过;", 3),
16
     STATUS_HR_PASS("通过;", 3),
17
     STATUS_HR_BACK("驳回;", 4),
17
     STATUS_HR_BACK("驳回;", 4),
18
 
18
 
19
+    // 流转步骤
20
+    STEP_HR("人力资源", 2),
21
+    STEP_ICFA("内控法务", 1),
22
+    STEP_SCHEME("方案入档",3),
19
 
23
 
20
     //status_icfa 2-内控法务部审批-状态:1-待审核;3-通过;4-驳回;
24
     //status_icfa 2-内控法务部审批-状态:1-待审核;3-通过;4-驳回;
21
     STATUS_ICFA_WAIT("待审核", 1),
25
     STATUS_ICFA_WAIT("待审核", 1),

+ 7 - 6
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostAssessmentRulesController.java

@@ -5,6 +5,7 @@ import java.util.Date;
5
 import java.util.List;
5
 import java.util.List;
6
 import javax.servlet.http.HttpServletResponse;
6
 import javax.servlet.http.HttpServletResponse;
7
 
7
 
8
+import com.ruoyi.common.constant.HttpStatus;
8
 import com.ruoyi.common.core.domain.entity.SysDept;
9
 import com.ruoyi.common.core.domain.entity.SysDept;
9
 import com.ruoyi.common.core.domain.model.LoginUser;
10
 import com.ruoyi.common.core.domain.model.LoginUser;
10
 import com.ruoyi.common.enums.DeptCode;
11
 import com.ruoyi.common.enums.DeptCode;
@@ -188,12 +189,12 @@ public class PostAssessmentRulesController extends BaseController
188
         // 当前登录用户的部门id 查询岗位id是否在内
189
         // 当前登录用户的部门id 查询岗位id是否在内
189
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
190
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
190
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
191
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
191
-            return error("审核权限有误,请联系管理员!");
192
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
192
         }
193
         }
193
         // 判断岗位是否在权限范围内
194
         // 判断岗位是否在权限范围内
194
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
195
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
195
         if (sysPost.getPostLevel() != 1) {
196
         if (sysPost.getPostLevel() != 1) {
196
-            return error("审核权限有误,请联系管理员!");
197
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
197
         }
198
         }
198
 
199
 
199
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));
200
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));
@@ -216,12 +217,12 @@ public class PostAssessmentRulesController extends BaseController
216
         // 当前登录用户的部门id 查询岗位id是否在内
217
         // 当前登录用户的部门id 查询岗位id是否在内
217
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
218
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
218
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
219
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
219
-            return error("审核权限有误,请联系管理员!");
220
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
220
         }
221
         }
221
         // 判断岗位是否在权限范围内
222
         // 判断岗位是否在权限范围内
222
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
223
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
223
         if (sysPost.getPostLevel() != 1) {
224
         if (sysPost.getPostLevel() != 1) {
224
-            return error("审核权限有误,请联系管理员!");
225
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
225
         }
226
         }
226
 
227
 
227
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));
228
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));
@@ -243,12 +244,12 @@ public class PostAssessmentRulesController extends BaseController
243
         // 当前登录用户的部门id 查询岗位id是否在内
244
         // 当前登录用户的部门id 查询岗位id是否在内
244
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
245
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
245
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
246
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
246
-            return error("审核权限有误,请联系管理员!");
247
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
247
         }
248
         }
248
         // 判断岗位是否在权限范围内
249
         // 判断岗位是否在权限范围内
249
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
250
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
250
         if (sysPost.getPostLevel() != 1) {
251
         if (sysPost.getPostLevel() != 1) {
251
-            return error("审核权限有误,请联系管理员!");
252
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
252
         }
253
         }
253
 
254
 
254
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));
255
         return toAjax(postAssessmentRulesService.statusApprove(id, status,  statusReason));

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

@@ -4,6 +4,7 @@ import java.util.Date;
4
 import java.util.List;
4
 import java.util.List;
5
 import javax.servlet.http.HttpServletResponse;
5
 import javax.servlet.http.HttpServletResponse;
6
 
6
 
7
+import com.ruoyi.common.constant.HttpStatus;
7
 import com.ruoyi.common.core.domain.entity.SysDept;
8
 import com.ruoyi.common.core.domain.entity.SysDept;
8
 import com.ruoyi.common.core.domain.model.LoginUser;
9
 import com.ruoyi.common.core.domain.model.LoginUser;
9
 import com.ruoyi.common.enums.DeptCode;
10
 import com.ruoyi.common.enums.DeptCode;
@@ -232,12 +233,12 @@ public class PostCheckedReportController extends BaseController
232
         // 当前登录用户的部门id 查询岗位id是否在内
233
         // 当前登录用户的部门id 查询岗位id是否在内
233
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
234
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
234
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
235
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
235
-            return error("审核权限有误,请联系管理员!");
236
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
236
         }
237
         }
237
         // 判断岗位是否在权限范围内
238
         // 判断岗位是否在权限范围内
238
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
239
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
239
         if (sysPost.getPostLevel() != 1) {
240
         if (sysPost.getPostLevel() != 1) {
240
-            return error("审核权限有误,请联系管理员!");
241
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
241
         }
242
         }
242
         return toAjax(postCheckedReportService.statusApprove(id, status,  statusReason));
243
         return toAjax(postCheckedReportService.statusApprove(id, status,  statusReason));
243
     }
244
     }

+ 61 - 0
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostPlanController.java

@@ -4,8 +4,18 @@ import java.util.List;
4
 import javax.servlet.http.HttpServletResponse;
4
 import javax.servlet.http.HttpServletResponse;
5
 
5
 
6
 import com.baomidou.mybatisplus.annotation.TableField;
6
 import com.baomidou.mybatisplus.annotation.TableField;
7
+import com.ruoyi.common.constant.HttpStatus;
8
+import com.ruoyi.common.constant.PostPlanEnum;
9
+import com.ruoyi.common.core.domain.entity.SysDept;
10
+import com.ruoyi.common.core.domain.model.LoginUser;
11
+import com.ruoyi.common.enums.DeptCode;
12
+import com.ruoyi.common.utils.SecurityUtils;
7
 import com.ruoyi.postCheck.domain.PostPlanCheckUser;
13
 import com.ruoyi.postCheck.domain.PostPlanCheckUser;
8
 import com.ruoyi.postCheck.domain.PostPlanInfo;
14
 import com.ruoyi.postCheck.domain.PostPlanInfo;
15
+import com.ruoyi.postCheck.domain.PostProgramme;
16
+import com.ruoyi.system.domain.SysPost;
17
+import com.ruoyi.system.service.ISysDeptService;
18
+import com.ruoyi.system.service.ISysPostService;
9
 import io.swagger.annotations.*;
19
 import io.swagger.annotations.*;
10
 import org.springframework.security.access.prepost.PreAuthorize;
20
 import org.springframework.security.access.prepost.PreAuthorize;
11
 import org.springframework.beans.factory.annotation.Autowired;
21
 import org.springframework.beans.factory.annotation.Autowired;
@@ -36,9 +46,16 @@ import com.ruoyi.common.core.page.TableDataInfo;
36
 @RestController
46
 @RestController
37
 @RequestMapping("/postCheck/postPlan")
47
 @RequestMapping("/postCheck/postPlan")
38
 public class PostPlanController extends BaseController {
48
 public class PostPlanController extends BaseController {
49
+
39
     @Autowired
50
     @Autowired
40
     private IPostPlanService postPlanService;
51
     private IPostPlanService postPlanService;
41
 
52
 
53
+    @Autowired
54
+    private ISysDeptService sysDeptService;
55
+
56
+    @Autowired
57
+    private ISysPostService sysPostService;
58
+
42
     /**
59
     /**
43
      * 查询岗检计划列表
60
      * 查询岗检计划列表
44
      */
61
      */
@@ -202,6 +219,25 @@ public class PostPlanController extends BaseController {
202
     @Log(title = "岗检计划审核-Icfa", businessType = BusinessType.UPDATE)
219
     @Log(title = "岗检计划审核-Icfa", businessType = BusinessType.UPDATE)
203
     @PutMapping("/approveIcfa")
220
     @PutMapping("/approveIcfa")
204
     public AjaxResult approveIcfa(Long id, Integer statusIcfa, String reasonIcfa) {
221
     public AjaxResult approveIcfa(Long id, Integer statusIcfa, String reasonIcfa) {
222
+        // 判断当前状态
223
+        PostPlan postPlan = postPlanService.selectPostPlanById(id);
224
+        // 审核过得不在审核
225
+        if (postPlan.getStatusIcfa() == PostPlanEnum.STATUS_ICFA_PASS.getValue()) {
226
+            return AjaxResult.error("审核失败,请勿重复审核!");
227
+        }
228
+        // 判断审核的权限
229
+        LoginUser loginUser = SecurityUtils.getLoginUser();
230
+        // 当前登录用户的部门id 查询岗位id是否在内
231
+        SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
232
+        if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
233
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
234
+        }
235
+        // 判断岗位是否在权限范围内
236
+        SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
237
+        if (sysPost.getPostLevel() != 1) {
238
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
239
+        }
240
+
205
         return toAjax(postPlanService.approveIcfa(id, statusIcfa, reasonIcfa));
241
         return toAjax(postPlanService.approveIcfa(id, statusIcfa, reasonIcfa));
206
     }
242
     }
207
 
243
 
@@ -217,6 +253,31 @@ public class PostPlanController extends BaseController {
217
     @Log(title = "岗检计划审核-HR", businessType = BusinessType.UPDATE)
253
     @Log(title = "岗检计划审核-HR", businessType = BusinessType.UPDATE)
218
     @PutMapping("/approveHr")
254
     @PutMapping("/approveHr")
219
     public AjaxResult approveHr(Long id, Integer statusHr, String reasonHr) {
255
     public AjaxResult approveHr(Long id, Integer statusHr, String reasonHr) {
256
+        // 判断当前状态
257
+        PostPlan postPlan = postPlanService.selectPostPlanById(id);
258
+        // 审核过得不在审核
259
+        if (postPlan.getStatusHr() == PostPlanEnum.STATUS_HR_PASS.getValue()) {
260
+            return AjaxResult.error( "审核失败,请勿重复审核!");
261
+        }
262
+        // 判断顺序
263
+        if (postPlan.getStatusIcfa() != PostPlanEnum.STATUS_ICFA_PASS.getValue()
264
+                && postPlan.getStatus() != PostPlanEnum.STATUS_ING.getValue()) {
265
+            return AjaxResult.error(HttpStatus.WARN,"审核失败,审核流程有误!!");
266
+        }
267
+        // 判断审核的权限
268
+        LoginUser loginUser = SecurityUtils.getLoginUser();
269
+        // 当前登录用户的部门id 查询岗位id是否在内
270
+        SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
271
+        if (!sysDept.getDeptCode().equals(DeptCode.DEPT_HR.getCode())) {
272
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
273
+        }
274
+
275
+        // 判断岗位是否在权限范围内
276
+        SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
277
+        if (sysPost.getPostLevel() != 1) {
278
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
279
+        }
280
+
220
         return toAjax(postPlanService.approveHr(id, statusHr, reasonHr));
281
         return toAjax(postPlanService.approveHr(id, statusHr, reasonHr));
221
     }
282
     }
222
 
283
 

+ 13 - 10
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/controller/PostProgrammeController.java

@@ -5,6 +5,8 @@ import java.util.List;
5
 import java.util.Optional;
5
 import java.util.Optional;
6
 import javax.servlet.http.HttpServletResponse;
6
 import javax.servlet.http.HttpServletResponse;
7
 
7
 
8
+import com.ruoyi.common.constant.HttpStatus;
9
+import com.ruoyi.common.constant.PostProgrammeEnum;
8
 import com.ruoyi.common.core.domain.entity.SysDept;
10
 import com.ruoyi.common.core.domain.entity.SysDept;
9
 import com.ruoyi.common.core.domain.model.LoginUser;
11
 import com.ruoyi.common.core.domain.model.LoginUser;
10
 import com.ruoyi.common.enums.DeptCode;
12
 import com.ruoyi.common.enums.DeptCode;
@@ -208,21 +210,21 @@ public class PostProgrammeController extends BaseController {
208
         PostProgramme postProgramme = postProgrammeService.selectPostProgrammeById(id);
210
         PostProgramme postProgramme = postProgrammeService.selectPostProgrammeById(id);
209
         // 审核过得不在审核
211
         // 审核过得不在审核
210
 
212
 
211
-        if (postProgramme.getStatusHr() == 3) {
212
-            return error("审核失败,请勿重复审核!");
213
+        if (postProgramme.getStatusHr() == PostProgrammeEnum.STATUS_HR_PASS.getValue()) {
214
+            return AjaxResult.error("审核失败,请勿重复审核!");
213
         }
215
         }
214
         // 判断审核的权限
216
         // 判断审核的权限
215
         LoginUser loginUser = SecurityUtils.getLoginUser();
217
         LoginUser loginUser = SecurityUtils.getLoginUser();
216
         // 当前登录用户的部门id 查询岗位id是否在内
218
         // 当前登录用户的部门id 查询岗位id是否在内
217
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
219
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
218
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_HR.getCode())) {
220
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_HR.getCode())) {
219
-            return error("审核权限有误,请联系管理员!");
221
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
220
         }
222
         }
221
 
223
 
222
         // 判断岗位是否在权限范围内
224
         // 判断岗位是否在权限范围内
223
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
225
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
224
         if (sysPost.getPostLevel() != 1) {
226
         if (sysPost.getPostLevel() != 1) {
225
-            return error("审核权限有误,请联系管理员!");
227
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
226
         }
228
         }
227
         return toAjax(postProgrammeService.approveHr(id, statusHr, reasonHr));
229
         return toAjax(postProgrammeService.approveHr(id, statusHr, reasonHr));
228
     }
230
     }
@@ -240,24 +242,25 @@ public class PostProgrammeController extends BaseController {
240
         // 判断当前状态
242
         // 判断当前状态
241
         PostProgramme postProgramme = postProgrammeService.selectPostProgrammeById(id);
243
         PostProgramme postProgramme = postProgrammeService.selectPostProgrammeById(id);
242
         // 审核过得不在审核
244
         // 审核过得不在审核
243
-        if (postProgramme.getStatusHr() != 3) {
244
-            return error("审核失败,审核流程有误!!");
245
+        if (postProgramme.getStatusHr() != PostProgrammeEnum.STATUS_PASS.getValue()
246
+                && postProgramme.getStatus() == PostProgrammeEnum.STATUS_ING.getValue()) {
247
+            return AjaxResult.error(HttpStatus.WARN,"审核失败,审核流程有误!!");
245
         }
248
         }
246
 
249
 
247
-        if (postProgramme.getStatusIcfa() == 3) {
248
-            return error("审核失败,请勿重复审核!");
250
+        if (postProgramme.getStatusIcfa() == PostProgrammeEnum.STATUS_ICFA_PASS.getValue()) {
251
+            return AjaxResult.error("审核失败,请勿重复审核!");
249
         }
252
         }
250
         // 判断审核的权限
253
         // 判断审核的权限
251
         LoginUser loginUser = SecurityUtils.getLoginUser();
254
         LoginUser loginUser = SecurityUtils.getLoginUser();
252
         // 当前登录用户的部门id 查询岗位id是否在内
255
         // 当前登录用户的部门id 查询岗位id是否在内
253
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
256
         SysDept sysDept = sysDeptService.selectDeptById(loginUser.getDeptId());
254
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
257
         if (!sysDept.getDeptCode().equals(DeptCode.DEPT_ICFA.getCode())) {
255
-            return error("审核权限有误,请联系管理员!");
258
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
256
         }
259
         }
257
         // 判断岗位是否在权限范围内
260
         // 判断岗位是否在权限范围内
258
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
261
         SysPost sysPost = sysPostService.selectPostByDeptId(loginUser.getDeptId());
259
         if (sysPost.getPostLevel() != 1) {
262
         if (sysPost.getPostLevel() != 1) {
260
-            return error("审核权限有误,请联系管理员!");
263
+            return AjaxResult.error(HttpStatus.FORBIDDEN, "没有权限,请联系管理员授权");
261
         }
264
         }
262
 
265
 
263
         return toAjax(postProgrammeService.approveIcfa(id, statusIcfa, reasonIcfa));
266
         return toAjax(postProgrammeService.approveIcfa(id, statusIcfa, reasonIcfa));

+ 5 - 0
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/domain/PostPlan.java

@@ -161,4 +161,9 @@ public class PostPlan extends BaseEntity {
161
     @TableField(exist = false)
161
     @TableField(exist = false)
162
     private String checkedPostNames;
162
     private String checkedPostNames;
163
 //    =======================页面显示值===============
163
 //    =======================页面显示值===============
164
+
165
+    @ApiModelProperty("步骤:0-初始状态;1-内控法务部;2-人力资源审核后;3-方案入档")
166
+    @TableField(value = "step")
167
+    private Integer step;
168
+
164
 }
169
 }

+ 5 - 2
ruoyi-postcheck/src/main/java/com/ruoyi/postCheck/service/impl/PostPlanServiceImpl.java

@@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
6
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
6
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
7
 import com.ruoyi.common.constant.DeptConstants;
7
 import com.ruoyi.common.constant.DeptConstants;
8
 import com.ruoyi.common.constant.PostPlanEnum;
8
 import com.ruoyi.common.constant.PostPlanEnum;
9
+import com.ruoyi.common.constant.PostProgrammeEnum;
9
 import com.ruoyi.common.utils.SecurityUtils;
10
 import com.ruoyi.common.utils.SecurityUtils;
10
 import com.ruoyi.postCheck.domain.PostAssessmentRating;
11
 import com.ruoyi.postCheck.domain.PostAssessmentRating;
11
 import com.ruoyi.postCheck.domain.PostPlan;
12
 import com.ruoyi.postCheck.domain.PostPlan;
@@ -237,6 +238,7 @@ public class PostPlanServiceImpl extends ServiceImpl<PostPlanMapper, PostPlan> i
237
         data.setReasonIcfa(reasonIcfa);
238
         data.setReasonIcfa(reasonIcfa);
238
 
239
 
239
         if (statusIcfa == PostPlanEnum.STATUS_ICFA_PASS.getValue()) {
240
         if (statusIcfa == PostPlanEnum.STATUS_ICFA_PASS.getValue()) {
241
+            data.setStep(PostPlanEnum.STEP_ICFA.getValue());
240
             data.setStatus(PostPlanEnum.STATUS_ING.getValue());//审核中
242
             data.setStatus(PostPlanEnum.STATUS_ING.getValue());//审核中
241
         } else {
243
         } else {
242
             data.setStatus(PostPlanEnum.STATUS_BACK.getValue());//驳回
244
             data.setStatus(PostPlanEnum.STATUS_BACK.getValue());//驳回
@@ -274,11 +276,12 @@ public class PostPlanServiceImpl extends ServiceImpl<PostPlanMapper, PostPlan> i
274
         data.setReasonHr(reasonHr);
276
         data.setReasonHr(reasonHr);
275
 
277
 
276
         data.setStatus(statusHr);//最终审核结果
278
         data.setStatus(statusHr);//最终审核结果
277
-        // 初始化岗检考核排名
278
 
279
 
279
-        if(statusHr==3){
280
+        if(statusHr==PostPlanEnum.STATUS_ICFA_PASS.getValue()){
281
+            data.setStep(PostPlanEnum.STEP_HR.getValue());
280
             // 如果审核通过开始初始化岗检排名表
282
             // 如果审核通过开始初始化岗检排名表
281
             initializationPostAssessmentRating(id);
283
             initializationPostAssessmentRating(id);
284
+
282
         }
285
         }
283
         return postPlanMapper.updatePostPlan(data);
286
         return postPlanMapper.updatePostPlan(data);
284
     }
287
     }

+ 2 - 0
ruoyi-postcheck/src/main/resources/mapper/postCheck/PostPlanMapper.xml

@@ -30,6 +30,7 @@
30
         <result property="statusUserId"    column="status_user_id"    />
30
         <result property="statusUserId"    column="status_user_id"    />
31
         <result property="statusIcfaUserId"    column="status_icfa_user_id"    />
31
         <result property="statusIcfaUserId"    column="status_icfa_user_id"    />
32
         <result property="statusHrUserId"    column="status_hr_user_id"    />
32
         <result property="statusHrUserId"    column="status_hr_user_id"    />
33
+        <result property="step"    column="step"    />
33
     </resultMap>
34
     </resultMap>
34
 
35
 
35
     <sql id="selectPostPlanVo">
36
     <sql id="selectPostPlanVo">
@@ -182,6 +183,7 @@
182
             <if test="statusUserId != null">status_user_id = #{statusUserId},</if>
183
             <if test="statusUserId != null">status_user_id = #{statusUserId},</if>
183
             <if test="statusIcfaUserId != null">status_icfa_user_id = #{statusIcfaUserId},</if>
184
             <if test="statusIcfaUserId != null">status_icfa_user_id = #{statusIcfaUserId},</if>
184
             <if test="statusHrUserId != null">status_hr_user_id = #{statusHrUserId},</if>
185
             <if test="statusHrUserId != null">status_hr_user_id = #{statusHrUserId},</if>
186
+            <if test="step != null">step = #{step},</if>
185
         </trim>
187
         </trim>
186
         where id = #{id}
188
         where id = #{id}
187
     </update>
189
     </update>