Merge remote-tracking branch 'origin/main'
This commit is contained in:
@@ -1,4 +1,7 @@
|
||||
package com.sdm.common.entity.flowable.executeConfig;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class CloudAppExecuteConfig extends BaseExecuteConfig {
|
||||
}
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
package com.sdm.common.entity.flowable.executeConfig;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class ExportWordScriptExecuteConfig extends BaseExecuteConfig {
|
||||
}
|
||||
|
||||
@@ -1,4 +1,10 @@
|
||||
package com.sdm.common.entity.flowable.executeConfig;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class HPCExecuteConfig extends BaseExecuteConfig {
|
||||
|
||||
private String beforeNodeId;
|
||||
|
||||
}
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
package com.sdm.common.entity.flowable.executeConfig;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class LocalAppExecuteConfig extends BaseExecuteConfig {
|
||||
}
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
package com.sdm.common.entity.flowable.params;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class BaseExecuteParams {
|
||||
|
||||
}
|
||||
@@ -0,0 +1,38 @@
|
||||
package com.sdm.common.entity.req.pbs;
|
||||
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 仿真工具命令占位符配置表
|
||||
* </p>
|
||||
*
|
||||
* @author author
|
||||
* @since 2025-12-01
|
||||
*/
|
||||
@Data
|
||||
public class SimulationCommandPlaceholderReq implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@Schema(description = "自增主键")
|
||||
private Long id;
|
||||
|
||||
@Schema(description = "占位符英文名称")
|
||||
private String keyEnName;
|
||||
|
||||
@Schema(description = "占位符中文名称")
|
||||
private String keyCnName;
|
||||
|
||||
@Schema(description = "占位符值的类型(file_exact_match:文件完全匹配;file_regex_match:文件正则匹配," +
|
||||
"hpc_file_select:Hpc节点文件选择,hpc_file_regex_match:Hpc节点目录正则,local_file_select:本地文件选择,custom_input:用户自定义输入值")
|
||||
private String valueType;
|
||||
|
||||
@Schema(description = "占位符的值,用户输入后赋值传递")
|
||||
private String inputValue="";
|
||||
|
||||
}
|
||||
@@ -1,12 +1,20 @@
|
||||
package com.sdm.common.entity.req.pbs;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.FieldStrategy;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.sdm.common.entity.flowable.executeConfig.BaseExecuteConfig;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Data
|
||||
public class SubmitHpcTaskRemoteReq {
|
||||
public class SubmitHpcTaskRemoteReq extends BaseExecuteConfig {
|
||||
|
||||
@Schema(description = "配置时的mm时间戳")
|
||||
public String timesmap;
|
||||
|
||||
@Schema(description = "计算任务名称")
|
||||
public String jobName;
|
||||
@@ -23,7 +31,7 @@ public class SubmitHpcTaskRemoteReq {
|
||||
@Schema(description = "计算任务是否独立存在 0:非独立任务 1:独立任务")
|
||||
public int independence;
|
||||
|
||||
@Schema(description = "求解文件")
|
||||
@Schema(description = "求解文件,featchFileType =beforeNode 时传递")
|
||||
public List<String> inputFiles = new ArrayList<>();
|
||||
|
||||
@Schema(description = "计算主文件")
|
||||
@@ -47,4 +55,13 @@ public class SubmitHpcTaskRemoteReq {
|
||||
@Schema(description = "任务所属项目")
|
||||
public String projectname;
|
||||
|
||||
@Schema(description = "获取文件的方式:上一节点:beforeNode,hpc节点(文件提前上传工作目录):hpcNode")
|
||||
public String featchFileType;
|
||||
|
||||
@Schema(description = "上一节点Id,featchFileType:beforeNode时传递 ")
|
||||
public String beforeNodeId;
|
||||
|
||||
@Schema(description= "自定义占位符,只有列表展示使用,key 就是占位符")
|
||||
private Map<String,SimulationCommandPlaceholderReq> commandExpand;
|
||||
|
||||
}
|
||||
|
||||
@@ -9,16 +9,17 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Slf4j
|
||||
public class FileSimulationMappingFeignClientImpl implements IFileSimulationMappingFeignClient {
|
||||
@Autowired
|
||||
private IFileSimulationMappingFeignClient fileSimulationMappingFeignClient;
|
||||
@Override
|
||||
public SdmResponse saveFileSimulationMapping(SaveFileSimulationMappingReq saveFileSimulationMappingReq) {
|
||||
public SdmResponse batchSaveFileSimulationMapping(List<SaveFileSimulationMappingReq> saveFileSimulationMappingReq) {
|
||||
SdmResponse response;
|
||||
try {
|
||||
response = fileSimulationMappingFeignClient.saveFileSimulationMapping(saveFileSimulationMappingReq);
|
||||
response = fileSimulationMappingFeignClient.batchSaveFileSimulationMapping(saveFileSimulationMappingReq);
|
||||
log.info("保存文件和工况库关系结果:"+ response);
|
||||
return response;
|
||||
} catch (Exception e) {
|
||||
@@ -39,4 +40,17 @@ public class FileSimulationMappingFeignClientImpl implements IFileSimulationMapp
|
||||
return SdmResponse.failed("查询工况库关系文件失败");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public SdmResponse<Map<String, List<FileMetadataInfoResp>>> batchGetFileSimulationMappingBySimulationPoolIdAndVersion(GetFileSimulationMappingReq getFileSimulationMappingReq) {
|
||||
SdmResponse<Map<String, List<FileMetadataInfoResp>>> response;
|
||||
try {
|
||||
response = fileSimulationMappingFeignClient.batchGetFileSimulationMappingBySimulationPoolIdAndVersion(getFileSimulationMappingReq);
|
||||
log.info("查询工况库关系文件结果:"+ response);
|
||||
return response;
|
||||
} catch (Exception e) {
|
||||
log.error("查询工况库关系文件", e);
|
||||
return SdmResponse.failed("查询工况库关系文件失败");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,12 +9,16 @@ import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@FeignClient(name = "data", contextId = "fileSimulationMappingFeignClient")
|
||||
public interface IFileSimulationMappingFeignClient {
|
||||
@PostMapping("/fileSimulationMapping/saveFileSimulationMapping")
|
||||
SdmResponse saveFileSimulationMapping(@RequestBody SaveFileSimulationMappingReq saveFileSimulationMappingReq);
|
||||
SdmResponse batchSaveFileSimulationMapping(@RequestBody List<SaveFileSimulationMappingReq> saveFileSimulationMappingReq);
|
||||
|
||||
@PostMapping("/getFileSimulationMappingBySimulationPoolIdAndVersionAndTaskId")
|
||||
SdmResponse<List<FileMetadataInfoResp>> getFileSimulationMappingBySimulationPoolIdAndVersionAndTaskId(@RequestBody GetFileSimulationMappingReq getFileSimulationMappingReq);
|
||||
|
||||
@PostMapping("/batchGetFileSimulationMappingBySimulationPoolIdAndVersion")
|
||||
SdmResponse<Map<String, List<FileMetadataInfoResp>>> batchGetFileSimulationMappingBySimulationPoolIdAndVersion(@RequestBody GetFileSimulationMappingReq getFileSimulationMappingReq);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user