diff --git a/src/main/java/neatlogic/module/autoexec/api/combop/AutoexecCombopDetailGetApi.java b/src/main/java/neatlogic/module/autoexec/api/combop/AutoexecCombopDetailGetApi.java index 223b7a5608b5c6bc97af2e6a605637f9e4dfcb9e..1a102bac28b8f31b681865af4a2aa4fd86ab80ed 100644 --- a/src/main/java/neatlogic/module/autoexec/api/combop/AutoexecCombopDetailGetApi.java +++ b/src/main/java/neatlogic/module/autoexec/api/combop/AutoexecCombopDetailGetApi.java @@ -27,7 +27,7 @@ import neatlogic.framework.autoexec.dto.combop.AutoexecCombopConfigVo; import neatlogic.framework.autoexec.dto.combop.AutoexecCombopVersionConfigVo; import neatlogic.framework.autoexec.dto.combop.AutoexecCombopVersionVo; import neatlogic.framework.autoexec.dto.combop.AutoexecCombopVo; -import neatlogic.framework.autoexec.exception.combop.AutoexecCombopNotFoundEditTargetException; +import neatlogic.framework.autoexec.exception.AutoexecCombopNotFoundException; import neatlogic.framework.autoexec.exception.combop.AutoexecCombopVersionNotFoundEditTargetException; import neatlogic.framework.common.constvalue.ApiParamType; import neatlogic.framework.restful.annotation.*; @@ -74,7 +74,7 @@ public class AutoexecCombopDetailGetApi extends PrivateApiComponentBase { Long versionId = paramObj.getLong("versionId"); AutoexecCombopVo autoexecCombopVo = autoexecCombopService.getAutoexecCombopById(id); if (autoexecCombopVo == null) { - throw new AutoexecCombopNotFoundEditTargetException(id); + throw new AutoexecCombopNotFoundException(id); } AutoexecTypeVo autoexecTypeVo = autoexecTypeMapper.getTypeById(autoexecCombopVo.getTypeId()); if (autoexecTypeVo != null) { diff --git a/src/main/java/neatlogic/module/autoexec/process/util/CreateJobConfigUtil.java b/src/main/java/neatlogic/module/autoexec/process/util/CreateJobConfigUtil.java index b279d53546267057d5af2ddb48b9b144566138ec..9a569d414ff69d8714c31afcf91cf9435dfe6d1f 100644 --- a/src/main/java/neatlogic/module/autoexec/process/util/CreateJobConfigUtil.java +++ b/src/main/java/neatlogic/module/autoexec/process/util/CreateJobConfigUtil.java @@ -432,7 +432,7 @@ public class CreateJobConfigUtil { return null; } - private static AutoexecCombopExecuteNodeConfigVo getExecuteNodeConfig(JSONArray jsonArray) { + public static AutoexecCombopExecuteNodeConfigVo getExecuteNodeConfig(JSONArray jsonArray) { if (CollectionUtils.isEmpty(jsonArray)) { return null; } diff --git a/src/main/java/neatlogic/module/autoexec/service/AutoexecServiceServiceImpl.java b/src/main/java/neatlogic/module/autoexec/service/AutoexecServiceServiceImpl.java index b0fc9240a78566815fc3e7bb5624665338b4e02e..54b145e694a86ca6f0c08dbc95c0098e8e161242 100644 --- a/src/main/java/neatlogic/module/autoexec/service/AutoexecServiceServiceImpl.java +++ b/src/main/java/neatlogic/module/autoexec/service/AutoexecServiceServiceImpl.java @@ -38,6 +38,7 @@ import neatlogic.framework.util.$; import neatlogic.framework.util.FormUtil; import neatlogic.module.autoexec.dao.mapper.AutoexecCombopVersionMapper; import neatlogic.module.autoexec.process.dto.AutoexecJobBuilder; +import neatlogic.module.autoexec.process.util.CreateJobConfigUtil; import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.MapUtils; import org.apache.commons.lang3.StringUtils; @@ -640,7 +641,9 @@ public class AutoexecServiceServiceImpl implements AutoexecServiceService { } else if (Objects.equals(executeNodeParamMappingVo.getMappingMode(), ServiceParamMappingMode.FORMATTR.getValue())) { Object value = formAttributeDataMap.get(executeNodeParamMappingVo.getValue()); if (value != null) { - AutoexecCombopExecuteNodeConfigVo executeNodeConfigVo = JSONObject.toJavaObject((JSONObject) value, AutoexecCombopExecuteNodeConfigVo.class); + JSONArray jsonArray = new JSONArray(); + jsonArray.add(value); + AutoexecCombopExecuteNodeConfigVo executeNodeConfigVo = CreateJobConfigUtil.getExecuteNodeConfig(jsonArray); executeConfigVo.setExecuteNodeConfig(executeNodeConfigVo); } }