diff --git a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataForwardingUnitClient.java b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataForwardingUnitClient.java index 423ccbf14..e1777ec52 100644 --- a/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataForwardingUnitClient.java +++ b/blade-service-api/logpm-basicdata-api/src/main/java/com/logpm/basicdata/feign/IBasicdataForwardingUnitClient.java @@ -15,6 +15,6 @@ public interface IBasicdataForwardingUnitClient { @GetMapping(API_PREFIX+"/findForwardingUnitByWarehouseId") - Long findForwardingUnitByWarehouseIdAndUserId(@RequestParam("warehouseId") Long warehouseId,@RequestParam("userId") Long userId); + Long findForwardingUnitByWarehouseId(@RequestParam("warehouseId") Long warehouseId); } diff --git a/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/ImportOrderNoPackageExcelDTO.java b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/ImportOrderNoPackageExcelDTO.java new file mode 100644 index 000000000..d65165262 --- /dev/null +++ b/blade-service-api/logpm-trunkline-api/src/main/java/com/logpm/trunkline/dto/ImportOrderNoPackageExcelDTO.java @@ -0,0 +1,42 @@ +package com.logpm.trunkline.dto; + +import com.alibaba.excel.annotation.ExcelProperty; +import lombok.Data; + +import java.io.Serializable; + +@Data +public class ImportOrderNoPackageExcelDTO implements Serializable { + + @ExcelProperty(value = "下单日期") + private String orderTime; + @ExcelProperty(value = "商场名称") + private String dealerName; + @ExcelProperty(value = "订单自编号") + private String orderCode; + @ExcelProperty(value = "销售数量") + private String num; + @ExcelProperty(value = "商场收货人") + private String consigneePerson; + @ExcelProperty(value = "商场收货人电话") + private String consigneeMobile; + @ExcelProperty(value = "商场收货地址") + private String consigneeAddress; + @ExcelProperty(value = "收货人") + private String customerName ; + @ExcelProperty(value = "联系电话") + private String customerPhone ; + @ExcelProperty(value = "地址") + private String customerAddress ; + @ExcelProperty(value = "车次") + private String trainNumber ; + @ExcelProperty(value = "发货日期") + private String sendDateStr ; + @ExcelProperty(value = "品牌") + private String brand ; + @ExcelProperty(value = "配送区域") + private String area ; + @ExcelProperty(value = "服务号") + private String serviceNum ; + +} diff --git a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/PackageListVO.java b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/PackageListVO.java index 1775340d6..5e260942a 100644 --- a/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/PackageListVO.java +++ b/blade-service-api/logpm-warehouse-api/src/main/java/com/logpm/warehouse/vo/PackageListVO.java @@ -13,5 +13,10 @@ public class PackageListVO implements Serializable { private String orderCode; private String warehouseName; private Integer num; + private String firsts; + private String seconds; + private String thirds; + private String materialName; + private String materialCode; } diff --git a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java index 220fa6585..88c2e8426 100644 --- a/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java +++ b/blade-service/logpm-basic/src/main/java/com/logpm/basic/controller/BasicMaterialController.java @@ -151,7 +151,7 @@ public class BasicMaterialController extends BladeController { if(ObjectUtil.isNull(basicMaterial.getName()) || ObjectUtil.isNull(basicMaterial.getProductCode()) || ObjectUtil.isNull(basicMaterial.getPackageNum()) || ObjectUtil.isNull(basicMaterial.getPackageNum())|| ObjectUtil.isNull(basicMaterial.getSku())|| ObjectUtil.isNull(basicMaterial.getPackingSpecification())|| - ObjectUtil.isNull(basicMaterial.getSpecification()) || ObjectUtil.isNull(basicMaterial.getLogpmUnit()) ){ + ObjectUtil.isNull(basicMaterial.getLogpmUnit()) ){ log.info("物料添加失败!"); return R.fail("添加失败,必填物料信息不完整为空!"); } diff --git a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataForwardingUnitClient.java b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataForwardingUnitClient.java index 57e8d44a5..54830d452 100644 --- a/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataForwardingUnitClient.java +++ b/blade-service/logpm-basicdata/src/main/java/com/logpm/basicdata/feign/BasicdataForwardingUnitClient.java @@ -17,10 +17,9 @@ public class BasicdataForwardingUnitClient implements IBasicdataForwardingUnitCl private final IBasicdataForwardingUnitService basicdataForwardingUnitService; @Override - public Long findForwardingUnitByWarehouseIdAndUserId(Long warehouseId, Long userId) { + public Long findForwardingUnitByWarehouseId(Long warehouseId) { QueryWrapper queryWrapper = new QueryWrapper<>(); - queryWrapper.eq("warehouse_id",warehouseId) - .eq("user_id",userId); + queryWrapper.eq("warehouse_id",warehouseId); BasicdataForwardingUnitEntity forwardingUnitEntity = basicdataForwardingUnitService.getOne(queryWrapper); if(!Objects.isNull(forwardingUnitEntity)){ diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java index 54ada61fb..3e727d00e 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/controller/OpenOrderController.java @@ -337,6 +337,39 @@ public class OpenOrderController { } } + @ResponseBody + @PostMapping("/advanceNoPackageToWaybillInfo") + @ApiOperationSupport(order = 1) + @ApiOperation(value = "暂存单转运单", notes = "传入waybillDTO") + public R advanceNoPackageToWaybillInfo(@RequestBody AdvanceDTO advanceDTO) { + String method = "############advanceNoPackageToWaybillInfo: "; + log.info(method + "请求参数{}", advanceDTO); + List advanceIds = advanceDTO.getAdvanceIds(); + try{ + + //当前登录人选择的仓库 + BasicdataWarehouseEntity myCurrentWarehouse = warehouseClient.getMyCurrentWarehouse(); + if(Objects.isNull(myCurrentWarehouse)){ + log.warn(method+"仓库信息为空 myCurrentWarehouse={}",myCurrentWarehouse); + return R.fail(403,"仓库信息为空"); + } + + if(advanceIds.isEmpty()){ + log.warn(method+"未选择暂存单 advanceIds={}",advanceIds); + return R.fail(403,"未选择暂存单"); + } + + return openOrderService.advanceNoPackageToWaybillInfo(advanceIds,myCurrentWarehouse.getId()); + }catch (CustomerException e){ + log.error(e.message,e); + return R.fail(e.code,e.message); + }catch (Exception e){ + log.error(method+"系统异常",e); + return R.fail(500,"系统异常"); + } + } + + @ResponseBody @PostMapping("/openWaybill") @ApiOperationSupport(order = 1) @@ -1163,6 +1196,10 @@ public class OpenOrderController { openOrderDTO.setWarehouseId(myCurrentWarehouse.getId()); openOrderDTO.setWarehouseName(myCurrentWarehouse.getName()); + if(Objects.isNull(waybillId)){ + log.warn(method+"运单id为空 waybillId={}",waybillId); + return R.fail(403,"运单id为空"); + } return openOrderService.checkWaybill(openOrderDTO); }catch (CustomerException e){ log.error(e.message,e); diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/IOpenOrderService.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/IOpenOrderService.java index f033a1dfe..b8f015fd4 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/IOpenOrderService.java +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/IOpenOrderService.java @@ -65,6 +65,7 @@ public interface IOpenOrderService { R checkWaybill(OpenOrderDTO openOrderDTO); + R advanceNoPackageToWaybillInfo(List advanceIds, Long warehouseId); // R findWaybillInfo(String waybillNo); diff --git a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java index 2d55a0a59..afd202771 100644 --- a/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java +++ b/blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/OpenOrderServiceImpl.java @@ -132,7 +132,7 @@ public class OpenOrderServiceImpl implements IOpenOrderService { openOrderVO.setDepartureWarehouseId(warehouseId); openOrderVO.setTotalNum(totalNum); //发货单位 - Long shipperId = basicdataForwardingUnitClient.findForwardingUnitByWarehouseIdAndUserId(warehouseId,AuthUtil.getUserId()); + Long shipperId = basicdataForwardingUnitClient.findForwardingUnitByWarehouseId(warehouseId); if(!Objects.isNull(shipperId)){ BasicdataClientEntity basicdataClientEntity = basicdataClientClient.findEntityById(shipperId); if(!Objects.isNull(basicdataClientEntity)){ @@ -774,6 +774,18 @@ public class OpenOrderServiceImpl implements IOpenOrderService { openOrderVO.setDepartureWarehouseName(basicdataWarehouseEntity.getName()); openOrderVO.setDepartureWarehouseId(warehouseId); + Long shipperId = basicdataForwardingUnitClient.findForwardingUnitByWarehouseId(warehouseId); + if(!Objects.isNull(shipperId)){ + BasicdataClientEntity basicdataClientEntity = basicdataClientClient.findEntityById(shipperId); + if(!Objects.isNull(basicdataClientEntity)){ + openOrderVO.setShipperClientId(shipperId); + openOrderVO.setShipper(basicdataClientEntity.getClientName()); + openOrderVO.setShipperName(basicdataClientEntity.getLinkman()); + openOrderVO.setShipperMobile(basicdataClientEntity.getPhone()); + openOrderVO.setShipperAddress(basicdataClientEntity.getDetailedly()); + } + } + //查询支付方式 openOrderVO.setPayTypeList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_PAY_TYPE)); //查询付款方式 @@ -1525,81 +1537,38 @@ public class OpenOrderServiceImpl implements IOpenOrderService { } InputStream inputStream = file.getInputStream(); - List orderNoPackageExcelDTOS = EasyExcel.read(inputStream).head(OrderNoPackageExcelDTO.class).sheet(0).headRowNumber(2).doReadSync(); - Map> listMap = orderNoPackageExcelDTOS.parallelStream().collect(Collectors.groupingBy(a -> a.getOrderCode() + "&" + a.getTrainNumber())); - - listMap.remove("null&null"); - - Set set = listMap.keySet(); - - for (String str : set) { - String[] split = str.split("&"); - String orderCode = split[0]; - String trainNumber = split[1]; - List noPackageExcelDTOList = listMap.get(str); - OrderNoPackageExcelDTO orderNoPackageExcelDTO = noPackageExcelDTOList.get(0); + List importOrderNoPackageExcelDTOS = EasyExcel.read(inputStream).head(ImportOrderNoPackageExcelDTO.class).sheet(0).headRowNumber(2).doReadSync(); + List list = new ArrayList<>(); + for (ImportOrderNoPackageExcelDTO importOrderNoPackageExcelDTO : importOrderNoPackageExcelDTOS) { + String orderCode = importOrderNoPackageExcelDTO.getOrderCode(); + String trainNumber = importOrderNoPackageExcelDTO.getTrainNumber(); TrunklineAdvanceEntity trunklineAdvanceEntity = advanceService.findEntityByOrderCodeAndTrainNumber(orderCode, trainNumber); if(Objects.isNull(trunklineAdvanceEntity)){ trunklineAdvanceEntity = new TrunklineAdvanceVO(); trunklineAdvanceEntity.setWarehouseId(warehouseId); trunklineAdvanceEntity.setWarehouseName(warehouseName); trunklineAdvanceEntity.setOrderCode(orderCode); - trunklineAdvanceEntity.setBrand(orderNoPackageExcelDTO.getBrand()); - trunklineAdvanceEntity.setTotalNum(Integer.parseInt(orderNoPackageExcelDTO.getNum())); - trunklineAdvanceEntity.setPackName(orderNoPackageExcelDTO.getFirsts()); - trunklineAdvanceEntity.setDealerName(orderNoPackageExcelDTO.getDealerName()); - trunklineAdvanceEntity.setCustomerName(orderNoPackageExcelDTO.getCustomerName()); - trunklineAdvanceEntity.setCustomerPhone(orderNoPackageExcelDTO.getCustomerPhone()); - trunklineAdvanceEntity.setCustomerAddress(orderNoPackageExcelDTO.getCustomerAddress()); - trunklineAdvanceEntity.setConsigneePerson(orderNoPackageExcelDTO.getConsigneePerson()); - trunklineAdvanceEntity.setConsigneeMobile(orderNoPackageExcelDTO.getConsigneeMobile()); - trunklineAdvanceEntity.setConsigneeAddress(orderNoPackageExcelDTO.getConsigneeAddress()); + trunklineAdvanceEntity.setBrand(importOrderNoPackageExcelDTO.getBrand()); + trunklineAdvanceEntity.setTotalNum(Integer.parseInt(importOrderNoPackageExcelDTO.getNum())); + trunklineAdvanceEntity.setDealerName(importOrderNoPackageExcelDTO.getDealerName()); + trunklineAdvanceEntity.setCustomerName(importOrderNoPackageExcelDTO.getCustomerName()); + trunklineAdvanceEntity.setCustomerPhone(importOrderNoPackageExcelDTO.getCustomerPhone()); + trunklineAdvanceEntity.setCustomerAddress(importOrderNoPackageExcelDTO.getCustomerAddress()); + trunklineAdvanceEntity.setConsigneePerson(importOrderNoPackageExcelDTO.getConsigneePerson()); + trunklineAdvanceEntity.setConsigneeMobile(importOrderNoPackageExcelDTO.getConsigneeMobile()); + trunklineAdvanceEntity.setConsigneeAddress(importOrderNoPackageExcelDTO.getConsigneeAddress()); trunklineAdvanceEntity.setSystemType("线上"); trunklineAdvanceEntity.setMatingType("1"); trunklineAdvanceEntity.setWaybillStatus("0"); - trunklineAdvanceEntity.setTrainNumber(orderNoPackageExcelDTO.getTrainNumber()); + trunklineAdvanceEntity.setTrainNumber(importOrderNoPackageExcelDTO.getTrainNumber()); trunklineAdvanceEntity.setFreezeStatus("0"); trunklineAdvanceEntity.setLegacyStatus("0"); trunklineAdvanceEntity.setHasPackage(0); trunklineAdvanceEntity.setCreateUserName(AuthUtil.getUserName()); - advanceService.save(trunklineAdvanceEntity); - } - - List advanceDetailEntities = new ArrayList<>(); - for (OrderNoPackageExcelDTO noPackageExcelDTO : orderNoPackageExcelDTOS) { - - TrunklineAdvanceDetailEntity advanceDetailModel = new TrunklineAdvanceDetailEntity(); - advanceDetailModel.setWarehouseId(warehouseId); - advanceDetailModel.setWarehouseName(warehouseName); - advanceDetailModel.setAdvanceId(trunklineAdvanceEntity.getId()); - advanceDetailModel.setOrderCode(orderCode); - advanceDetailModel.setBrand(noPackageExcelDTO.getBrand()); - advanceDetailModel.setSystemType("线上"); - - advanceDetailModel.setFirstPackName(noPackageExcelDTO.getFirsts()); - String sencods = noPackageExcelDTO.getSencods(); - if(StringUtil.isBlank(sencods)){ - advanceDetailModel.setSecondPackName(noPackageExcelDTO.getFirsts()); - }else{ - advanceDetailModel.setSecondPackName(sencods); - } - String thirds = noPackageExcelDTO.getThirds(); - if(StringUtil.isBlank(thirds)){ - advanceDetailModel.setThirdPackName(noPackageExcelDTO.getFirsts()); - }else{ - advanceDetailModel.setThirdPackName(thirds); - } - advanceDetailModel.setQuantity(Integer.parseInt(noPackageExcelDTO.getNum())); - advanceDetailModel.setServiceNum(noPackageExcelDTO.getServiceNum()); - advanceDetailModel.setPackageStatus("0"); - advanceDetailModel.setFirstPackName(noPackageExcelDTO.getFirsts()); - advanceDetailModel.setSecondPackName(noPackageExcelDTO.getSencods()); - advanceDetailModel.setThirdPackName(noPackageExcelDTO.getThirds()); - advanceDetailEntities.add(advanceDetailModel); + list.add(trunklineAdvanceEntity); } - advanceDetailService.saveBatch(advanceDetailEntities); - } + advanceService.saveBatch(list); return R.success("导入成功"); } @@ -1638,9 +1607,132 @@ public class OpenOrderServiceImpl implements IOpenOrderService { }catch (Exception e){ log.warn("###############checkWaybill: 存入日志失败"); } + return R.success("审核成功"); + } + @Override + public R advanceNoPackageToWaybillInfo(List advanceIds, Long warehouseId) { + log.info("##################advanceNoPackageToWaybillInfo: 暂存单转运单"); - return R.success("审核成功"); + BasicdataWarehouseEntity basicdataWarehouseEntity = basicdataWarehouseClient.getEntityWarehouseId(warehouseId); + if(Objects.isNull(basicdataWarehouseEntity)){ + log.warn("##############advanceNoPackageToWaybillInfo: 仓库信息不存在 warehouseId={}",warehouseId); + return R.fail(405,"仓库信息不存在"); + } + + //先查询出所有的暂存单 + List list = advanceService.findListByIds(advanceIds); + + if(list.isEmpty()){ + log.warn("##############advanceNoPackageToWaybillInfo: 暂存单数据不存在 advanceIds={}",advanceIds); + return R.fail(405,"暂存单数据不存在"); + } + String dealerName = null; + String brand = null; + Integer totalNum = 0; + for (TrunklineAdvanceEntity advanceEntity:list){ + if(StringUtil.isBlank(dealerName)){ + dealerName = advanceEntity.getDealerName(); + } + if(StringUtil.isBlank(brand)){ + brand = advanceEntity.getBrand(); + } + + totalNum = totalNum + advanceEntity.getTotalNum(); + } + OpenOrderVO openOrderVO = new OpenOrderVO(); + //查询品牌 客户车次号 订单自编码 + OpenOrderVO infoByIds = advanceService.selectInfoByIds(advanceIds); + BeanUtil.copy(infoByIds,openOrderVO); + openOrderVO.setAdvanceIds(advanceIds); + //发站仓-----目前登录人的仓库 + openOrderVO.setDepartureWarehouseName(basicdataWarehouseEntity.getName()); + openOrderVO.setDepartureWarehouseId(warehouseId); + openOrderVO.setTotalNum(totalNum); + //发货单位 + Long shipperId = basicdataForwardingUnitClient.findForwardingUnitByWarehouseId(warehouseId); + if(!Objects.isNull(shipperId)){ + BasicdataClientEntity basicdataClientEntity = basicdataClientClient.findEntityById(shipperId); + if(!Objects.isNull(basicdataClientEntity)){ + openOrderVO.setShipperClientId(shipperId); + openOrderVO.setShipper(basicdataClientEntity.getClientName()); + openOrderVO.setShipperName(basicdataClientEntity.getLinkman()); + openOrderVO.setShipperMobile(basicdataClientEntity.getPhone()); + openOrderVO.setShipperAddress(basicdataClientEntity.getDetailedly()); + } + } + + + //收货单位-----根据三方商场找到对应的clientId + Long clientId = basicdataTripartiteMallClient.getClientIdByNameAndBrand(dealerName, brand); + BasicdataClientEntity basicdataClientEntity = basicdataClientClient.findEntityById(clientId); + if(!Objects.isNull(basicdataClientEntity)){ + openOrderVO.setConsigneeClientId(clientId); + openOrderVO.setConsignee(basicdataClientEntity.getClientName()); + openOrderVO.setConsigneeName(basicdataClientEntity.getLinkman()); + openOrderVO.setConsigneeMobile(basicdataClientEntity.getPhone()); + openOrderVO.setConsigneeAddress(basicdataClientEntity.getDetailedly()); + + List destinationArray = new ArrayList<>(); + String badeRegionAreaId = basicdataClientEntity.getBladeRegionAreaId(); + String bladeRegionProvinceId = basicdataClientEntity.getBladeRegionProvinceId(); + String bladeRegionCityId = basicdataClientEntity.getBladeRegionCityId(); + destinationArray.add(bladeRegionProvinceId); + destinationArray.add(bladeRegionCityId); + String name = regionFeign.getName(bladeRegionCityId); + String areaId = bladeRegionCityId; + if(!StringUtil.isBlank(badeRegionAreaId)){ + destinationArray.add(badeRegionAreaId); + name = regionFeign.getName(badeRegionAreaId); + areaId = badeRegionAreaId; + } + + openOrderVO.setDestination(name); + openOrderVO.setDestinationCode(areaId); + openOrderVO.setDestinationArray(destinationArray); + + openOrderVO.setDefaultPayWay(basicdataClientEntity.getDefaultPaymentMethods()); + + //查询目的仓数据 + BasicdataStorageServicesEntity basicdataStorageServicesEntity = basicdataStorageServicesClient.findEntityBySendWarehouseIdAndClientId(warehouseId, clientId); + if(!Objects.isNull(basicdataStorageServicesEntity)){ + openOrderVO.setDestinationWarehouseId(basicdataStorageServicesEntity.getServeWarehouseId()); + openOrderVO.setDestinationWarehouseName(basicdataStorageServicesEntity.getServeWarehouseName()); + } + } + + //组装货物数据 +// List goodsList = advanceDetailService.findGoodsListByAdvanceIds(advanceIds); + //因为这个时候还没有到站信息,所有无法去匹配一个该商场的货物单价 +// for (AdvanceDetailGoodsVO advanceDetailGoodsVO:goodsList){ +// String goodsName = advanceDetailGoodsVO.getGoodsName(); +// if(!Objects.isNull(basicdataClientEntity)){ +// //TODO 这里要根据商场信息和物品名称去匹配一个预设单价 +// advanceDetailGoodsVO.setPrice(BigDecimal.ZERO); +// }else{ +// //因为没有 +// } +// } +// openOrderVO.setGoodsList(goodsList); + + //查询支付方式 + openOrderVO.setPayTypeList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_PAY_TYPE)); + //查询付款方式 + openOrderVO.setPayWayList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_PAY_WAY)); + //查询送货方式 + openOrderVO.setDeliveryWayList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_DELIVERY_WAY)); + //查询紧急度 + openOrderVO.setUrgencyList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_URGENCY)); + //查询回单方式 + openOrderVO.setReceiptList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_RECEIPT)); + //查询回单方式 + openOrderVO.setTransportTypeList(DictBizCache.getList(DictBizConstant.OPEN_ORDER_TRANSPORT_TYPE)); + + openOrderVO.setOpenOrderUserName(AuthUtil.getNickName()); + + openOrderVO.setOpenOrderDate(CommonUtil.dateToStringGeneral(new Date())); + + return R.data(openOrderVO); } private String verifyData(OpenOrderDTO openOrderDTO, WarehouseWaybillEntity waybillEntity) { diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTrayGoodsMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTrayGoodsMapper.xml index fcdff55e6..a69ee4162 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTrayGoodsMapper.xml +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseTrayGoodsMapper.xml @@ -387,7 +387,12 @@ ldpl.waybill_number waybillNo, ldpl.order_code orderCode, ldpl.warehouse warehouseName, - lwtg.num num + lwtg.num num, + ldpl.firsts firsts, + ldpl.second seconds, + ldpl.third_product thirds, + ldpl.material_name materialName, + ldpl.material_code materialCode from logpm_warehouse_tray_goods lwtg left join logpm_distribution_parcel_list ldpl on ldpl.order_package_code = lwtg.association_value where lwtg.tray_code = #{trayCode} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml index 2cf8257b8..b67791569 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/mapper/WarehouseUpdownGoodsMapper.xml @@ -431,7 +431,12 @@ ldpl.waybill_number waybillNo, ldpl.order_code orderCode, ldpl.warehouse warehouseName, - lwug.num num + lwug.num num, + ldpl.firsts firsts, + ldpl.second seconds, + ldpl.third_product thirds, + ldpl.material_name materialName, + ldpl.material_code materialCode from logpm_warehouse_updown_goods lwug left join logpm_distribution_parcel_list ldpl on ldpl.order_package_code = lwug.association_value where lwug.allocation_id = #{allocationId} diff --git a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java index 448342a97..8e8dcac17 100644 --- a/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java +++ b/blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseWaybillServiceImpl.java @@ -704,6 +704,14 @@ public class WarehouseWaybillServiceImpl extends BaseServiceImpl pageList = baseMapper.pageList(page,waybillDTO); + List records = pageList.getRecords(); + for (WarehouseWaybillVO record : records) { + Long waybillId = record.getId(); + List wayBillDetailList = warehouseWayBillDetailService.findByWaybillId(waybillId); + record.setDetailList(wayBillDetailList); + } + pageList.setRecords(records); + return pageList; } diff --git a/pom.xml b/pom.xml index 3a4c8218b..5a7f5cf19 100644 --- a/pom.xml +++ b/pom.xml @@ -205,7 +205,7 @@ logpm logpm - http://192.168.10.46:8081/repository/maven-public/ + http://192.168.2.46:8081/repository/maven-public/ aliyun-repos