Browse Source

Merge branch 'dev' into pre-production

newStockUp
zhenghaoyu 1 year ago
parent
commit
315e9536bd
  1. 4
      blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java
  2. 28
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml
  3. 24
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java
  4. 25
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java
  5. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockupServiceImpl.java

4
blade-service-api/logpm-distribution-api/src/main/java/com/logpm/distribution/entity/DistributionStockupEntity.java

@ -202,6 +202,10 @@ public class DistributionStockupEntity extends TenantEntity {
@ApiModelProperty(value = "仓库Id")
private Long warehouseId;
@ApiModelProperty(value = "仓库Id")
@TableField(exist = false)
private String consignee;
@ApiModelProperty(value = "仓库Id")
@TableField(exist = false)
private List<Long> warehouseIdList;

28
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionStockupMapper.xml

@ -165,7 +165,7 @@
LEFT JOIN logpm_distribution_parcel_list ldpl on ldpl.order_code = ldsl.incoming_batch
LEFT JOIN logpm_warehouse_updown_goods lwug
on lwug.association_id = ldpl.id and lwug.association_type = '3' and ldsl.warehouse_id = lwug.warehouse_id
where ldrs.id = #{param.deliveryDetailsId}
where ldrs.id = #{param.deliveryDetailsId} and lwug.allocation_id is not null
</select>
<select id="getLocationMarketSelection" resultType="com.logpm.distribution.vo.DistributionStockupTrayVO">
@ -179,7 +179,7 @@
on lwug.association_id = ldsl.material_id and lwug.association_type = '4' and
ldsl.market_id = lwug.market_id
and ldsl.incoming_batch = lwug.incoming_batch and ldsl.warehouse_id = lwug.warehouse_id
where ldrs.id = #{param.deliveryDetailsId}
where ldrs.id = #{param.deliveryDetailsId} and lwug.allocation_id is not null
</select>
<select id="getLocationSelection" resultType="com.logpm.distribution.vo.DistributionStockupTrayVO">
select lwug.position_code positionCode,
@ -192,7 +192,7 @@
on lwug.association_id = ldsl.material_id and lwug.association_type = '4' and
ldsl.market_id = lwug.market_id
and ldsl.incoming_batch = lwug.incoming_batch and ldsl.warehouse_id = lwug.warehouse_id
where lddd.id = #{param.deliveryDetailsId}
where lddd.id = #{param.deliveryDetailsId} and lwug.allocation_id is not null
GROUP BY lwug.position_code, lwug.allocation_id, lwug.allocation_title, lwug.num
</select>
<select id="getLocationSelectionOrder" resultType="com.logpm.distribution.vo.DistributionStockupTrayVO">
@ -206,7 +206,7 @@
LEFT JOIN logpm_distribution_parcel_list ldpl on ldpl.order_code = ldsl.incoming_batch
LEFT JOIN logpm_warehouse_updown_goods lwug
on lwug.association_id = ldpl.id and lwug.association_type = '3' and ldsl.warehouse_id = lwug.warehouse_id
where lddd.id = #{param.deliveryDetailsId}
where lddd.id = #{param.deliveryDetailsId} and lwug.allocation_id is not null
</select>
@ -234,10 +234,12 @@
lds.loader_name loaderName, lds.forklift_id forkliftId,lds.loader_id loaderId,lds.fix_time
fixTime,lds.assign_time assignTime,
lds.type_service typeService,lds.outbound_date outboundDate,lds.stockup_code stockupCode,
COALESCE(GROUP_CONCAT(DISTINCT lwug.position_code SEPARATOR ','), '')
stockipAllocation,COALESCE(GROUP_CONCAT(DISTINCT lwtg.tray_code SEPARATOR ','), '') pallet
COALESCE(GROUP_CONCAT(DISTINCT lwug.position_code SEPARATOR ','), '') stockipAllocation,
COALESCE(GROUP_CONCAT(DISTINCT lwtg.tray_code SEPARATOR ','), '') pallet,
COALESCE ( group_concat( DISTINCT ldr.consignee SEPARATOR ',' ), '' ) AS consignee
from logpm_distribution_stockup lds
LEFT JOIN logpm_distribution_stockup_info ldsi on ldsi.stockup_id =lds.id
LEFT JOIN logpm_distribution_reservation ldr ON ldsi.reservation_id = ldr.id
LEFT JOIN logpm_distribution_reservation_package ldrp on ldrp.reservation_id = ldsi.reservation_id
LEFT JOIN logpm_warehouse_updown_goods lwug on lwug.association_id = ldrp.parce_list_id
LEFT JOIN logpm_warehouse_tray_goods lwtg on lwtg.association_id = ldrp.parce_list_id
@ -247,6 +249,10 @@
<if test="param.typeService != null and param.typeService != '' ">and lds.type_service =
#{param.typeService}
</if>
<if test="param.consignee != null and param.consignee != '' ">and
ldr.consignee =
#{param.consignee}
</if>
<if test="param.stockupDate != null ">and TO_DAYS(lds.stockup_date)=TO_DAYS( #{param.stockupDate})</if>
<if test="param.outboundDate != null ">and TO_DAYS(lds.outbound_date)=TO_DAYS( #{param.outboundDate})</if>
<if test="param.startDate != null ">and lds.stockup_date between #{param.startDate} and #{param.entDate}
@ -325,10 +331,12 @@
lds.loader_name loaderName, lds.forklift_id forkliftId,lds.loader_id loaderId,lds.fix_time
fixTime,lds.assign_time assignTime,
lds.type_service typeService,lds.outbound_date outboundDate,lds.stockup_code stockupCode,
COALESCE(GROUP_CONCAT(DISTINCT lwug.position_code SEPARATOR ','), '')
stockipAllocation,COALESCE(GROUP_CONCAT(DISTINCT lwtg.tray_code SEPARATOR ','), '') pallet
COALESCE(GROUP_CONCAT(DISTINCT lwug.position_code SEPARATOR ','), '')stockipAllocation,
COALESCE(GROUP_CONCAT(DISTINCT lwtg.tray_code SEPARATOR ','), '') pallet,
COALESCE(GROUP_CONCAT(DISTINCT ldr.consignee SEPARATOR ','), '') consignee
from logpm_distribution_stockup lds
LEFT JOIN logpm_distribution_stockup_info ldsi on ldsi.stockup_id = lds.id
LEFT JOIN logpm_distribution_reservation ldr on ldsi.reservation_id = ldr.id
LEFT JOIN logpm_distrilbution_bill_stock ldbs on ldbs.bill_lading_id = ldsi.reservation_id
LEFT JOIN logpm_distribution_parcel_list ldpl on ldpl.stock_article_id = ldbs.stock_article_id
LEFT JOIN logpm_warehouse_tray_goods lwtg on lwtg.association_id = ldpl.id
@ -339,6 +347,10 @@
<if test="param.typeService != null and param.typeService != '' ">and lds.type_service =
#{param.typeService}
</if>
<if test="param.consignee != null and param.consignee != '' ">and
ldr.consignee =
#{param.consignee}
</if>
<if test="param.stockupDate != null ">and TO_DAYS(lds.stockup_date)=TO_DAYS( #{param.stockupDate})</if>
<if test="param.outboundDate != null ">and TO_DAYS(lds.outbound_date)=TO_DAYS( #{param.outboundDate})</if>
<if test="param.startDate != null ">and lds.stockup_date between #{param.startDate} and #{param.entDate}

24
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionDeliveryListServiceImpl.java

@ -551,7 +551,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setOrderId(parcelListEntity.getStockArticleId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setIsAbnormalLoading(1);
//出库
@ -690,7 +691,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setPackageId(parcelListEntity.getId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setOneClick(1);
loadscanEntity.setScanType("2");
@ -1443,7 +1445,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
if (Func.isEmpty(packageLoadingScan)){
DistributionLoadscanEntity loadscanEntity = new DistributionLoadscanEntity();
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setDriverName(finalDistributionDeliverySelfEntity.getDriverName());
loadscanEntity.setVehicleName(finalDistributionDeliverySelfEntity.getVehicleNub());
loadscanEntity.setScanStatus(LoadingStatusConstant.yijianzhuangche.getValue());
@ -1514,7 +1517,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity = loadscanServiceOne;
}
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setDriverName(finalDistributionDeliverySelfEntity.getDriverName());
loadscanEntity.setVehicleName(finalDistributionDeliverySelfEntity.getVehicleNub());
loadscanEntity.setScanStatus(LoadingStatusConstant.yijianzhuangche.getValue());
@ -1649,7 +1653,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
if (disStockListDetailEntity.getStockLockingStatus().equals(InventoryLoadingStatusConstant.weizhuangche.getValue())) {
DistributionLoadscaninvnEntity loadscaninvnEntity = new DistributionLoadscaninvnEntity();
BladeUser user = AuthUtil.getUser();
loadscaninvnEntity.setScanUser(user.getUserName());
// loadscaninvnEntity.setScanUser(user.getUserName());
loadscaninvnEntity.setScanUser(user.getNickName());
loadscaninvnEntity.setDriverName(distributionDeliverySelfEntity.getDriverName());
loadscaninvnEntity.setVehicleName(distributionDeliverySelfEntity.getVehicleNub());
loadscaninvnEntity.setScanStatus(LoadingStatusConstant.yijianzhuangche.getValue());
@ -4946,7 +4951,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
distributionLoadscanAbnormalEntity.setDeliveryListId(deliveryListEntity.getId());
distributionLoadscanAbnormalEntity.setReservationId(reservationEntity.getId());
distributionLoadscanAbnormalEntity.setDeliveryType(deliveryListEntity.getType());
distributionLoadscanAbnormalEntity.setScanUser(user.getUserName());
// distributionLoadscanAbnormalEntity.setScanUser(user.getUserName());
distributionLoadscanAbnormalEntity.setScanUser(user.getNickName());
distributionLoadscanAbnormalEntity.setScanTime(new Date());
distributionLoadscanAbnormalEntity.setLoadingQuantity(parcelListEntity.getQuantity());
distributionLoadscanAbnormalEntity.setPackageCode(parcelListEntity.getOrderPackageCode());
@ -5200,7 +5206,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setOrderId(parcelListDTO.getStockArticleId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setIsAbnormalLoading(1);
distributionLoadscanService.save(loadscanEntity);
@ -5250,7 +5257,8 @@ public class DistributionDeliveryListServiceImpl extends BaseServiceImpl<Distrib
loadscanEntity.setOrderId(parcelListDTO.getStockArticleId());
loadscanEntity.setScanTime(new Date());
BladeUser user = AuthUtil.getUser();
loadscanEntity.setScanUser(user.getUserName());
// loadscanEntity.setScanUser(user.getUserName());
loadscanEntity.setScanUser(user.getNickName());
loadscanEntity.setLoadingId(distrilbutionloadingscanDTO.getLoadingId());
loadscanEntity.setIsAbnormalLoading(1);
distributionLoadscanService.save(loadscanEntity);

25
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java

@ -292,6 +292,8 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
loadscanEntity.setSigningTime(simpleDateFormat.format(new Date()));
loadscanEntity.setSignforState(2);
loadscanEntity.setReceivedQuantity(loadscanEntity.getLoadedNub());
loadscanEntity.setSigningUser(AuthUtil.getUser().getNickName());
loadscanEntity.setSigningUserId(AuthUtil.getUser().getUserId());
distributionLoadscanService.updateById(loadscanEntity);
//缺少一个异步维护包件签收的方法
// distributionAsyncService.changeOrderSignforStatus(collect.get(0));
@ -349,8 +351,10 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
distributionLoadscanEntity.setOrderId(collect.get(0).getStockArticleId());
distributionLoadscanEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
distributionLoadscanEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
distributionLoadscanEntity.setScanUser(AuthUtil.getUser().getUserName());
distributionLoadscanEntity.setSigningUser(AuthUtil.getUser().getUserName());
// distributionLoadscanEntity.setScanUser(AuthUtil.getUser().getUserName());
distributionLoadscanEntity.setScanUser(AuthUtil.getUser().getNickName());
// distributionLoadscanEntity.setSigningUser(AuthUtil.getUser().getUserName());
distributionLoadscanEntity.setSigningUser(AuthUtil.getUser().getNickName());
distributionLoadscanEntity.setSigningUserId(AuthUtil.getUser().getUserId());
distributionLoadscanService.save(distributionLoadscanEntity);
//进行签收数量的修改
@ -622,8 +626,8 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
distributionLoadscanEntity.setOrderId(parcelListEntity.getStockArticleId());
distributionLoadscanEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
distributionLoadscanEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
distributionLoadscanEntity.setScanUser(AuthUtil.getUser().getUserName());
distributionLoadscanEntity.setSigningUser(AuthUtil.getUser().getUserName());
distributionLoadscanEntity.setScanUser(AuthUtil.getUser().getNickName());
distributionLoadscanEntity.setSigningUser(AuthUtil.getUser().getNickName());
distributionLoadscanEntity.setSigningUserId(AuthUtil.getUser().getUserId());
distributionLoadscanEntity.setAbnormalNote("异常签收");
//进行签收数量的修改
@ -1460,7 +1464,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
loadscaninvnEntity.setInventoryId(disStockListDetailEntity.getStockListId());
loadscaninvnEntity.setDeliveryId(distributionSignforEntity.getDeliveryId());
loadscaninvnEntity.setReservationId(distributionSignforEntity.getReservationId());
loadscaninvnEntity.setScanUser(user.getUserName());
loadscaninvnEntity.setScanUser(user.getNickName());
loadscaninvnEntity.setScanTime(new Date());
loadscaninvnEntity.setPackageNub(disStockListDetailEntity.getNum());
loadscaninvnEntity.setScanStatus(LoadingStatusConstant.yijianzhuangche.getValue());
@ -1472,7 +1476,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
loadscaninvnEntity.setReceivedQuantity(disStockListDetailEntity.getNum());
loadscaninvnEntity.setOneClick(2);
loadscaninvnEntity.setOneQclick(2);
loadscaninvnEntity.setSigningUser(user.getUserName());
loadscaninvnEntity.setSigningUser(user.getNickName());
loadscaninvnEntity.setSigningUserId(user.getUserId());
loadscaninvnEntity.setSigningTime(simpleDateFormat.format(new Date()));
@ -2599,7 +2603,8 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
loadscanEntityList.setReceivedQuantity(p.getSigningNum());
loadscanEntityList.setSignforState(LoadScanSigningStatusConstant.yiqianshou.getValue());
loadscanEntityList.setSigningTime(simpleDateFormat.format(new Date()));
loadscanEntityList.setSigningUser(AuthUtil.getUser().getUserName());
// loadscanEntityList.setSigningUser(AuthUtil.getUser().getUserName());
loadscanEntityList.setSigningUser(AuthUtil.getUser().getNickName());
loadscanEntityList.setSigningUserId(AuthUtil.getUser().getUserId());
//维护装车数量
if (p.getSigningNum() > loadscanEntityList.getLoadedNub()) {
@ -2700,8 +2705,10 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
loadscanEntity.setOrderId(p.getStockArticleId());
loadscanEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
loadscanEntity.setDeliveryId(deliveryListEntity.getId());
loadscanEntity.setScanUser(AuthUtil.getUser().getUserName());
loadscanEntity.setSigningUser(AuthUtil.getUser().getUserName());
loadscanEntity.setScanUser(AuthUtil.getUser().getNickName());
// loadscanEntity.setScanUser(AuthUtil.getUser().getUserName());
// loadscanEntity.setSigningUser(AuthUtil.getUser().getUserName());
loadscanEntity.setSigningUser(AuthUtil.getUser().getNickName());
loadscanEntity.setSigningUserId(AuthUtil.getUser().getUserId());
distributionLoadscanService.save(loadscanEntity);
//进行签收数量的修改

4
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionStockupServiceImpl.java

@ -281,7 +281,8 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
page.setSize(stockupDTO.getSize());
stockupDTO.setUserId(AuthUtil.getUserId());
stockupDTO.setStockupDateStart(stockupDTO.getStockupDateStart() + " 00:00:00");
stockupDTO.setStockupDateEnd(stockupDTO.getStockupDateEnd() + " 23:59:59");
stockupDTO.setStockupDateEnd(stockupDTO.getStockupDateEnd() + " 23:59:59")
;
// BasicdataWarehouseEntity myCurrentWarehouse = basicdataWarehouseClient.getMyCurrentWarehouse();
// if(ObjectUtils.isNotNull(myCurrentWarehouse)){
// stockupDTO.setWarehouseId(myCurrentWarehouse.getId());
@ -2051,6 +2052,7 @@ public class DistributionStockupServiceImpl extends BaseServiceImpl<Distribution
}
String packetBarCode = stockupDTO.getPacketBarCode();
Integer integer = baseMapper.selectPackageExist(stockupDTO);
//查询包件信息
if (ObjectUtils.isNotNull(integer) && integer > 0) {
//存在
queryWrapper.eq("coding",packetBarCode);

Loading…
Cancel
Save