diff --git a/src/main/java/neatlogic/module/process/stephandler/regulatehandler/ShowAutoApprovalRegulateHandler.java b/src/main/java/neatlogic/module/process/stephandler/regulatehandler/ShowAutoApprovalRegulateHandler.java new file mode 100644 index 0000000000000000000000000000000000000000..cd57df23fb67f7c4bd06f90a1a5c11974fb22973 --- /dev/null +++ b/src/main/java/neatlogic/module/process/stephandler/regulatehandler/ShowAutoApprovalRegulateHandler.java @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2024 深圳极向量科技有限公司 All Rights Reserved. + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ + +package neatlogic.module.process.stephandler.regulatehandler; + +import com.alibaba.fastjson.JSONObject; +import neatlogic.framework.config.ConfigManager; +import neatlogic.framework.process.constvalue.ItsmTenantConfig; +import neatlogic.framework.process.stephandler.core.IProcessStepInternalHandler; +import neatlogic.framework.process.stephandler.core.IRegulateHandler; +import org.springframework.stereotype.Service; + +@Service +public class ShowAutoApprovalRegulateHandler implements IRegulateHandler { + /** + * 是否显示自动审批 + **/ + @Override + public String getName() { + return "showAutoApproval"; + } + + @Override + public void regulateConfig(IProcessStepInternalHandler processStepInternalHandler, JSONObject oldConfigObj, JSONObject newConfigObj) { + newConfigObj.put("showAutoApproval", ConfigManager.getConfig(ItsmTenantConfig.PROCESSTASK_STEP_AUTOAPPROVAL_SHOW)); + } +} diff --git a/src/main/java/neatlogic/module/process/stephandler/utilhandler/OmnipotentProcessUtilHandler.java b/src/main/java/neatlogic/module/process/stephandler/utilhandler/OmnipotentProcessUtilHandler.java index 1bc00e544761055349b48743620c803b205dee3e..7383473955a71dc725d72cf3d555119ea6ca33a0 100644 --- a/src/main/java/neatlogic/module/process/stephandler/utilhandler/OmnipotentProcessUtilHandler.java +++ b/src/main/java/neatlogic/module/process/stephandler/utilhandler/OmnipotentProcessUtilHandler.java @@ -74,7 +74,7 @@ public class OmnipotentProcessUtilHandler extends ProcessStepInternalHandlerBase @Override public String[] getRegulateKeyList() { - return new String[]{"authorityList", "notifyPolicyConfig", "actionConfig", "customButtonList", "customStatusList", "replaceableTextList", "workerPolicyConfig", "taskConfig", "enableReapproval", "autoComplete", "autoApproval", "formSceneUuid", "formSceneName", "autoStart", "isNeedUploadFile", "isNeedContent", "isRequired", "commentTemplateId", "tagList"}; + return new String[]{"authorityList", "notifyPolicyConfig", "actionConfig", "customButtonList", "customStatusList", "replaceableTextList", "workerPolicyConfig", "taskConfig", "enableReapproval", "autoComplete", "autoApproval", "showAutoApproval", "formSceneUuid", "formSceneName", "autoStart", "isNeedUploadFile", "isNeedContent", "isRequired", "commentTemplateId", "tagList"}; } @Override