| | |
| | | import com.ruoyi.system.mapper.*; |
| | | import com.ruoyi.system.model.*; |
| | | import com.ruoyi.system.query.TClinicGoodsWarehouseQuery; |
| | | import com.ruoyi.system.query.TErpGoodsAdminQuery; |
| | | import com.ruoyi.system.query.TErpGoodsInventoryQuery; |
| | | import com.ruoyi.system.query.TErpGoodsQuery; |
| | | import com.ruoyi.system.service.TErpGoodsService; |
| | |
| | | } |
| | | |
| | | pageInfo.setRecords(list); |
| | | return pageInfo; |
| | | } |
| | | |
| | | @Override |
| | | public PageInfo<TErpGoodsVO> pageAdminList(TErpGoodsAdminQuery query) { |
| | | PageInfo<TErpGoodsVO> pageInfo = new PageInfo<>(query.getPageNum(), query.getPageSize()); |
| | | List<TErpGoodsVO> list = this.baseMapper.pageAdminList(query, pageInfo); |
| | | if (list.isEmpty()) { |
| | | return pageInfo; |
| | | } |
| | | List<String> typeIds = list.stream().map(TErpGoods::getTypeId).collect(Collectors.toList()); |
| | | if (!typeIds.isEmpty()) { |
| | | List<TErpGoodsType> typeList = erpGoodsTypeMapper.selectBatchIds(typeIds); |
| | | for (TErpGoodsVO tErpGoodsVO : list) { |
| | | typeList.stream().filter(t -> t.getId().equals(tErpGoodsVO.getTypeId())).findFirst().ifPresent(t -> tErpGoodsVO.setTypeName(t.getTypeName())); |
| | | } |
| | | } |
| | | pageInfo.setRecords( list); |
| | | return pageInfo; |
| | | } |
| | | |
| | |
| | | outboundGoodsDetailVo.setCreateBy(tErpClinicOutbound.getCreateBy()); |
| | | outboundGoodsDetailVo.setOutboundType(tErpClinicOutbound.getOutboundType()); |
| | | outboundGoodsDetailVo.setOrderNumber(tErpClinicOutbound.getOrderNumber()); |
| | | outboundGoodsDetailVo.setOutboundReason(tErpClinicOutbound.getOutboundReason()); |
| | | if(tErpClinicOutbound.getOutboundType()==6){ |
| | | TErpClinicInventory tErpClinicInventory = erpClinicInventoryMapper.selectById(tErpClinicOutbound.getInventoryId()); |
| | | outboundGoodsDetailVo.setInventoryNumber(tErpClinicInventory.getInventoryNumber()); |
| | |
| | | outboundGoodsDetailNextVo.setWarehouseNo(tErpClinicWarehousing.getWarehouseNo()); |
| | | |
| | | outboundGoodsDetailNextVo.setGoodsId(outboundGoods.getGoodsId()); |
| | | TErpGoods goods = erpGoodsMapper.selectById(outboundGoods.getGoodsId()); |
| | | TErpGoods goods = erpGoodsMapper.getGoodsById(outboundGoods.getGoodsId()); |
| | | outboundGoodsDetailNextVo.setGoodsName(goods.getGoodsName()); |
| | | |
| | | outboundGoodsDetailNextVo.setTypeId(goods.getTypeId()); |