Browse Source

Merge remote-tracking branch 'origin/fix_bug_20240104' into fix_bug_20240104

single_db
Diss 1 year ago
parent
commit
a02db17064
  1. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml
  2. 2
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml
  3. 6
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java
  4. 4
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionSignforServiceImpl.java

4
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryInfoMapper.xml

@ -121,7 +121,7 @@
logpm_distribution_signfor lds
JOIN logpm_distribution_reservation ldr ON ldr.id = lds.reservation_id
<where>
lds.is_deleted = 0 and lds.delivery_id = #{id} and ldr.reservation_status != 40
lds.is_deleted = 0 and lds.delivery_id = #{id} and ldr.reservation_status != 40 AND (ldr.reservation_num + ldr.reservation_stock_list_num) > 0
</where>
</select>
<select id="selectDistributionDeliverywrapInfoPage"
@ -678,7 +678,7 @@ FROM
logpm_distribution_signfor lds
JOIN logpm_distribution_reservation ldr ON ldr.id = lds.reservation_id
<where>
lds.is_deleted = 0 and lds.delivery_id = #{id} and ldr.reservation_status != 40
lds.is_deleted = 0 and lds.delivery_id = #{id} and ldr.reservation_status != 40 AND (ldr.reservation_num + ldr.reservation_stock_list_num) > 0
<if test="param.reservationCode != '' and param.reservationCode != null">
and ldr.reservation_code like concat('%',#{param.reservationCode},'%')
</if>

2
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/mapper/DistributionDeliveryListMapper.xml

@ -210,7 +210,7 @@
left JOIN logpm_distribution_signfor lds on lddl.id = lds.delivery_id
LEFT JOIN logpm_distribution_reservation ldr on ldr.id = lds.reservation_id
<where>
lddl.is_deleted = 0
lddl.is_deleted = 0 AND (IF(lddl.delivery_number is null ,0,lddl.delivery_number) + IF(lddl.inventory_nub is null ,0,lddl.inventory_nub)) > 0
<if test="param.trainNumber != null and param.trainNumber!=''">
and lddl.train_number like concat('%',#{param.trainNumber},'%')
</if>

6
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java

@ -3626,9 +3626,9 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
public void maintenanceReservationNum(Long reservationId) {
DistributionReservationEntity reservationEntity = this.getById(reservationId);
if (Func.isNotEmpty(reservationEntity)){
List<DistributionReservationStockarticleEntity> distributionReservationStockarticleEntities = distributionReservationMapper.selectStockArticleByReservationId(reservationId);
if (Func.isNotEmpty(distributionReservationStockarticleEntities)){
int sum = distributionReservationStockarticleEntities.stream().mapToInt(DistributionReservationStockarticleEntity::getReservationNum).sum();
List<DistributionParcelListEntity> distributionParcelListEntities = distributionReservationMapper.selectPackageListByReservationId(reservationId);
if (Func.isNotEmpty(distributionParcelListEntities)){
int sum = distributionParcelListEntities.stream().mapToInt(DistributionParcelListEntity::getQuantity).sum();
reservationEntity.setReservationNum(sum);
}
List<DistributionReservationStocklistEntity> reservationStocklistEntities = distributionReservationMapper.selectStockListByReservationId(reservationId);

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

@ -504,7 +504,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
}
if (Func.isEmpty(distrilbutionloadingscanDTO.getBarcodes())){
log.error(method+"barCode参数缺失");
return R.fail("请联系管理员!!!");
return R.fail("此库存品暂未进行备货,请联系管理员!!!");
}
String[] split = distrilbutionloadingscanDTO.getBarcodes().split(",");
List<DisStockListDetailEntity> detailEntities = distributionReservationMapper.selectInventoryListByReservation(distrilbutionloadingscanDTO.getReservationId());
@ -569,6 +569,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
distributionLoadscaninvnEntity.setLoadingId(distributionDeliverySelfEntity.getId().toString());
distributionLoadscaninvnEntity.setOrderPackageCode(inventoryPackage.get(0).getStockPackageCode());
distributionLoadscaninvnEntity.setInventoryId(inventoryPackage.get(0).getStockListId());
distributionLoadscaninvnEntity.setInventoryPackageId(inventoryPackage.get(0).getId());
distributionLoadscaninvnEntity.setDeliveryId(distrilbutionloadingscanDTO.getDeliveryId());
distributionLoadscaninvnEntity.setReservationId(distrilbutionloadingscanDTO.getReservationId());
distributionLoadscaninvnEntity.setScanUser(user.getNickName());
@ -598,6 +599,7 @@ public class DistributionSignforServiceImpl extends BaseServiceImpl<Distribution
//修改对应库存品包件的签收数量
DisStockListDetailEntity disStockListDetailEntity = inventoryPackage.get(0);
disStockListDetailEntity.setStockSignfoStatus(InventorySigningStatusConstant.yiqianshou.getValue());
disStockListDetailEntity.setStockLockingStatus(InventoryLoadingStatusConstant.yizhuangche.getValue());
disStockListDetailService.updateById(disStockListDetailEntity);
}else {
//出现不属于当前客户的库存品包件信息

Loading…
Cancel
Save