diff --git a/src/main/java/neatlogic/module/process/api/processtask/ProcessTaskFormApi.java b/src/main/java/neatlogic/module/process/api/processtask/ProcessTaskFormApi.java
index d7d71ca15a01f0decacdf74a2560798598e246dd..b642d0afde1460166e673736a8ab9c7a1edea501 100644
--- a/src/main/java/neatlogic/module/process/api/processtask/ProcessTaskFormApi.java
+++ b/src/main/java/neatlogic/module/process/api/processtask/ProcessTaskFormApi.java
@@ -90,7 +90,6 @@ public class ProcessTaskFormApi extends PrivateApiComponentBase {
resultObj.put("formAttributeDataMap", processTaskVo.getFormAttributeDataMap());
resultObj.put("formConfig", processTaskVo.getFormConfig());
- resultObj.put("formConfigAuthorityList", processTaskVo.getFormConfigAuthorityList());
resultObj.put("formAttributeHideList", processTaskVo.getFormAttributeHideList());
}
diff --git a/src/main/java/neatlogic/module/process/dao/mapper/workcenter/WorkcenterMapper.xml b/src/main/java/neatlogic/module/process/dao/mapper/workcenter/WorkcenterMapper.xml
index a7026d4a062de4983f952696b43e6329b3fa5ab5..a28df7c3abda712220faf8ead1e481858f8397a6 100644
--- a/src/main/java/neatlogic/module/process/dao/mapper/workcenter/WorkcenterMapper.xml
+++ b/src/main/java/neatlogic/module/process/dao/mapper/workcenter/WorkcenterMapper.xml
@@ -173,7 +173,8 @@ along with this program. If not, see .-->
`sort`,
`type`,
`support`,
- `is_show_total`
+ `is_show_total`,
+ `condition_config`
from `process_workcenter`
where `uuid` in
diff --git a/src/main/java/neatlogic/module/process/service/ProcessTaskServiceImpl.java b/src/main/java/neatlogic/module/process/service/ProcessTaskServiceImpl.java
index bfff9d65a2c3a390df9f032d9b15ec58fcd4aa82..c7041a762445a29a7cbe29d10da22432a2b1dd38 100644
--- a/src/main/java/neatlogic/module/process/service/ProcessTaskServiceImpl.java
+++ b/src/main/java/neatlogic/module/process/service/ProcessTaskServiceImpl.java
@@ -287,10 +287,6 @@ public class ProcessTaskServiceImpl implements ProcessTaskService, IProcessTaskC
processTaskVo.getFormAttributeDataMap().put(processTaskFormAttributeDataVo.getAttributeUuid(), processTaskFormAttributeDataVo.getDataObj());
}
processTaskVo.setProcessTaskFormAttributeDataList(processTaskFormAttributeDataList);
- // 获取工单流程图信息
- String taskConfig = selectContentByHashMapper.getProcessTaskConfigStringByHash(processTaskVo.getConfigHash());
- JSONArray formConfigAuthorityList = (JSONArray) JSONPath.read(taskConfig, "process.formConfig.authorityList");
- processTaskVo.setFormConfigAuthorityList(formConfigAuthorityList);
List formAttributeHideList = getFormConfigAuthorityConfig(processTaskVo);
processTaskVo.setFormAttributeHideList(formAttributeHideList);
}
@@ -306,17 +302,6 @@ public class ProcessTaskServiceImpl implements ProcessTaskService, IProcessTaskC
throw new FormActiveVersionNotFoundExcepiton(formUuid);
}
processTaskVo.setFormConfig(formVersion.getFormConfig());
- JSONObject processConfig = processVo.getConfig();
- if (MapUtils.isNotEmpty(processConfig)) {
- JSONObject process = processConfig.getJSONObject("process");
- if (MapUtils.isNotEmpty(process)) {
- JSONObject formConfig = process.getJSONObject("formConfig");
- if (MapUtils.isNotEmpty(formConfig)) {
- JSONArray authorityList = formConfig.getJSONArray("authorityList");
- processTaskVo.setFormConfigAuthorityList(authorityList);
- }
- }
- }
List formAttributeHideList = getFormConfigAuthorityConfig(processTaskVo);
processTaskVo.setFormAttributeHideList(formAttributeHideList);
}
diff --git a/src/main/java/neatlogic/module/process/service/ProcessTaskStepTaskServiceImpl.java b/src/main/java/neatlogic/module/process/service/ProcessTaskStepTaskServiceImpl.java
index 854807614d6cae9bdf19b7737a342cad33a0dd19..5547c8fce581f6521bc8641d88bca0a387b7c9b6 100644
--- a/src/main/java/neatlogic/module/process/service/ProcessTaskStepTaskServiceImpl.java
+++ b/src/main/java/neatlogic/module/process/service/ProcessTaskStepTaskServiceImpl.java
@@ -15,6 +15,9 @@ along with this program. If not, see .*/
package neatlogic.module.process.service;
+import com.alibaba.fastjson.JSON;
+import com.alibaba.fastjson.JSONArray;
+import com.alibaba.fastjson.JSONObject;
import neatlogic.framework.asynchronization.threadlocal.UserContext;
import neatlogic.framework.common.constvalue.systemuser.SystemUser;
import neatlogic.framework.dao.mapper.UserMapper;
@@ -22,11 +25,7 @@ import neatlogic.framework.dto.UserVo;
import neatlogic.framework.file.dao.mapper.FileMapper;
import neatlogic.framework.file.dto.FileVo;
import neatlogic.framework.process.constvalue.*;
-import neatlogic.framework.process.operationauth.core.IOperationType;
-import neatlogic.module.process.dao.mapper.processtask.ProcessTaskMapper;
-import neatlogic.module.process.dao.mapper.processtask.ProcessTaskStepTaskMapper;
-import neatlogic.module.process.dao.mapper.SelectContentByHashMapper;
-import neatlogic.module.process.dao.mapper.task.TaskMapper;
+import neatlogic.framework.process.crossover.IProcessTaskStepTaskCrossoverService;
import neatlogic.framework.process.dto.*;
import neatlogic.framework.process.exception.operationauth.ProcessTaskHiddenException;
import neatlogic.framework.process.exception.operationauth.ProcessTaskPermissionDeniedException;
@@ -35,13 +34,15 @@ import neatlogic.framework.process.exception.operationauth.ProcessTaskStepNotMin
import neatlogic.framework.process.exception.process.ProcessStepUtilHandlerNotFoundException;
import neatlogic.framework.process.exception.processtask.task.*;
import neatlogic.framework.process.notify.constvalue.ProcessTaskStepTaskNotifyTriggerType;
+import neatlogic.framework.process.operationauth.core.IOperationType;
import neatlogic.framework.process.stephandler.core.IProcessStepInternalHandler;
import neatlogic.framework.process.stephandler.core.ProcessStepInternalHandlerFactory;
import neatlogic.framework.process.task.TaskConfigManager;
import neatlogic.framework.service.UserService;
-import com.alibaba.fastjson.JSON;
-import com.alibaba.fastjson.JSONArray;
-import com.alibaba.fastjson.JSONObject;
+import neatlogic.module.process.dao.mapper.SelectContentByHashMapper;
+import neatlogic.module.process.dao.mapper.processtask.ProcessTaskMapper;
+import neatlogic.module.process.dao.mapper.processtask.ProcessTaskStepTaskMapper;
+import neatlogic.module.process.dao.mapper.task.TaskMapper;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.collections4.MapUtils;
import org.apache.commons.lang3.StringUtils;
@@ -57,7 +58,7 @@ import java.util.stream.Collectors;
* @since 2021/8/31 11:49
**/
@Service
-public class ProcessTaskStepTaskServiceImpl implements ProcessTaskStepTaskService {
+public class ProcessTaskStepTaskServiceImpl implements ProcessTaskStepTaskService, IProcessTaskStepTaskCrossoverService {
@Resource
ProcessTaskMapper processTaskMapper;
@Resource
diff --git a/src/main/java/neatlogic/module/process/stephandler/utilhandler/ConditionProcessUtilHandler.java b/src/main/java/neatlogic/module/process/stephandler/utilhandler/ConditionProcessUtilHandler.java
index 045bdc47701d010c2935bc774dba3f08bf39a69b..e7114507ba7cab21675b742d9f816c9b097285e4 100755
--- a/src/main/java/neatlogic/module/process/stephandler/utilhandler/ConditionProcessUtilHandler.java
+++ b/src/main/java/neatlogic/module/process/stephandler/utilhandler/ConditionProcessUtilHandler.java
@@ -1,5 +1,6 @@
package neatlogic.module.process.stephandler.utilhandler;
+import com.alibaba.fastjson.JSONObject;
import neatlogic.framework.process.constvalue.ProcessStepHandlerType;
import neatlogic.framework.process.dto.ProcessTaskStepVo;
import neatlogic.framework.process.stephandler.core.ProcessStepInternalHandlerBase;
@@ -31,6 +32,14 @@ public class ConditionProcessUtilHandler extends ProcessStepInternalHandlerBase
}
+ @Override
+ public JSONObject makeupConfig(JSONObject configObj) {
+ if (configObj == null) {
+ configObj = new JSONObject();
+ }
+ return configObj;
+ }
+
@Override
public String[] getRegulateKeyList() {
return new String[]{"moveonConfigList", "formTag"};
diff --git a/src/main/java/neatlogic/module/process/stephandler/utilhandler/EndProcessUtilHandler.java b/src/main/java/neatlogic/module/process/stephandler/utilhandler/EndProcessUtilHandler.java
index 5010176b62936adfe4840c4f5f1f3b05fd5e81fd..484644a82c3ec9e8c3eb5d9bf1becf5c401a1bd3 100644
--- a/src/main/java/neatlogic/module/process/stephandler/utilhandler/EndProcessUtilHandler.java
+++ b/src/main/java/neatlogic/module/process/stephandler/utilhandler/EndProcessUtilHandler.java
@@ -2,9 +2,7 @@ package neatlogic.module.process.stephandler.utilhandler;
import neatlogic.framework.notify.core.INotifyPolicyHandler;
import neatlogic.framework.process.constvalue.ProcessStepHandlerType;
-import neatlogic.framework.process.constvalue.ProcessTaskOperationType;
import neatlogic.framework.process.dto.ProcessTaskStepVo;
-import neatlogic.framework.process.operationauth.core.IOperationType;
import neatlogic.framework.process.stephandler.core.ProcessStepInternalHandlerBase;
import neatlogic.module.process.notify.handler.TaskNotifyPolicyHandler;
import org.springframework.stereotype.Service;
@@ -37,19 +35,9 @@ public class EndProcessUtilHandler extends ProcessStepInternalHandlerBase {
return TaskNotifyPolicyHandler.class;
}
- @Override
- public IOperationType[] getStepActions() {
- /* 授权 */
- return new IOperationType[]{
- ProcessTaskOperationType.PROCESSTASK_ABORT,
- ProcessTaskOperationType.PROCESSTASK_UPDATE,
- ProcessTaskOperationType.PROCESSTASK_URGE
- };
- }
-
@Override
public String[] getRegulateKeyList() {
- return new String[]{"processConfig", "formConfig", "scoreConfig", "slaList", "authorityList"};
+ return new String[]{"processConfig", "formConfig", "scoreConfig", "slaList"};
}
// @Override
diff --git a/src/main/java/neatlogic/module/process/workcenter/init/WorkcenterInit.java b/src/main/java/neatlogic/module/process/workcenter/init/WorkcenterInit.java
index 62c79d53a5f295844aa2a917bda6794100c62dac..8d72ef0e9236ab2226bf80728bde2faf1f2b6383 100644
--- a/src/main/java/neatlogic/module/process/workcenter/init/WorkcenterInit.java
+++ b/src/main/java/neatlogic/module/process/workcenter/init/WorkcenterInit.java
@@ -15,6 +15,7 @@ along with this program. If not, see .*/
package neatlogic.module.process.workcenter.init;
+import com.alibaba.fastjson.JSONObject;
import neatlogic.framework.common.constvalue.DeviceType;
import neatlogic.framework.common.constvalue.GroupSearch;
import neatlogic.framework.common.constvalue.UserType;
@@ -26,6 +27,7 @@ import neatlogic.framework.process.workcenter.dto.WorkcenterVo;
import neatlogic.framework.startup.StartupBase;
import neatlogic.framework.tenantinit.ITenantInit;
import org.apache.commons.collections4.CollectionUtils;
+import org.apache.commons.collections4.MapUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Component;
@@ -233,6 +235,16 @@ public class WorkcenterInit extends StartupBase implements ITenantInit {
if (StringUtils.isNotBlank(oldWorkcenterVo.getSupport())) {
workcenterVo.setSupport(oldWorkcenterVo.getSupport());
}
+ JSONObject oldConditionConfig = oldWorkcenterVo.getConditionConfig();
+ if (MapUtils.isNotEmpty(oldConditionConfig)) {
+ JSONObject startTimeCondition = oldConditionConfig.getJSONObject("startTimeCondition");
+ if (MapUtils.isNotEmpty(startTimeCondition)) {
+ JSONObject conditionConfig = workcenterVo.getConditionConfig();
+ if (MapUtils.isNotEmpty(conditionConfig)) {
+ conditionConfig.put("startTimeCondition", startTimeCondition);
+ }
+ }
+ }
}
workcenterMapper.insertWorkcenter(workcenterVo);
//初始化工单中心分类权限