feat:查询算例结果文件和指标提供给flowable
This commit is contained in:
@@ -25,10 +25,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
@@ -178,6 +175,11 @@ public class SimulationRunController implements ISimulationRunFeignClient {
|
||||
return runService.listSimulationKeyResult(req);
|
||||
}
|
||||
|
||||
@GetMapping(value = "/getSimulationKeyResultFileIds")
|
||||
public SdmResponse<List<Long>> getSimulationKeyResultFileIds(@RequestParam String runId) {
|
||||
return runService.getSimulationKeyResultFileIds(runId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据交付物文件id查询相关属性和任务信息
|
||||
*
|
||||
|
||||
@@ -59,6 +59,8 @@ public interface ISimulationRunService extends IService<SimulationRun> {
|
||||
|
||||
SdmResponse<PageDataResp<List<SimulationRunKeyResult>>> listSimulationKeyResult(KeyResultReq req);
|
||||
|
||||
SdmResponse<List<Long>> getSimulationKeyResultFileIds(String runId);
|
||||
|
||||
SdmResponse<PageDataResp<List<KeyResultAndTaskInfoResp>>> queryKeyResultAndTaskInfo(KeyResultReq req);
|
||||
|
||||
SdmResponse deleteSimulationKeyResult(KeyResultReq req);
|
||||
|
||||
@@ -1016,6 +1016,15 @@ public class SimulationRunServiceImpl extends ServiceImpl<SimulationRunMapper, S
|
||||
return PageUtils.getJsonObjectSdmResponse(runKeyResults, page);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SdmResponse<List<Long>> getSimulationKeyResultFileIds(String runId) {
|
||||
List<SimulationRunKeyResult> runKeyResults = simulationKeyResultService.lambdaQuery().eq(SimulationRunKeyResult::getRunId, runId).list();
|
||||
if (CollectionUtils.isNotEmpty(runKeyResults)) {
|
||||
return SdmResponse.success(runKeyResults.stream().map(SimulationRunKeyResult::getFileId).collect(Collectors.toList()));
|
||||
}
|
||||
return SdmResponse.success(new ArrayList<>());
|
||||
}
|
||||
|
||||
@Override
|
||||
public SdmResponse<PageDataResp<List<KeyResultAndTaskInfoResp>>> queryKeyResultAndTaskInfo(KeyResultReq req) {
|
||||
List<KeyResultAndTaskInfoResp> respList = new ArrayList<>();
|
||||
|
||||
Reference in New Issue
Block a user