Browse Source

Merge branch 'dev' into pre-production

master
zhaoqiaobo 9 months ago
parent
commit
a4689a86d3
  1. 5
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionBillOrderPackExcel.java
  2. 24
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml
  3. 21
      blade-service/logpm-factory-data/logpm-factory-data-suofeiya/src/main/java/com/logpm/factorydata/suofeiya/mq/FactoryOrderListener.java

5
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/excel/DistributionBillOrderPackExcel.java

@ -28,12 +28,15 @@ public class DistributionBillOrderPackExcel {
@ExcelProperty("包件码") @ExcelProperty("包件码")
private String orderPackageCode; private String orderPackageCode;
@ColumnWidth(20) @ColumnWidth(20)
@ExcelProperty("客户车次号") @ExcelProperty("自提批次号")
private String trainNumber; //客户车次号 private String trainNumber; //客户车次号
@ColumnWidth(20) @ColumnWidth(20)
@ExcelProperty("订单自编号") @ExcelProperty("订单自编号")
private String orderCode; private String orderCode;
@ColumnWidth(20) @ColumnWidth(20)
@ExcelProperty("包件状态")
private String orderPackageStatusName;
@ColumnWidth(20)
@ExcelProperty("仓库") @ExcelProperty("仓库")
private String sendWarehouseName; private String sendWarehouseName;
@ColumnWidth(20) @ColumnWidth(20)

24
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistrilbutionBillStockMapper.xml

@ -158,7 +158,6 @@
</select> </select>
<select id="getBillOrderPack" resultType="com.logpm.distribution.vo.DistributionBillOrderPackVO"> <select id="getBillOrderPack" resultType="com.logpm.distribution.vo.DistributionBillOrderPackVO">
SELECT SELECT
lds.outbound_type,
ldpl.order_package_code orderPackageCode, ldpl.order_package_code orderPackageCode,
ldpl.warehouse, ldpl.warehouse,
ldpl.id, ldpl.id,
@ -167,14 +166,14 @@
ldpl.third_product thirdProduct, ldpl.third_product thirdProduct,
ldpl.material_code materialCode, ldpl.material_code materialCode,
ldpl.material_name materialName, ldpl.material_name materialName,
ldpl.train_number trainNumber, ldbl.pickup_batch AS trainNumber,
ldpl.waybill_number waybillNumber, ldpl.waybill_number waybillNumber,
ldpl.send_warehouse_name sendWarehouseName, ldpl.send_warehouse_name sendWarehouseName,
ldpl.order_code orderCode, ldpl.order_code orderCode,
ldpl.service_number serviceNumber, ldpl.service_number serviceNumber,
lwtg.tray_code pallet, lwtg.tray_code pallet,
lwug.allocation_title goodsAllocation, lwug.allocation_title goodsAllocation,
ldpl.order_package_status orderPackageStatus , ldpl.order_package_status orderPackageStatus,
case case
when lds.id is null then '未备货' when lds.id is null then '未备货'
else '已备货' else '已备货'
@ -296,12 +295,12 @@
<select id="billOrderPackExcel" resultType="com.logpm.distribution.excel.DistributionBillOrderPackExcel"> <select id="billOrderPackExcel" resultType="com.logpm.distribution.excel.DistributionBillOrderPackExcel">
SELECT SELECT
lds.outbound_type,
ldpl.order_package_code orderPackageCode, ldpl.order_package_code orderPackageCode,
ldpl.warehouse, ldpl.warehouse,
ldpl.firsts, ldpl.firsts,
ldpl.SECOND, ldpl.SECOND,
ldpl.third_product thirdProduct, ldpl.third_product thirdProduct,
ldbl.pickup_batch AS trainNumber,
ldpl.material_code materialCode, ldpl.material_code materialCode,
ldpl.material_name materialName, ldpl.material_name materialName,
ldpl.waybill_number waybillNumber, ldpl.waybill_number waybillNumber,
@ -322,10 +321,23 @@
ldbls.create_user stockupCreateUser, ldbls.create_user stockupCreateUser,
ldbl.pick_up_time stockuppickUpTime, ldbl.pick_up_time stockuppickUpTime,
ldbls.create_time signForCreateTime, ldbls.create_time signForCreateTime,
case CASE
ldpl.order_package_status
WHEN 10 THEN
'未入库'
WHEN 20 THEN
'已入库'
WHEN 30 THEN
'中转入库'
WHEN 60 THEN
'已出库'
WHEN 70 THEN
'已签收' ELSE '未知'
END orderPackageStatusName,
CASE
WHEN ldbl.conditions = 30 THEN ldbl.update_user WHEN ldbl.conditions = 30 THEN ldbl.update_user
end as clerkCheck, end as clerkCheck,
case CASE
WHEN ldbl.conditions = 30 THEN ldbl.update_time WHEN ldbl.conditions = 30 THEN ldbl.update_time
end as clerkUpdateTime end as clerkUpdateTime
FROM logpm_distrilbution_bill_lading ldbl FROM logpm_distrilbution_bill_lading ldbl

21
blade-service/logpm-factory-data/logpm-factory-data-suofeiya/src/main/java/com/logpm/factorydata/suofeiya/mq/FactoryOrderListener.java

@ -189,16 +189,25 @@ public class FactoryOrderListener {
// 组装暂存单数据 // 组装暂存单数据
List<JSONObject> advances = new ArrayList<>(); List<JSONObject> advances = new ArrayList<>();
for (OrderInfoVO orderInfoVO : details) { for (OrderInfoVO orderInfoVO : details) {
List<JSONObject> packageList = new ArrayList<>();
if (CollUtil.isEmpty(advanceMap)) {
return;
}
List<PackageInfoVO> packageInfoVOS = advanceMap.get(orderInfoVO.getOrderNo());
if (ObjectUtil.isEmpty(packageInfoVOS)) {
return;
}
TrunklineAdvanceEntity advanceEntity = new TrunklineAdvanceEntity(); TrunklineAdvanceEntity advanceEntity = new TrunklineAdvanceEntity();
advanceEntity.setTenantId(tenantId); advanceEntity.setTenantId(tenantId);
advanceEntity.setStatus(0); advanceEntity.setStatus(0);
advanceEntity.setIsDeleted(0); advanceEntity.setIsDeleted(0);
advanceEntity.setHasPackage(CollUtil.isNotEmpty(vo.getPackageInfo()) ? 1 : 0); advanceEntity.setHasPackage(CollUtil.isNotEmpty(packageInfoVOS) ? 1 : 0);
advanceEntity.setOrderType(vo.getOrderType()); advanceEntity.setOrderType(vo.getOrderType());
advanceEntity.setBrand(BrandEnums.SFY.getValue()); advanceEntity.setBrand(BrandEnums.SFY.getValue());
advanceEntity.setSiteName(""); advanceEntity.setSiteName("");
advanceEntity.setArea(""); advanceEntity.setArea("");
advanceEntity.setTotalNum(CollUtil.isNotEmpty(vo.getPackageInfo()) ? vo.getPackageInfo().size() : 0); advanceEntity.setTotalNum(CollUtil.isNotEmpty(packageInfoVOS) ? packageInfoVOS.size() : 0);
advanceEntity.setPackName(""); advanceEntity.setPackName("");
advanceEntity.setPackCode(""); advanceEntity.setPackCode("");
advanceEntity.setWarehouseId(startWarehouseId); advanceEntity.setWarehouseId(startWarehouseId);
@ -220,14 +229,6 @@ public class FactoryOrderListener {
advanceEntity.setSenderFactory(vo.getSendAddr()); advanceEntity.setSenderFactory(vo.getSendAddr());
List<JSONObject> packageList = new ArrayList<>();
if (CollUtil.isEmpty(advanceMap)) {
return;
}
List<PackageInfoVO> packageInfoVOS = advanceMap.get(orderInfoVO.getOrderNo());
if (ObjectUtil.isEmpty(packageInfoVOS)) {
return;
}
for (PackageInfoVO orderPackageDTO : packageInfoVOS) { for (PackageInfoVO orderPackageDTO : packageInfoVOS) {
advanceEntity.setDealerCode(orderPackageDTO.getDealerNo()); advanceEntity.setDealerCode(orderPackageDTO.getDealerNo());
advanceEntity.setDealerName(orderPackageDTO.getDealerName()); advanceEntity.setDealerName(orderPackageDTO.getDealerName());

Loading…
Cancel
Save