|
|
|
@ -706,23 +706,12 @@ public class TaskQuestServiceImpl extends BaseServiceImpl<TaskQuestMapper, TaskQ
|
|
|
|
|
return R.fail("待处理的包件为空!QuestNum"); |
|
|
|
|
}*/ |
|
|
|
|
BladeUser user = AuthUtil.getUser(); |
|
|
|
|
QuestDetailEntity questDetailer = new QuestDetailEntity(); |
|
|
|
|
|
|
|
|
|
List<Long> ids = null; |
|
|
|
|
if(ObjectUtils.isNotNull(taskSearchDTO.getQuestDetailIds())){ |
|
|
|
|
|
|
|
|
|
for (String questDetailId : taskSearchDTO.getQuestDetailIds()) { |
|
|
|
|
if(ObjectUtils.isNull(ids)){ |
|
|
|
|
ids = new ArrayList<>(); |
|
|
|
|
} |
|
|
|
|
ids.add(Long.parseLong(questDetailId)); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
List<QuestDetailEntity> questDetailList = baseMapper.selectTaskInfoForIds(questNum, questDetailer,ids); |
|
|
|
|
log.info(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> questDetailList {}",questDetailList); |
|
|
|
|
|
|
|
|
|
// 在库包件状态修改
|
|
|
|
|
if(ObjectUtils.isNotNull(taskSearchDTO.getQuestDetailIds()) && ObjectUtils.isNotNull(taskSearchDTO.getQuestDetailIds().get(0)) ){ |
|
|
|
|
QuestDetailEntity quest = new QuestDetailEntity(); |
|
|
|
|
List<QuestDetailEntity> questDetailList = baseMapper.selectTaskInfoForIds(questNum, quest,taskSearchDTO.getQuestDetailIds()); |
|
|
|
|
|
|
|
|
|
log.info(">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> tag {}",1); |
|
|
|
|
List<QuestDetailEntity> list = new ArrayList<>(); |
|
|
|
|
AtomicBoolean s = new AtomicBoolean(false); |
|
|
|
@ -807,12 +796,12 @@ public class TaskQuestServiceImpl extends BaseServiceImpl<TaskQuestMapper, TaskQ
|
|
|
|
|
} |
|
|
|
|
//添加
|
|
|
|
|
List<QuestDetailChildEntity> childList = new ArrayList<>(); |
|
|
|
|
childList.add(addQuestDetailChild(stockNum,"10",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(wornNum,"20",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(lossNum,"30",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(noRepairNum,"40",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(deliveNum,"50",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(noReceivedNum,"60",i.getId(),warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(stockNum,"10",taskID,warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(wornNum,"20",taskID,warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(lossNum,"30",taskID,warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(noRepairNum,"40",taskID,warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(deliveNum,"50",taskID,warehouseId,questNum)); |
|
|
|
|
childList.add(addQuestDetailChild(noReceivedNum,"60",taskID,warehouseId,questNum)); |
|
|
|
|
if(!childList.isEmpty()){ |
|
|
|
|
boolean b = childList.stream().anyMatch(ii -> ObjectUtils.isNull(ii.getId())); |
|
|
|
|
if(b){ |
|
|
|
@ -2742,11 +2731,6 @@ public class TaskQuestServiceImpl extends BaseServiceImpl<TaskQuestMapper, TaskQ
|
|
|
|
|
|
|
|
|
|
private QuestDetailChildEntity addQuestDetailChild(Integer num,String cargoName,Long questDetaiId,Long warehouseId,String qu){ |
|
|
|
|
|
|
|
|
|
if(Objects.isNull(questDetaiId)){ |
|
|
|
|
log.warn("###########addQuestDetailChild: 明细id不存在 questDetaiId={}",questDetaiId); |
|
|
|
|
throw new CustomerException(403,"明细id不存在"); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if(Objects.isNull(num)){ |
|
|
|
|
log.warn("###########addQuestDetailChild: 数量不正确 num={}",num); |
|
|
|
|
throw new CustomerException(403,"数量不正确"); |
|
|
|
|