diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java index b0cc12581..d1c836062 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/TaskQuestServiceImpl.java @@ -102,7 +102,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl0){ + if (taskQuest.getList().size() > 0) { List list = taskQuest.getList(); for (TaskQuestChildEntity taskQuestChildEntity : list) { taskQuestChildEntity.setWarehouseId(id); @@ -120,14 +120,14 @@ public class TaskQuestServiceImpl extends BaseServiceImpl list = taskQuestChildService.selectlistByMasterId(id); taskQuestVO.setList(list); @@ -138,8 +138,8 @@ public class TaskQuestServiceImpl extends BaseServiceImpl toLongList) { //删除子表 boolean remove = taskQuestChildService.remove(new QueryWrapper().lambda() - .eq(TaskQuestChildEntity::getIsDeleted,0) - .in(TaskQuestChildEntity::getQuestId,toLongList) + .eq(TaskQuestChildEntity::getIsDeleted, 0) + .in(TaskQuestChildEntity::getQuestId, toLongList) ); return this.deleteLogic(toLongList); } @@ -149,11 +149,11 @@ public class TaskQuestServiceImpl extends BaseServiceImpl().lambda() - .eq(TaskQuestChildEntity::getIsDeleted,0) - .eq(TaskQuestChildEntity::getQuestId,id) + .eq(TaskQuestChildEntity::getIsDeleted, 0) + .eq(TaskQuestChildEntity::getQuestId, id) ); //存入子表 - if (taskQuest.getList().size()>0){ + if (taskQuest.getList().size() > 0) { List list = taskQuest.getList(); for (TaskQuestChildEntity taskQuestChildEntity : list) { taskQuestChildEntity.setWarehouseId(id); @@ -168,12 +168,12 @@ public class TaskQuestServiceImpl extends BaseServiceImpl selectTaskQuestApiPage(IPage page, TaskQuestApiVO taskQuest) { - List collect =this.getmyWarehouseList(); + List collect = this.getmyWarehouseList(); List taskQuestVOS = baseMapper.selectTaskQuestApiPage(page, taskQuest, collect); for (TaskQuestApiVO taskQuestVO : taskQuestVOS) { - //查询子表 - List list = taskQuestChildService.selectlistByMasterId(taskQuestVO.getId()); - taskQuestVO.setList(list); + //查询子表 + List list = taskQuestChildService.selectlistByMasterId(taskQuestVO.getId()); + taskQuestVO.setList(list); } return page.setRecords(taskQuestVOS); } @@ -188,13 +188,13 @@ public class TaskQuestServiceImpl extends BaseServiceImpl selectallocationList(IPage page, TaskSearchDTO taskSearchDTO) { - List collect =this.getmyWarehouseList(); - List list =baseMapper.selectallocationList(page,taskSearchDTO,collect); - if (!list.isEmpty()){ + List collect = this.getmyWarehouseList(); + List list = baseMapper.selectallocationList(page, taskSearchDTO, collect); + if (!list.isEmpty()) { for (TaskallocationVO taskallocationVO : list) { Long allocationId = taskallocationVO.getAllocationId(); - Integer i = warehouseUpdownGoodsMapper.selectCountSumByallocation(allocationId); - taskallocationVO.setTotal(i); + Integer i = warehouseUpdownGoodsMapper.selectCountSumByallocation(allocationId); + taskallocationVO.setTotal(i); } } return page.setRecords(list); @@ -202,43 +202,43 @@ public class TaskQuestServiceImpl extends BaseServiceImpl selectcontractList(IPage page, TaskSearchDTO taskSearchDTO) { - List collect =this.getmyWarehouseList(); + List collect = this.getmyWarehouseList(); baseMapper.setSqlMode(); - List list = baseMapper.selectcontractList(page,taskSearchDTO,collect); - if (!list.isEmpty()){ - for (TaskContractVO taskContractVO : list) { - Long orderId = taskContractVO.getOrderId(); - String orderCode = taskContractVO.getOrderCode(); - //查询该订单,如果是零担直接用在库数量 - DistributionStockArticleEntity entityByStockArticle = distributionStockArticleClient.findEntityByStockArticleId(orderId); - if (entityByStockArticle.getIsZero().equals("1")){ - if (entityByStockArticle.getGenre() == 1){ - taskContractVO.setTotal(entityByStockArticle.getTotalNumber()); - taskContractVO.setZktotal(entityByStockArticle.getTotalNumber()); - } - }else if (entityByStockArticle.getIsZero().equals("0")){ - //包条 - if (entityByStockArticle.getGenre()==1){ - //查询该订单下包条的所有数量 - Integer integer = distributionParcelListClient.SumEntityByOrderId(orderId, null); - Integer integer1 = distributionParcelListClient.SumEntityByOrderId(orderId, collect.get(0)); - taskContractVO.setTotal(integer); - taskContractVO.setZktotal(integer1); + List list = baseMapper.selectcontractList(page, taskSearchDTO, collect); + if (!list.isEmpty()) { + for (TaskContractVO taskContractVO : list) { + Long orderId = taskContractVO.getOrderId(); + String orderCode = taskContractVO.getOrderCode(); + //查询该订单,如果是零担直接用在库数量 + DistributionStockArticleEntity entityByStockArticle = distributionStockArticleClient.findEntityByStockArticleId(orderId); + if (entityByStockArticle.getIsZero().equals("1")) { + if (entityByStockArticle.getGenre() == 1) { + taskContractVO.setTotal(entityByStockArticle.getTotalNumber()); + taskContractVO.setZktotal(entityByStockArticle.getTotalNumber()); + } + } else if (entityByStockArticle.getIsZero().equals("0")) { + //包条 + if (entityByStockArticle.getGenre() == 1) { + //查询该订单下包条的所有数量 + Integer integer = distributionParcelListClient.SumEntityByOrderId(orderId, null); + Integer integer1 = distributionParcelListClient.SumEntityByOrderId(orderId, collect.get(0)); + taskContractVO.setTotal(integer); + taskContractVO.setZktotal(integer1); + } + } } - - } } return page.setRecords(list); } @Override public IPage selecttrayList(IPage page, TaskSearchDTO taskSearchDTO) { - List collect =this.getmyWarehouseList(); + List collect = this.getmyWarehouseList(); baseMapper.setSqlMode(); - List list = baseMapper.selecttrayList(page,taskSearchDTO,collect); - if (!list.isEmpty()){ + List list = baseMapper.selecttrayList(page, taskSearchDTO, collect); + if (!list.isEmpty()) { for (TaskTrayVO taskTrayVO : list) { //查询托盘 Integer i = warehouseTrayGoodsMapper.SumByTrayId(taskTrayVO.getTrayId()); @@ -251,7 +251,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl selectallocationDetailByStrip(IPage page, TaskSearchDTO taskSearchDTO) { //查询货位上的所有包条 - List list = warehouseUpdownGoodsMapper.selectListByTaskStrip(page,taskSearchDTO); + List list = warehouseUpdownGoodsMapper.selectListByTaskStrip(page, taskSearchDTO); for (TaskStripApiVO taskStripApiVO : list) { } @@ -260,7 +260,7 @@ public class TaskQuestServiceImpl extends BaseServiceImpl