This commit is contained in:
linfso 2025-01-03 18:21:28 +08:00
parent f25d7489ed
commit 2e8353b20b

View File

@ -1916,14 +1916,14 @@ public class EmisWaybillServiceImpl extends EmisBaseService implements IEmisWayb
// 仓库收货/整柜提货 建立入仓预报单
if("1".equals(emisWaybillSave.getPickupMethod()) || "3".equals(emisWaybillSave.getPickupMethod()) ) {
String wayhoustInNo = null;
String intoWarehouseBillCode = null;
// 旧进仓单号不变
if(oldWaybill!=null){
wayhoustInNo=oldWaybill.getWarehouseInNo();
intoWarehouseBillCode= oldWaybill.getIntoWarehouseBillCode();
}
if(StringUtils.isEmpty(wayhoustInNo)) {
if(StringUtils.isEmpty(intoWarehouseBillCode)) {
// 获取进仓单号
try {
// TAN-SMD-240603-01
@ -1931,8 +1931,8 @@ public class EmisWaybillServiceImpl extends EmisBaseService implements IEmisWayb
// String hbKey = "TAN" + "-" + simpleName +"-"+ DateUtils.parseDateToStr(YYMMDD, new Date());
String hbKey = "TAN" + "-" + simpleName + "-" + DateUtils.parseDateToStr(YYMMDD, emisWaybillSave.getPickStartDate());
Long lockNo = redissonService.addAndGetLong(hbKey, 1L);
wayhoustInNo = hbKey + "" + StringUtils.leftPad(String.valueOf(lockNo), 2, "0");
emisWaybillSave.setIntoWarehouseBillCode(wayhoustInNo);
intoWarehouseBillCode = hbKey + "" + StringUtils.leftPad(String.valueOf(lockNo), 2, "0");
emisWaybillSave.setIntoWarehouseBillCode(intoWarehouseBillCode);
// 建立入仓预报信息
EmisWarehouseIn emisWarehouseIn = new EmisWarehouseIn();