Commit 1def9590 authored by 刘林's avatar 刘林

fix(jg):设计年限功能修改

parent 6c3215c4
......@@ -172,12 +172,18 @@ public class JgOverDesignServiceLife extends BaseEntity {
@TableField("use_registration_code")
private String useRegistrationCode;
@TableField(exist = false)
@TableField("equ_list")
private String equList;
@TableField("equ_list_name")
private String equListName;
@TableField(exist = false)
private String equCategory;
@TableField(exist = false)
private String equCategoryName;
/**
* 首次使用截止日期
*/
......
......@@ -41,7 +41,7 @@
ovds.use_registration_code AS useRegistrationCode,
ovds.next_execute_user_ids AS nextExecuteUserIds,
ovds.create_user_id AS createUserId,
ovds.next_tASk_id AS nextTASkId,
ovds.next_task_id AS nextTaskId,
ovds.USE_UNIT_NAME AS useUnitName,
jri.PRODUCT_NAME AS productName,
jri.EQU_CODE AS equCode,
......
......@@ -234,8 +234,10 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
.findFirst()
.map(e -> Objects.toString(e.get(key), ""))
.orElse("");
overDesignServiceLife.setEquList(getFirstValue.apply("equList"));
overDesignServiceLife.setEquCategory(getFirstValue.apply("equCategory"));
overDesignServiceLife.setEquList(getFirstValue.apply("equListCode"));
overDesignServiceLife.setEquListName(getFirstValue.apply("equList"));
overDesignServiceLife.setEquCategory(getFirstValue.apply("equCategoryCode"));
overDesignServiceLife.setEquCategoryName(getFirstValue.apply("equCategory"));
boolean hasId = StringUtils.isEmpty(overDesignDto.getSequenceNbr());
//新增
if (hasId) {
......@@ -275,7 +277,8 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
equip.setSafetyAssessmentReport(JSONObject.toJSONString(device.get("safetyAssessmentReport")));
}
equipList.add(equip);
overDesignServiceLife.setEquList(Objects.toString(device.get("equList"), ""));
overDesignServiceLife.setEquList(Objects.toString(device.get("equListCode"), ""));
overDesignServiceLife.setEquListName(Objects.toString(device.get("equList"), ""));
});
//保存或更新检验信息
this.updateOrCreateInspectionDetection(equipmentLists);
......@@ -313,7 +316,7 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
BeanUtil.copyProperties(overDesignServiceLife, taskMessageDto);
taskMessageDto.setEquipId(String.valueOf(map.get("equipId")));
dto.setModel(taskMessageDto);
dto.setTaskContent(String.format("来自%s的业务办理,【申请单号:%s】", ObjectUtils.isEmpty(overDesignServiceLife.getEquList()) ? "" : overDesignServiceLife.getEquList(),
dto.setTaskContent(String.format("来自%s的业务办理,【申请单号:%s】", ObjectUtils.isEmpty(overDesignServiceLife.getEquListName()) ? "" : overDesignServiceLife.getEquListName(),
overDesignServiceLife.getApplyNo()));
dto.setTaskCode(overDesignServiceLife.getApplyNo());
dto.setTaskType(String.valueOf(BusinessTypeEnum.JG_OVER_DESIGN_SERVICE_LIFE.getCode()));
......@@ -799,7 +802,7 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
dto.setNextExecuteUser(workflowResultDto.getNextExecutorRoleIds());
dto.setTaskContent(
String.format("来自%s的业务办理,【申请单号:%s】",
ObjectUtils.isEmpty(jgOverDesignServiceLife.getEquList()) ? "" : jgOverDesignServiceLife.getEquList(),
ObjectUtils.isEmpty(jgOverDesignServiceLife.getEquListName()) ? "" : jgOverDesignServiceLife.getEquListName(),
jgOverDesignServiceLife.getApplyNo()));
dto.setFlowCode(jgOverDesignServiceLife.getNextTaskId());
list.add(dto);
......
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