Commit a454ad11 authored by suhuiguang's avatar suhuiguang

feat(大编辑):管道增减功能开发

1.检验信息录入前后端联调修改
parent fc30dc91
......@@ -56,7 +56,7 @@ public class PipelineChangeItemDto extends TechParamsPipelineChangeFieldDto {
private Date inspectDate;
@FieldDisplayDefine(value ="检验结论", dictCode = "JYJL")
private String inspectConclusion;
private String inspectConclusionCode;
@FieldDisplayDefine(value = "下次检验日期")
private Date nextInspectDate;
......
......@@ -892,7 +892,7 @@
(select SEQUENCE_NBR from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) jySeq,
(select INSPECT_ORG_CODE from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectOrgCode,
(select INSPECT_ORG_NAME from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectOrgName,
(select INSPECT_CONCLUSION from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectConclusion,
(select INSPECT_CONCLUSION from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectConclusionCode,
(select to_char(NEXT_INSPECT_DATE, 'YYYY-MM-DD') from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) nextInspectDate,
(select INSPECT_REPORT from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectReport,
(select INSPECT_TYPE from idx_biz_jg_inspection_detection_info where "RECORD" = ibjui."RECORD" ORDER BY INSPECT_DATE DESC limit 1) inspectType,
......
......@@ -19,6 +19,7 @@ import lombok.Getter;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections.ListUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.typroject.tyboot.core.foundation.context.RequestContext;
......@@ -125,10 +126,16 @@ public class UseRegisterUpdateService {
private List<JgUseRegistrationEq> getRemainedPieLines(JgUseRegistration useRegistration) {
String pIds = useRegistration.getOriginProjectContraptionIds();
if (pIds != null && !pIds.isEmpty() && !pIds.equals(useRegistration.getProjectContraptionId())) {
// 合并的装置逻辑,按照原始装置查询其下的管道
if (StringUtils.isNotEmpty(pIds) && !pIds.equals(useRegistration.getProjectContraptionId())) {
List<IdxBizJgUseInfo> useInfos = jgUseRegistrationService.getIdxBizJgUseInfoService().list(new LambdaQueryWrapper<IdxBizJgUseInfo>().in(IdxBizJgUseInfo::getProjectContraptionId, Arrays.asList(pIds.split(","))).select(TzsBaseEntity::getSequenceNbr, IdxBizJgUseInfo::getRecord));
return buildEqs(useRegistration, useInfos);
}
// 非装置合并逻辑,按照新装置查询其下的管道
if ((StringUtils.isNotEmpty(pIds) && pIds.equals(useRegistration.getProjectContraptionId())) || (StringUtils.isEmpty(useRegistration.getOriginProjectContraptionIds()))) {
List<IdxBizJgUseInfo> useInfos = jgUseRegistrationService.getIdxBizJgUseInfoService().list(new LambdaQueryWrapper<IdxBizJgUseInfo>().eq(IdxBizJgUseInfo::getProjectContraptionId, useRegistration.getProjectContraptionId()).select(TzsBaseEntity::getSequenceNbr, IdxBizJgUseInfo::getRecord));
return buildEqs(useRegistration, useInfos);
}
return new ArrayList<>();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment