Browse Source

驳回判断

hanqingsong 4 months ago
parent
commit
05c47db621

+ 9 - 4
unis-plugin/unis-plugin-biz/src/main/java/com/unis/lawEnforcementSupervision/modular/lesJointInspectionTask/service/impl/LesJointInspectionTaskServiceImpl.java

@@ -179,10 +179,15 @@ public class LesJointInspectionTaskServiceImpl extends ServiceImpl<LesJointInspe
179 179
         // 状态 0:保存状态;1:发布(申请中);2:审核通过;3:驳回
180 180
         Integer status = lesJointInspectionTask.getStatus();
181 181
         if (1 == status) {
182
-            // 添加审批(状态 0:待审核;1:已审核;2:驳回)
183
-            AuditRequest request = this.addAuditRequest(lesJointInspectionTask);
184
-            // 添加审批流程记录
185
-            this.addAuditRecord(lesJointInspectionTask, request.getId(), 0);
182
+            // 判断驳回在提交
183
+            if (StringUtils.isEmpty(lesJointInspectionTask.getId())) {
184
+                // 添加审批(状态 0:待审核;1:已审核;2:驳回)
185
+                AuditRequest request = this.addAuditRequest(lesJointInspectionTask);
186
+                // 添加审批流程记录
187
+                this.addAuditRecord(lesJointInspectionTask, request.getId(), 0);
188
+            } else {
189
+                this.editAuditRequest(lesJointInspectionTask, 0);
190
+            }
186 191
         } else if (2 == status) {
187 192
             this.editAuditRequest(lesJointInspectionTask, 1);
188 193
         } else if (3 == status) {