Browse Source

Merge branch 'dev' into pre-production

master
汤建军 10 months ago
parent
commit
68d2274059
  1. 6
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationZeroPackageServiceImpl.java
  2. 12
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java

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

@ -29,10 +29,12 @@ import com.logpm.distribution.mapper.DistributionReservationZeroPackageMapper;
import com.logpm.distribution.service.IDistributionParcelListService;
import com.logpm.distribution.service.IDistributionParcelNumberService;
import com.logpm.distribution.service.IDistributionReservationZeroPackageService;
import com.logpm.distribution.service.IDistributionStockArticleService;
import com.logpm.distribution.vo.DistributionReservationZeroPackageVO;
import org.springblade.common.constant.reservation.ReservationPackageStatusConstant;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Service;
import java.util.List;
@ -51,6 +53,9 @@ public class DistributionReservationZeroPackageServiceImpl extends BaseServiceIm
private DistributionParcelListMapper distributionParcelListMapper;
@Autowired
private IDistributionParcelNumberService distributionParcelNumberService;
@Autowired
@Lazy
private IDistributionStockArticleService distributionStockArticleService;
@Override
@ -118,6 +123,7 @@ public class DistributionReservationZeroPackageServiceImpl extends BaseServiceIm
distributionParcelNumberService.updateById(distributionParcelNumberEntity);
reservationZeroPackageEntity.setQuantity(0);
reservationZeroPackageEntity.setZeroPackageStatus(ReservationPackageStatusConstant.quxiao.getValue());
distributionStockArticleService.maintenanceOrderInfo(parcelListEntity.getOrderCode(),parcelListEntity.getWarehouseId());
this.updateById(reservationZeroPackageEntity);
}

12
blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistrilbutionBillLadingServiceImpl.java

@ -336,10 +336,10 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl<Distrilb
}
//修改订单数据
if (!distrilbutionBillLading.getStockArticleList().isEmpty()) {
// boolean order = getOrder(distrilbutionBillLading.getStockArticleList(), distrilbutionBillLading.getId());
// if (!order) {
// throw new ServiceException("修改失败!!");
// }
boolean order = getOrder(distrilbutionBillLading.getStockArticleList(), distrilbutionBillLading.getId());
if (!order) {
throw new ServiceException("修改失败!!");
}
List<DistributionStockArticleEntity> stockArticleList = distrilbutionBillLading.getStockArticleList();
if (Func.isNotEmpty(stockArticleList)){
String orderCodes = stockArticleList.stream().map(DistributionStockArticleEntity::getOrderCode).collect(Collectors.joining(","));
@ -650,6 +650,8 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl<Distrilb
for (DistributionParcelListEntity distrilbutionBillPackageEntity : packageMap.get(Long.parseLong(s))) {
DistrilbutionBillPackageEntity aaa = new DistrilbutionBillPackageEntity();
aaa.setBillLadingId(distrilbutionBillLading.getId());
aaa.setStockArticleId(distrilbutionBillPackageEntity.getStockArticleId());
aaa.setParceListId(distrilbutionBillPackageEntity.getId());
aaa.setPacketBarStatus(1);
aaa.setBillType("1");
aaa.setPacketNumber(distrilbutionBillPackageEntity.getQuantity());
@ -2030,7 +2032,7 @@ public class DistrilbutionBillLadingServiceImpl extends BaseServiceImpl<Distrilb
List<DistrilbutionBillPackageEntity> list3 = distrilbutionBillPackageService.list(Wrappers.<DistrilbutionBillPackageEntity>query().lambda()
.eq(DistrilbutionBillPackageEntity::getBillLadingId, distrilbutionBillLadingEntity.getId())
.ne(DistrilbutionBillPackageEntity::getPacketBarStatus, "2")
.ne(DistrilbutionBillPackageEntity::getStockArticleId, distributionStockArticleVO.getId())
.eq(DistrilbutionBillPackageEntity::getStockArticleId, distributionStockArticleVO.getId())
);
if (!list3.isEmpty()){
distributionStockArticleVO.setReservationNum(list3.size());

Loading…
Cancel
Save