|
|
|
@ -413,14 +413,10 @@ public class EquPlanServiceImpl implements IEquPlanService {
|
|
|
|
|
// 处理计划1-n设备信息
|
|
|
|
|
List<EquPlanEqu> equipmentItemList = equPlan.getEquipmentItem();
|
|
|
|
|
|
|
|
|
|
// 计划-设备流水号
|
|
|
|
|
int equipmentCodeTemp = 0;
|
|
|
|
|
|
|
|
|
|
for (EquPlanEqu equipment : equipmentItemList) {
|
|
|
|
|
equipment.setId(IdUtils.fastSimpleUUID());
|
|
|
|
|
equipment.setPlanCode(equPlan.getPlanCode());
|
|
|
|
|
equipment.setCode("E" + equPlan.getPlanCode() + String.format("%02d", ++equipmentCodeTemp));
|
|
|
|
|
equipment.setParentCode(equPlan.getPlanCode());
|
|
|
|
|
equipment.setParentCode(equPlan.getPlanId());
|
|
|
|
|
equipment.setFactoryCode(factory);
|
|
|
|
|
equipment.setCreateBy(SecurityContextHolder.getUserName());
|
|
|
|
|
equipment.setCreateTime(DateUtils.getNowDate());
|
|
|
|
@ -430,16 +426,13 @@ public class EquPlanServiceImpl implements IEquPlanService {
|
|
|
|
|
// 处理检查项信息
|
|
|
|
|
List<EquPlanDetail> detailList = equipment.getEquPlanDetailList();
|
|
|
|
|
if (detailList != null) {
|
|
|
|
|
// 计划检查项流水号
|
|
|
|
|
int itemCodeTemp = 0;
|
|
|
|
|
|
|
|
|
|
for (EquPlanDetail item : detailList) {
|
|
|
|
|
|
|
|
|
|
if (item != null) {
|
|
|
|
|
item.setId(IdUtils.fastSimpleUUID());
|
|
|
|
|
item.setPlanCode(equPlan.getPlanCode());
|
|
|
|
|
item.setCode("C" + equipment.getCode() + String.format("%02d", ++itemCodeTemp));
|
|
|
|
|
item.setParentCode(equipment.getCode());
|
|
|
|
|
item.setParentCode(equipment.getId());
|
|
|
|
|
item.setCreateBy(SecurityContextHolder.getUserName());
|
|
|
|
|
item.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
item.setUpdateBy(SecurityContextHolder.getUserName());
|
|
|
|
@ -458,7 +451,7 @@ public class EquPlanServiceImpl implements IEquPlanService {
|
|
|
|
|
checkInsert = true;
|
|
|
|
|
|
|
|
|
|
standard.setId(IdUtils.fastSimpleUUID());
|
|
|
|
|
standard.setParentCode(item.getCode());
|
|
|
|
|
standard.setParentCode(item.getId());
|
|
|
|
|
standard.setPlanCode(equPlan.getPlanCode());
|
|
|
|
|
standard.setCreateBy(SecurityContextHolder.getUserName());
|
|
|
|
|
standard.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|