Browse Source

1.干线bug修复

fix-sign
zhenghaoyu 4 months ago
parent
commit
7e1c80ae5a
  1. 17
      blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java

17
blade-service/logpm-trunkline/src/main/java/com/logpm/trunkline/service/impl/TrunklineCarsLoadServiceImpl.java

@ -2582,10 +2582,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
entity -> entity.getOrderCode() + "-" + entity.getWaybillNo(), // 复合键
entity -> entity,
(existing, replacement) -> existing // 保留第一个出现的元素
))
.values()
.stream()
.collect(Collectors.toList());
)).values().stream().collect(Collectors.toList());
log.info("##############saveNew: loadId={} 处理后新增的订单集合 {}",loadId,distinctList);
@ -6511,9 +6508,19 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
map.put("trayName", basicdataTrayEntity.getPalletName());
map.put("warehouseId", warehouseId);
map.put("orderPackageCode", orderPackageCode);
String key = "unloadTrayAllOne:"+orderPackageCode;
Boolean exists = bladeRedis.exists(key);
if(exists){
log.warn("##########unloadTrayAllOne: 包件正在打托,请勿重复操作 trayCode={} orderPackageCode={} ", trayCode, orderPackageCode);
return R.fail(405, "包件正在打托,请勿重复操作");
}
bladeRedis.setEx(key,1,2L);
R r = trayTypeClient.orderScanOrderPackageCodeSyncJd(map);
int code = r.getCode();
if (code != 200) {
bladeRedis.del(key);
log.warn("##########unloadTrayAllOne: 打托失败 trayCode={} orderPackageCode={} msg={}", trayCode, orderPackageCode, r.getMsg());
return R.fail(code, r.getMsg());
}else{
@ -6525,7 +6532,7 @@ public class TrunklineCarsLoadServiceImpl extends BaseServiceImpl<TrunklineCarsL
}
DistributionParcelListEntity parcelListEntity = distributionParcelListClient.findByPacketBarCodeAndWarehouseId(orderPackageCode, warehouseId);
orders = parcelListEntity.getOrderCode();
bladeRedis.del(key);
} else {
if(CollUtil.isEmpty(zeroPackageList)){

Loading…
Cancel
Save