This commit is contained in:
xy
2024-06-26 17:47:33 +08:00
parent 16e90de9eb
commit ae2207bd97
4 changed files with 33 additions and 25 deletions

View File

@@ -109,7 +109,7 @@ public class BpmModelController extends BaseController {
@OperateInfo(info = LogEnum.BUSINESS_COMMON, operateType = OperateType.ADD) @OperateInfo(info = LogEnum.BUSINESS_COMMON, operateType = OperateType.ADD)
@PostMapping("/add") @PostMapping("/add")
@ApiOperation("新建模型") @ApiOperation("新建模型")
@ApiImplicitParam(name = "createRetVO", value = "模型数据", required = true) @ApiImplicitParam(name = "bpmModelParam", value = "模型数据", required = true)
public HttpResult<String> createModel(@Validated @RequestBody BpmModelParam bpmModelParam) { public HttpResult<String> createModel(@Validated @RequestBody BpmModelParam bpmModelParam) {
String methodDescribe = getMethodDescribe("createModel"); String methodDescribe = getMethodDescribe("createModel");
String modelId = modelService.createModel(bpmModelParam, null); String modelId = modelService.createModel(bpmModelParam, null);

View File

@@ -49,7 +49,8 @@
supervision_warning_leaflet.create_by, supervision_warning_leaflet.create_by,
supervision_warning_leaflet.create_time, supervision_warning_leaflet.create_time,
supervision_warning_leaflet.update_by, supervision_warning_leaflet.update_by,
supervision_warning_leaflet.update_time supervision_warning_leaflet.update_time,
supervision_warning_leaflet.file_path
FROM supervision_warning_leaflet supervision_warning_leaflet FROM supervision_warning_leaflet supervision_warning_leaflet
WHERE ${ew.sqlSegment} WHERE ${ew.sqlSegment}
</select> </select>

View File

@@ -211,6 +211,7 @@ public class WarningLeafletServiceImpl extends ServiceImpl<WarningLeafletMapper,
public WarningLeafletVO getVOById(String id) { public WarningLeafletVO getVOById(String id) {
WarningLeaflet warningLeaflet = this.getById(id); WarningLeaflet warningLeaflet = this.getById(id);
WarningLeafletVO warningLeafletVO = new WarningLeafletVO(); WarningLeafletVO warningLeafletVO = new WarningLeafletVO();
if (!Objects.isNull(warningLeaflet)){
BeanUtil.copyProperties(warningLeaflet, warningLeafletVO); BeanUtil.copyProperties(warningLeaflet, warningLeafletVO);
if (StrUtil.isNotBlank(warningLeaflet.getDeptId())) { if (StrUtil.isNotBlank(warningLeaflet.getDeptId())) {
Dept dept = deptFeignClient.getDeptById(warningLeaflet.getDeptId()).getData(); Dept dept = deptFeignClient.getDeptById(warningLeaflet.getDeptId()).getData();
@@ -225,6 +226,7 @@ public class WarningLeafletServiceImpl extends ServiceImpl<WarningLeafletMapper,
SurveyTest surveyTest = surveyTestService.getById(problemId); SurveyTest surveyTest = surveyTestService.getById(problemId);
warningLeafletVO.setProblemPath(surveyTest.getTestReport()); warningLeafletVO.setProblemPath(surveyTest.getTestReport());
} }
}
return warningLeafletVO; return warningLeafletVO;
} }
@@ -237,6 +239,7 @@ public class WarningLeafletServiceImpl extends ServiceImpl<WarningLeafletMapper,
public BpmInstanceInfo getInstanceInfo(String businessId) { public BpmInstanceInfo getInstanceInfo(String businessId) {
BpmInstanceInfo bpmInstanceInfo = new BpmInstanceInfo(); BpmInstanceInfo bpmInstanceInfo = new BpmInstanceInfo();
WarningLeafletVO warningLeafletVO = this.getVOById(businessId); WarningLeafletVO warningLeafletVO = this.getVOById(businessId);
if (Objects.nonNull(warningLeafletVO.getId())) {
bpmInstanceInfo.setHistoryInstanceId(warningLeafletVO.getHistoryInstanceId()); bpmInstanceInfo.setHistoryInstanceId(warningLeafletVO.getHistoryInstanceId());
String type = "告警单"; String type = "告警单";
if(warningLeafletVO.getLeafletType() == 1){ if(warningLeafletVO.getLeafletType() == 1){
@@ -249,6 +252,7 @@ public class WarningLeafletServiceImpl extends ServiceImpl<WarningLeafletMapper,
.concat(warningLeafletVO.getLeafletName()) .concat(warningLeafletVO.getLeafletName())
.concat(type); .concat(type);
bpmInstanceInfo.setInstanceSign(sign); bpmInstanceInfo.setInstanceSign(sign);
}
return bpmInstanceInfo; return bpmInstanceInfo;
} }
@@ -291,6 +295,9 @@ public class WarningLeafletServiceImpl extends ServiceImpl<WarningLeafletMapper,
if (deptMap.containsKey(record.getDutyOrgId())) { if (deptMap.containsKey(record.getDutyOrgId())) {
record.setDutyOrgName(deptMap.get(record.getDutyOrgId())); record.setDutyOrgName(deptMap.get(record.getDutyOrgId()));
} }
if (!Objects.isNull(record.getFilePath())){
record.setFilePath(fileStorageUtil.getFileUrl(record.getFilePath()));
}
} }
} }
return warningLeafletVOPage; return warningLeafletVOPage;