Browse Source

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

dev
汤建军 2 months ago
parent
commit
7900e8f387
  1. 23
      blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java

23
blade-service/logpm-warehouse/src/main/java/com/logpm/warehouse/service/impl/WarehouseTrayTypeServiceImpl.java

@ -1042,6 +1042,29 @@ public class WarehouseTrayTypeServiceImpl extends BaseServiceImpl<WarehouseTrayT
@Override
public R orderScanOrderPackageCodeSyncJd(Long trayId,String trayType, String trayCode,String trayName, String orderPackageCode, Long warehouseId) {
QueryWrapper<WarehouseTrayGoodsEntity> qw = new QueryWrapper<>();
qw.eq("association_value", orderPackageCode);
WarehouseTrayGoodsEntity trayGoodsEntity = warehouseTrayGoodsService.getOne(qw);
if (!Objects.isNull(trayGoodsEntity)) {
String oldTrayCode = trayGoodsEntity.getTrayCode();
if (oldTrayCode.equals(trayCode)) {
log.warn("##############orderScanOrderPackageCode: 该包条已打托 trayCode={}", trayCode);
return R.fail(4001, "该包条已打托");
}
log.warn("#########orderScanOrderPackageCode: 包件已打托 orderPackageCode={}", orderPackageCode);
// 需要告知这个托盘名称
BasicdataTrayEntity trayByTray = basicdataTrayClient.getTrayByTrayCode(oldTrayCode);
if(!Objects.isNull(trayByTray)){
return R.fail(4002, "包件已在"+trayByTray.getPalletName()+"进行打托");
}else{
return R.fail(4002, "包件已在"+trayGoodsEntity.getTrayCode()+"进行打托");
}
}
DistributionParcelListEntity parcelListEntity = distributionParcelListClient.findByPacketBarCodeAndWarehouseId(orderPackageCode, warehouseId);
if (Objects.isNull(parcelListEntity)) {
log.warn("##############orderScanOrderPackageCodeSyncJd: 包件不存在 orderPackageCode={} warehouseId={}", orderPackageCode, warehouseId);

Loading…
Cancel
Save