demand: 修复虚拟单重复录入问题
committer: heyu
This commit is contained in:
parent
efd3e7f455
commit
bfd40fc09e
@ -2845,13 +2845,23 @@ public class EmisBaseService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ("002".equals(waybill.getTransLineType()) && StringUtil.isNotBlank(waybill.getVirtualRemark())) {
|
if ("002".equals(waybill.getTransLineType()) && StringUtil.isNotBlank(waybill.getVirtualRemark())) {
|
||||||
// 取每个虚拟单号的后六位,用逗号拼接
|
Date sendDate = waybill.getSendDate();
|
||||||
String[] codes = waybill.getVirtualRemark().split(",");
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||||
String shortCodes = Arrays.stream(codes)
|
Date limitDate = null;
|
||||||
.filter(s -> s != null && s.length() >= 6)
|
try {
|
||||||
.map(s -> s.substring(s.length() - 6))
|
limitDate = sdf.parse("2025-06-23 20:00:00");
|
||||||
.collect(Collectors.joining(","));
|
} catch (ParseException e) {
|
||||||
remark = remark + " " + "该运单为主单,对应虚拟单为" + shortCodes + ",";
|
// ignore
|
||||||
|
}
|
||||||
|
if (sendDate != null && limitDate != null && sendDate.after(limitDate)) {
|
||||||
|
// 取每个虚拟单号的后六位,用逗号拼接
|
||||||
|
String[] codes = waybill.getVirtualRemark().split(",");
|
||||||
|
String shortCodes = Arrays.stream(codes)
|
||||||
|
.filter(s -> s != null && s.length() >= 6)
|
||||||
|
.map(s -> s.substring(s.length() - 6))
|
||||||
|
.collect(Collectors.joining(","));
|
||||||
|
remark = remark + " " + "该运单为主单,对应虚拟单为" + shortCodes + ",";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// if (StringUtil.isNotBlank(waybill.getMasterBillCode())) {
|
// if (StringUtil.isNotBlank(waybill.getMasterBillCode())) {
|
||||||
// remark = remark + " " + "该运单为虚拟单,对应主单为" + waybill.getMasterBillCode();
|
// remark = remark + " " + "该运单为虚拟单,对应主单为" + waybill.getMasterBillCode();
|
||||||
@ -4792,6 +4802,10 @@ public class EmisBaseService {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
updateMasterWaybill(emisWaybillSave,emisWaybillOld);
|
updateMasterWaybill(emisWaybillSave,emisWaybillOld);
|
||||||
|
if ("1".equals(emisWaybillOld.getBlVirtual()
|
||||||
|
)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
// 做问题件录入
|
// 做问题件录入
|
||||||
scanProblemInfo(emisWaybillSave,emisWaybillOld);
|
scanProblemInfo(emisWaybillSave,emisWaybillOld);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user