Bladeren bron

代码修正

wangliang 1 jaar geleden
bovenliggende
commit
3336af4a47

+ 10 - 9
sop-business/src/main/java/com/qmth/sop/business/service/impl/TBSopInfoServiceImpl.java

@@ -759,7 +759,8 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
         String assistantEngineerUserIds = null;
         List<FlowFormWidgetResult> formProperty = flowTaskResult.getFormProperty();
         for (FlowFormWidgetResult f : formProperty) {
-            if (f.getFormId().contains(SystemConstant.REGION_USER_ID) && Objects.nonNull(f.getValue()) && !Objects.equals(f.getValue(), "{\"value\":null}")) {
+            if (f.getFormId().contains(SystemConstant.REGION_USER_ID) && Objects.nonNull(f.getValue())
+                    && !Objects.equals(f.getValue(), "{\"value\":null}")) {
                 JSONObject jsonObject = JSONObject.parseObject(f.getValue());
                 String value = jsonObject.getString(SystemConstant.VALUE);
                 regionUserId = Long.parseLong(value);
@@ -1253,8 +1254,7 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
         flowResult.setSetupMap(setupMap);
         tfCustomFlowEntity.updateInfo(sysUser.getId());
         tfCustomFlowEntity.setFlowProcessVar(JacksonUtil.parseJson(flowResult));
-        //        if (tfFlowApprove.getStatus() != FlowStatusEnum.FINISH && tfFlowApprove.getStatus() != FlowStatusEnum.END) {
-        if (tfFlowApprove.getStatus() != FlowStatusEnum.END) {
+        if (tfFlowApprove.getStatus() != FlowStatusEnum.FINISH && tfFlowApprove.getStatus() != FlowStatusEnum.END) {
             Map<String, Object> map = new HashMap<>();
             CrmProjectResult crmProjectResult = tbCrmService.findCrmProjectBySopNoOrCrmNo(tfCustomFlowEntity.getCode(),
                     tfCustomFlowEntity.getCrmNo());
@@ -1274,13 +1274,13 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
             map.put(SystemConstant.SOURCE, "save");
             tbSopInfoService.saveJobRemind(map);
 
-            if (tfCustomFlow.getType() == TFCustomTypeEnum.OFFICE_SOP_FLOW && (tfFlowApprove.getSetup().intValue() >= 4
-                    || tfFlowApprove.getSetup().intValue() == 0)) {
+            if (tfCustomFlow.getType() == TFCustomTypeEnum.OFFICE_SOP_FLOW
+                    && tfFlowApprove.getSetup().intValue() >= 4) {
                 tbSopInfoService.sopDeviceInOutSave(map, 4);
-            } else if (tfCustomFlow.getType() == TFCustomTypeEnum.CLOUD_MARK_SOP_FLOW && (
-                    tfFlowApprove.getSetup().intValue() >= 4 || tfFlowApprove.getSetup().intValue() == 0)) {
+            } else if (tfCustomFlow.getType() == TFCustomTypeEnum.CLOUD_MARK_SOP_FLOW
+                    && tfFlowApprove.getSetup().intValue() >= 4) {
                 tbSopInfoService.sopDeviceInOutSave(map, 4);
-                if (tfFlowApprove.getSetup().intValue() > 5 || tfFlowApprove.getSetup().intValue() == 0) {
+                if (tfFlowApprove.getSetup().intValue() > 5) {
                     FlowTaskResult flowTaskResultDeviceOut = this.getFormProperties(tfCustomFlowEntity, 4);
                     tbDeviceDeliveryService.updateStatusBySop(flowTaskResultDeviceOut, DeviceDeliveryStatusEnum.RECEIVE,
                             sysUser.getId());
@@ -1342,7 +1342,8 @@ public class TBSopInfoServiceImpl extends ServiceImpl<TBSopInfoMapper, TBSopInfo
         Long processLimitedTime = null;
         List<FlowFormWidgetResult> formProperty = flowTaskResult.getFormProperty();
         for (FlowFormWidgetResult f : formProperty) {
-            if (f.getFormId().contains(fieldId) && Objects.nonNull(f.getValue()) && !Objects.equals(f.getValue(), "{\"value\":null}")) {
+            if (f.getFormId().contains(fieldId) && Objects.nonNull(f.getValue()) && !Objects.equals(f.getValue(),
+                    "{\"value\":null}")) {
                 JSONObject jsonObject = JSONObject.parseObject(f.getValue());
                 String value = jsonObject.getString(SystemConstant.VALUE);
                 processLimitedTime = Long.parseLong(value);