Browse Source

批量转备货任务增加限制

dist.1.3.0
汤建军 9 months ago
parent
commit
de6a85db41
  1. 13
      blade-service/logpm-distribution/src/main/java/com/logpm/distribution/service/impl/DistributionReservationServiceImpl.java

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

@ -1005,6 +1005,19 @@ public class DistributionReservationServiceImpl extends BaseServiceImpl<Distribu
String errorReservationCode = yijingbeihuo.stream().map(DistributionReservationEntity::getReservationCode).collect(Collectors.joining(","));
return R.fail("预约单号:"+errorReservationCode+"已经提交过备货任务!!!");
}
List<Long> idsList = distributionReservationEntities.stream().map(DistributionReservationEntity::getId).collect(Collectors.toList());
List<DistributionStockupInfoEntity> entityList = distributionStockupInfoService.list(Wrappers.<DistributionStockupInfoEntity>query().lambda()
.in(DistributionStockupInfoEntity::getReservationId, idsList)
.ne(DistributionStockupInfoEntity::getStockStatus, "4")
);
if (!entityList.isEmpty()){
List<Long> stockIds = entityList.stream().map(DistributionStockupInfoEntity::getStockupId).collect(Collectors.toList());
log.info("批量转备货任务勾选预约存在备货任务>>>>>>>>>>>>>>>>>>>>>>>>>>>>reservationIds:{},stockIds:{}",idsList,stockIds);
List<DistributionStockupEntity> distributionStockupEntities = distributionStockupService.listByIds(stockIds);
String code = distributionStockupEntities.stream().map(DistributionStockupEntity::getStockupCode).collect(Collectors.joining(","));
return R.fail("勾选预约存在备货任务:"+code);
}
}
try {
//获取前端携带批量转备货的id

Loading…
Cancel
Save