From f79c71bebe44776678392b0205f5deb967468d61 Mon Sep 17 00:00:00 2001 From: mengjiao <3338049200@qq,com> Date: Thu, 23 May 2024 11:36:21 +0800 Subject: [PATCH] =?UTF-8?q?wms=E6=88=90=E5=93=81sap=E6=94=B6=E8=8E=B7?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E4=B8=AD=E8=BF=87=E8=B4=A6=E6=97=B6=E6=89=B9?= =?UTF-8?q?=E6=AC=A1=E7=9A=84=E6=88=AA=E5=8F=96=E8=A7=84=E5=88=99=E9=83=A8?= =?UTF-8?q?=E5=88=86=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../impl/WmsProductPutServiceImpl.java | 21 +++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/op-modules/op-wms/src/main/java/com/op/wms/service/impl/WmsProductPutServiceImpl.java b/op-modules/op-wms/src/main/java/com/op/wms/service/impl/WmsProductPutServiceImpl.java index 6ba5304a..a982fff0 100644 --- a/op-modules/op-wms/src/main/java/com/op/wms/service/impl/WmsProductPutServiceImpl.java +++ b/op-modules/op-wms/src/main/java/com/op/wms/service/impl/WmsProductPutServiceImpl.java @@ -487,7 +487,8 @@ public class WmsProductPutServiceImpl implements IWmsProductPutService { map.put("QUANTITY", mesReportWork.getQuantityQualified()); map.put("ERFME", mesReportWork.getUnit()); if (mesReportWork.getBatch().length()>12){ - String batch = mesReportWork.getBatch().substring(12); + //String batch = mesReportWork.getBatch().substring(12); + String batch = InterceptionRules(mesReportWork.getBatch()); map.put("BATCH", batch); }else { map.put("BATCH", mesReportWork.getBatch()); @@ -526,7 +527,7 @@ public class WmsProductPutServiceImpl implements IWmsProductPutService { map.put("QUANTITY", mesReportWork.getQuantityQualified()); map.put("ERFME", mesReportWork.getUnit()); if (mesReportWork.getBatch().length()>12){ - String batch = mesReportWork.getBatch().substring(12); + String batch = InterceptionRules(mesReportWork.getBatch()); map.put("BATCH", batch); }else { map.put("BATCH", mesReportWork.getBatch()); @@ -583,6 +584,10 @@ public class WmsProductPutServiceImpl implements IWmsProductPutService { + + + + @Override public ProOrderWorkorder selectWmsOdsWhiteEmbryoInhAnd(WmsOdsWhiteEmbryoIn wmsOdsWhiteEmbryoIns) { //pro order workorder @@ -1133,4 +1138,16 @@ public class WmsProductPutServiceImpl implements IWmsProductPutService { public List selectWmsRuturnPutEmbryoList(WmsRuturnPutEmbryo wmsRuturnPutEmbryo) { return wmsRuturnPutEmbryoMapper.selectWmsRuturnPutEmbryoList(wmsRuturnPutEmbryo); } + + + + //去除空格,截取规则,例子:20270106LJ20240107CBCD0J——》240107CBCD + public String InterceptionRules(String batchString){ + boolean containsSpace = batchString.contains(" "); + if (containsSpace) {//去除空格 + batchString = batchString.replace(" ", ""); + } + batchString =batchString.substring(12,22); + return batchString; + } }