|
|
|
@ -290,10 +290,12 @@ public class WorkPlanItemServiceImpl extends BaseServiceImpl<WorkPlanItemMapper, |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public List<WorkPlanItemVO> listShareVOByWpiId(Long wpiId) { |
|
|
|
public List<WorkPlanItemVO> listShareVOByWpiId(Long wpiId) { |
|
|
|
List<WorkPlanItemVO> listVO = baseMapper.listShareByWpiId(wpiId); |
|
|
|
List<WorkPlanItemVO> listVO = baseMapper.listShareByWpiId(wpiId); |
|
|
|
|
|
|
|
if (CollectionUtils.isNotEmpty(listVO)) { |
|
|
|
for (WorkPlanItemVO vo : listVO) { |
|
|
|
for (WorkPlanItemVO vo : listVO) { |
|
|
|
setVOValue(vo); |
|
|
|
setVOValue(vo); |
|
|
|
vo.setCheckName("工序检验"); |
|
|
|
vo.setCheckName("工序检验"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
List<WorkPlanItemVO> itemVOS = listShareBySameSlot(wpiId); |
|
|
|
List<WorkPlanItemVO> itemVOS = listShareBySameSlot(wpiId); |
|
|
|
if (CollectionUtils.isNotEmpty(itemVOS)) { |
|
|
|
if (CollectionUtils.isNotEmpty(itemVOS)) { |
|
|
|
for (WorkPlanItemVO vo : itemVOS) { |
|
|
|
for (WorkPlanItemVO vo : itemVOS) { |
|
|
|
@ -313,10 +315,12 @@ public class WorkPlanItemServiceImpl extends BaseServiceImpl<WorkPlanItemMapper, |
|
|
|
private List<WorkPlanItemVO> listShareBySameSlot(Long wpiId) { |
|
|
|
private List<WorkPlanItemVO> listShareBySameSlot(Long wpiId) { |
|
|
|
WorkPlanItem workPlanItem = this.getById(wpiId); |
|
|
|
WorkPlanItem workPlanItem = this.getById(wpiId); |
|
|
|
if (workPlanItem == null) { |
|
|
|
if (workPlanItem == null) { |
|
|
|
|
|
|
|
log.info("WorkPlanItem查询失败"); |
|
|
|
return null; |
|
|
|
return null; |
|
|
|
} |
|
|
|
} |
|
|
|
WorkPlan workPlan = workPlanMapper.selectById(workPlanItem.getWpId()); |
|
|
|
WorkPlan workPlan = workPlanMapper.selectById(workPlanItem.getWpId()); |
|
|
|
if (workPlan == null) { |
|
|
|
if (workPlan == null) { |
|
|
|
|
|
|
|
log.info("workPlan查询失败"); |
|
|
|
return null; |
|
|
|
return null; |
|
|
|
} |
|
|
|
} |
|
|
|
if (workPlan != null && workPlan.getFrontWpId() != null) { |
|
|
|
if (workPlan != null && workPlan.getFrontWpId() != null) { |
|
|
|
@ -342,17 +346,21 @@ public class WorkPlanItemServiceImpl extends BaseServiceImpl<WorkPlanItemMapper, |
|
|
|
String partCode = null; |
|
|
|
String partCode = null; |
|
|
|
if (workPlan.getCaId() != null) { |
|
|
|
if (workPlan.getCaId() != null) { |
|
|
|
CraftAbilityEntity craftAbility = craftAbilityService.getById(workPlan.getCaId()); |
|
|
|
CraftAbilityEntity craftAbility = craftAbilityService.getById(workPlan.getCaId()); |
|
|
|
|
|
|
|
if (craftAbility != null) { |
|
|
|
Map<String, String> dictMap = getProcessCapabilityTypeMap(); |
|
|
|
Map<String, String> dictMap = getProcessCapabilityTypeMap(); |
|
|
|
String wxLimitName = dictMap.get(craftAbility.getWxLimit()); |
|
|
|
String wxLimitName = dictMap.get(craftAbility.getWxLimit()); |
|
|
|
boolean checkCaType = !StringUtils.isEmpty(wxLimitName) && (wxLimitName.contains("镀金") || wxLimitName.contains("镀银")); |
|
|
|
boolean checkCaType = !StringUtils.isEmpty(wxLimitName) && (wxLimitName.contains("镀金") || wxLimitName.contains("镀银")); |
|
|
|
|
|
|
|
log.info("checkCaType:" + checkCaType); |
|
|
|
WorkOrder workOrder = workOrderMapper.selectById(workPlan.getWoId()); |
|
|
|
WorkOrder workOrder = workOrderMapper.selectById(workPlan.getWoId()); |
|
|
|
if (workOrder == null) { |
|
|
|
if (workOrder == null) { |
|
|
|
|
|
|
|
log.info("workOrder查询失败"); |
|
|
|
return null; |
|
|
|
return null; |
|
|
|
} |
|
|
|
} |
|
|
|
if (checkCaType) { |
|
|
|
if (checkCaType) { |
|
|
|
partCode = workOrder.getPartCode(); |
|
|
|
partCode = workOrder.getPartCode(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
List<ProduceMonitorSlotListVO> list = macToolUseService.listSlotInfo(workPlan); |
|
|
|
List<ProduceMonitorSlotListVO> list = macToolUseService.listSlotInfo(workPlan); |
|
|
|
if (CollectionUtils.isNotEmpty(list)) { |
|
|
|
if (CollectionUtils.isNotEmpty(list)) { |
|
|
|
List<ProduceMonitorSlotListVO> collect = list.stream().filter(vo -> !vo.getWpId().equals(workPlanItem.getWpId())).collect(Collectors.toList()); |
|
|
|
List<ProduceMonitorSlotListVO> collect = list.stream().filter(vo -> !vo.getWpId().equals(workPlanItem.getWpId())).collect(Collectors.toList()); |
|
|
|
|