diff --git a/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesPackageExtService.java b/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesPackageExtService.java index eeeca27..b09d312 100644 --- a/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesPackageExtService.java +++ b/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesPackageExtService.java @@ -1,6 +1,7 @@ package cn.estsh.i3plus.ext.mes.pcn.api.busi; import cn.estsh.i3plus.pojo.mes.bean.MesPackage; +import cn.estsh.i3plus.pojo.mes.bean.MesPackageDetail; import io.swagger.annotations.ApiOperation; /** @@ -15,4 +16,16 @@ public interface IMesPackageExtService { @ApiOperation(value = "根据ID查询包装信息") MesPackage getMesPackage(String organizeCode, Long id); + @ApiOperation(value = "根据包装条码查询包装信息") + MesPackage getPackageDb(String organizeCode, String packageNo); + + @ApiOperation(value = "根据包装条码查询一条包装明细信息") + MesPackageDetail getPackageDetailByPackageNo(String organizeCode, String packageNo); + + @ApiOperation(value = "根据零件条码查询一条包装明细信息") + MesPackageDetail getPackageDetailByProductSn(String organizeCode, String productSn); + + @ApiOperation(value = "根据零件条码及字段名称查询一条包装明细信息") + MesPackageDetail getPackageDetailByProductSnWithProperty(String organizeCode, String productSn, String propertyName); + } diff --git a/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesProduceSnPrintService.java b/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesProduceSnPrintService.java index 8368a66..a272222 100644 --- a/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesProduceSnPrintService.java +++ b/modules/i3plus-ext-mes-pcn-api/src/main/java/cn/estsh/i3plus/ext/mes/pcn/api/busi/IMesProduceSnPrintService.java @@ -28,4 +28,7 @@ public interface IMesProduceSnPrintService { @ApiOperation(value = "打印队列查询") List findMesPrintQueueList(MesPrintQueue printQueue); + + @ApiOperation(value = "根据包装条码或者零件条码补打印包装条码") + MesProduceSnPrintModel doRePrintPackByPackageNoOrProductSn(MesProduceSnPrintModel mesProduceSnPrintModel); } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/MesProduceSnPrintController.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/MesProduceSnPrintController.java index 60e3d4a..8419c4b 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/MesProduceSnPrintController.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/controller/busi/MesProduceSnPrintController.java @@ -175,4 +175,20 @@ public class MesProduceSnPrintController { } } + @PostMapping("/by-packageno-or-productsn/reprint-pack") + @ApiOperation(value = "根据包装条码或者零件条码补打印包装条码") + public ResultBean doRePrintPackByPackageNoOrProductSn(MesProduceSnPrintModel mesProduceSnPrintModel) { + try { + ValidatorBean.checkNotNull(mesProduceSnPrintModel.getPackageNo(), "包装条码不能为空"); + ValidatorBean.checkNotNull(mesProduceSnPrintModel.getOrganizeCode(), "工厂代码不能为空"); + ValidatorBean.checkNotNull(mesProduceSnPrintModel.getUserName(), "操作人不能为空"); + return ResultBean.success("查询成功").setResultObject(mesProduceSnPrintService.doRePrintPackByPackageNoOrProductSn(mesProduceSnPrintModel)); + } catch (ImppBusiException imppException) { + return ResultBean.fail(imppException); + } catch (Exception e) { + return ImppExceptionBuilder.newInstance().buildExceptionResult(e); + } + } + + } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesPackageExtService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesPackageExtService.java index fc24bf7..3856d32 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesPackageExtService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesPackageExtService.java @@ -2,11 +2,16 @@ package cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.busi; import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesPackageExtService; import cn.estsh.i3plus.ext.mes.pcn.pojo.util.MesPcnExtConstWords; +import cn.estsh.i3plus.pojo.base.bean.DdlPackBean; import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil; +import cn.estsh.i3plus.pojo.base.tool.DdlPreparedPack; import cn.estsh.i3plus.pojo.mes.bean.MesPackage; +import cn.estsh.i3plus.pojo.mes.bean.MesPackageDetail; +import cn.estsh.i3plus.pojo.mes.repository.MesPackageDetailRepository; import cn.estsh.i3plus.pojo.mes.repository.MesPackageRepository; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import org.springframework.util.StringUtils; /** * @Description : 包装信息 @@ -21,10 +26,48 @@ public class MesPackageExtService implements IMesPackageExtService { @Autowired private MesPackageRepository packageRepository; + @Autowired + private MesPackageDetailRepository packageDetailRepository; + @Override public MesPackage getMesPackage(String organizeCode, Long id) { + if (StringUtils.isEmpty(organizeCode) || StringUtils.isEmpty(id)) return null; return packageRepository.getByProperty( new String[]{MesPcnExtConstWords.ORGANIZE_CODE, MesPcnExtConstWords.IS_DELETED, MesPcnExtConstWords.IS_VALID, MesPcnExtConstWords.ID}, new Object[]{organizeCode, CommonEnumUtil.TRUE_OR_FALSE.FALSE.getValue(), CommonEnumUtil.IS_VAILD.VAILD.getValue(), id}); } + + @Override + public MesPackage getPackageDb(String organizeCode, String packageNo) { + if (StringUtils.isEmpty(organizeCode) || StringUtils.isEmpty(packageNo)) return null; + return packageRepository.getByProperty( + new String[]{MesPcnExtConstWords.ORGANIZE_CODE, MesPcnExtConstWords.IS_DELETED, MesPcnExtConstWords.IS_VALID, MesPcnExtConstWords.PACKAGE_NO}, + new Object[]{organizeCode, CommonEnumUtil.TRUE_OR_FALSE.FALSE.getValue(), CommonEnumUtil.IS_VAILD.VAILD.getValue(), packageNo}); + } + + @Override + public MesPackageDetail getPackageDetailByPackageNo(String organizeCode, String packageNo) { + if (StringUtils.isEmpty(organizeCode) || StringUtils.isEmpty(packageNo)) return null; + DdlPackBean packBean = DdlPackBean.getDdlPackBean(organizeCode); + DdlPreparedPack.getStringEqualPack(packageNo, MesPcnExtConstWords.PACKAGE_NO, packBean); + DdlPreparedPack.getOrderByPack(new Object[]{CommonEnumUtil.ASC_OR_DESC.DESC.getValue()}, new String[]{MesPcnExtConstWords.CREATE_DATE_TIME}, packBean); + return packageDetailRepository.getByProperty(packBean); + } + + @Override + public MesPackageDetail getPackageDetailByProductSn(String organizeCode, String productSn) { + if (StringUtils.isEmpty(organizeCode) || StringUtils.isEmpty(productSn)) return null; + MesPackageDetail packageDetail = getPackageDetailByProductSnWithProperty(organizeCode, productSn, MesPcnExtConstWords.SERIAL_NUMBER); + if (null == packageDetail) packageDetail = getPackageDetailByProductSnWithProperty(organizeCode, productSn, MesPcnExtConstWords.PRODUCT_SN); + if (null == packageDetail || StringUtils.isEmpty(packageDetail.getPackageNo())) return null; + return packageDetail; + } + + @Override + public MesPackageDetail getPackageDetailByProductSnWithProperty(String organizeCode, String productSn, String propertyName) { + DdlPackBean packBean = DdlPackBean.getDdlPackBean(organizeCode); + DdlPreparedPack.getStringEqualPack(productSn, propertyName, packBean); + DdlPreparedPack.getOrderByPack(new Object[]{CommonEnumUtil.ASC_OR_DESC.DESC.getValue()}, new String[]{MesPcnExtConstWords.CREATE_DATE_TIME}, packBean); + return packageDetailRepository.getByProperty(packBean); + } } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesProduceSnPrintService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesProduceSnPrintService.java index e85f344..31c7cd6 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesProduceSnPrintService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/busi/MesProduceSnPrintService.java @@ -2,10 +2,7 @@ package cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.busi; import cn.estsh.i3plus.ext.mes.pcn.api.base.IMesPartService; import cn.estsh.i3plus.ext.mes.pcn.api.base.IMesTemplateService; -import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesPrintedSnLogService; -import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesProduceSnPrintService; -import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesWorkOrderCutService; -import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesWorkOrderService; +import cn.estsh.i3plus.ext.mes.pcn.api.busi.*; import cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.busi.printqueue.IPrintQueueStrategyService; import cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.print.IPrintTemplateStrategyService; import cn.estsh.i3plus.ext.mes.pcn.apiservice.util.MesPcnException; @@ -111,6 +108,9 @@ public class MesProduceSnPrintService implements IMesProduceSnPrintService { @Autowired private IMesWorkOrderService mesWorkOrderService; + @Autowired + private IMesPackageExtService packageExtService; + // 仅查询 public static final Integer CUT_QUERY_MODE_BY_QUERY = 1; // 打印 @@ -501,4 +501,34 @@ public class MesProduceSnPrintService implements IMesProduceSnPrintService { snLog.setOrganizeCode(workOrder.getOrganizeCode()); return snLog; } + + @Override + public MesProduceSnPrintModel doRePrintPackByPackageNoOrProductSn(MesProduceSnPrintModel mesProduceSnPrintModel) { + //根据包装条码查询包装信息 + MesPackage packageDb = packageExtService.getPackageDb(mesProduceSnPrintModel.getOrganizeCode(), mesProduceSnPrintModel.getPackageNo()); + if (null == packageDb) MesPcnException.throwBusiException("包装条码[%s]信息不存在!", mesProduceSnPrintModel.getPackageNo()); + if (StringUtils.isEmpty(packageDb.getPackageLabelTemplate())) MesPcnException.throwBusiException("包装条码[%s]信息未关联包装条码模版代码!", mesProduceSnPrintModel.getPackageNo()); + + //查询模版信息 + MesLabelTemplate labelTemplate = mesTemplateService.getMesLabelTemplate(packageDb.getPackageLabelTemplate(), mesProduceSnPrintModel.getOrganizeCode()); + if (StringUtils.isEmpty(labelTemplate.getMethodCode())) + MesPcnException.throwBusiException("包装条码[%s]关联的包装条码模版代码[%s]未维护方法策略!", mesProduceSnPrintModel.getPackageNo(), packageDb.getPackageLabelTemplate()); + + IPrintTemplateStrategyService strategyService = (IPrintTemplateStrategyService) SpringContextsUtil.getBean(labelTemplate.getMethodCode()); + if (null == strategyService) MesPcnException.throwBusiException("包装条码[%s]关联的包装条码模版代码[%s]未维护有效的方法策略!", mesProduceSnPrintModel.getPackageNo(), packageDb.getPackageLabelTemplate()); + + mesProduceSnPrintModel.setMesLabelTemplate(labelTemplate); + mesProduceSnPrintModel.setPartNo(packageDb.getPartNo()); + mesProduceSnPrintModel.setPartName(packageDb.getPartName()); + mesProduceSnPrintModel.getPackageList().addAll(Stream.of(packageDb).collect(Collectors.toList())); + + mesProduceSnPrintModel = strategyService.execute(null, mesProduceSnPrintModel, null, null, null, false); + + //保存打印记录日志 + printedSnLogRepository.saveAll(mesProduceSnPrintModel.getMesPrintedSnLogList()); + + return mesProduceSnPrintModel; + + } + } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/MesNoSortCustSnNumberRuleStrategyService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/MesNoSortCustSnNumberRuleStrategyService.java index fd0c4ce..5cb280f 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/MesNoSortCustSnNumberRuleStrategyService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/MesNoSortCustSnNumberRuleStrategyService.java @@ -54,7 +54,7 @@ public class MesNoSortCustSnNumberRuleStrategyService implements INumberRulePack } @Override - public String transform(String serialNo) { + public String transform(GenSerialNoModel genSerialNoModel, String serialNo) { if (StringUtils.isEmpty(serialNo)) return serialNo; return customerSnTransformService.transformBarCodeGm(serialNo); } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/WuhuPackageNumberRuleStrategyService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/YfaiPackageNumberRuleStrategyService.java similarity index 50% rename from modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/WuhuPackageNumberRuleStrategyService.java rename to modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/YfaiPackageNumberRuleStrategyService.java index 5d6e53a..9143ea6 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/WuhuPackageNumberRuleStrategyService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/numberrule/YfaiPackageNumberRuleStrategyService.java @@ -7,6 +7,7 @@ import cn.estsh.i3plus.mes.pcn.api.iservice.busi.INumberRulePackAttributeStrateg import cn.estsh.i3plus.pojo.mes.model.GenSerialNoModel; import org.springframework.stereotype.Component; import org.springframework.util.CollectionUtils; +import org.springframework.util.StringUtils; import java.text.SimpleDateFormat; import java.util.Date; @@ -14,31 +15,14 @@ import java.util.Map; import java.util.StringJoiner; /** - * @Description : MES-包装条码(芜湖打包) + * @Description : MES-包装条码 * @Reference : - * @Author : junsheng.li + * @Author : wangjie * @CreateDate 2024/10/28 16:47 * @Modify: **/ @Component -public class WuhuPackageNumberRuleStrategyService implements INumberRulePackAttributeStrategyService { - - @Override - public GenSerialNoModel execute(GenSerialNoModel genSerialNoModel) { - Map dataMap = genSerialNoModel.getDataMap(); - MesPackageRuleContext packageRuleContext = !CollectionUtils.isEmpty(dataMap) ? (MesPackageRuleContext) dataMap.get(MesPackageRuleContext.class.getSimpleName()) : null; - if (null == packageRuleContext) MesPcnException.throwBusiException("生成包装条码缺少必要参数[规则对象]"); - genSerialNoModel.setDynamicRule( - new StringJoiner(MesPcnExtConstWords.COMMA) - .add(((new SimpleDateFormat(MesPcnExtConstWords.DATE_FORMAT_SHORT)).format(new Date()))) - .add(String.format("%.1f", packageRuleContext.getPackSpecQty())) - .add(packageRuleContext.getUnit()) - .toString() - ); - return genSerialNoModel; - } - -} +public class YfaiPackageNumberRuleStrategyService implements INumberRulePackAttributeStrategyService { // YFWHU|YFNSC901C241223042722|C901|401007574AAABN|9.0|EA|C901|20241223| //YFWHU|YFNS {Prefix} @@ -59,3 +43,42 @@ public class WuhuPackageNumberRuleStrategyService implements INumberRulePackAttr //| {SPILTRULE} //20241223 {YEAR}{MONTH}{DAY} //| {SPILTRULE} + + @Override + public GenSerialNoModel execute(GenSerialNoModel genSerialNoModel) { + Map dataMap = genSerialNoModel.getDataMap(); + MesPackageRuleContext packageRuleContext = !CollectionUtils.isEmpty(dataMap) ? (MesPackageRuleContext) dataMap.get(MesPackageRuleContext.class.getSimpleName()) : null; + Double qty = (!CollectionUtils.isEmpty(dataMap) && dataMap.containsKey(MesPcnExtConstWords.QTY)) ? (Double) dataMap.get(MesPcnExtConstWords.QTY) : null; + if (StringUtils.isEmpty(qty)) qty = null != packageRuleContext ? packageRuleContext.getPackSpecQty() : null; + if (StringUtils.isEmpty(qty)) MesPcnException.throwBusiException("生成包装条码缺少必要参数[包装数量]"); + String unit = (!CollectionUtils.isEmpty(dataMap) && dataMap.containsKey(MesPcnExtConstWords.UNIT)) ? (String) dataMap.get(MesPcnExtConstWords.UNIT) : null; + if (StringUtils.isEmpty(unit)) unit = null != packageRuleContext ? packageRuleContext.getUnit() : null; + if (StringUtils.isEmpty(unit)) MesPcnException.throwBusiException("生成包装条码缺少必要参数[单位]"); + genSerialNoModel.setDynamicRule( + new StringJoiner(MesPcnExtConstWords.COMMA) + .add(((new SimpleDateFormat(MesPcnExtConstWords.DATE_FORMAT_SHORT)).format(new Date()))) + .add(String.format("%.1f", qty)) + .add(packageRuleContext.getUnit()) + .toString() + ); + return genSerialNoModel; + } + + // 生成一维码,存到dataMap中 + // YFWHU|YFNSC901C241223042722|C901|401007574AAABN|9.0|EA|C901|20241223| + // YFNSC901C241223042722 截取原始条码的 第7位到27位 + @Override + public String transform(GenSerialNoModel genSerialNoModel, String serialNo) { + String packageOneCode; +// packageOneCode = serialNo.length() >= 27 ? serialNo.substring(6, 27) : serialNo; + try { + //截取前2个 "|" 之间的字符串 + Integer indexVerticalBar = serialNo.indexOf(MesPcnExtConstWords.VERTICAL_BAR) + 1; + packageOneCode = serialNo.substring(indexVerticalBar, serialNo.indexOf(MesPcnExtConstWords.VERTICAL_BAR, indexVerticalBar)); + } catch (Exception e) { + packageOneCode = serialNo; + } + genSerialNoModel.putDataMap(serialNo, packageOneCode); + return serialNo; + } +} \ No newline at end of file diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/WuhuPackageNoPrintStrategy.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/YfaiPackageNoPrintStrategy.java similarity index 80% rename from modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/WuhuPackageNoPrintStrategy.java rename to modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/YfaiPackageNoPrintStrategy.java index 4740beb..6088585 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/WuhuPackageNoPrintStrategy.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/print/strategy/YfaiPackageNoPrintStrategy.java @@ -22,7 +22,7 @@ import org.springframework.util.CollectionUtils; import java.util.*; /** - * @Description : 芜湖包装条码打印 + * @Description : 包装条码打印 * @Reference : * @Author : wangjie * @CreateDate : 2024/9/29 16:43 @@ -30,7 +30,7 @@ import java.util.*; **/ @Component @Slf4j -public class WuhuPackageNoPrintStrategy implements IPrintTemplateStrategyService { +public class YfaiPackageNoPrintStrategy implements IPrintTemplateStrategyService { @Autowired private IMesCustomerPartService mesCustomerPartService; @@ -49,12 +49,11 @@ public class WuhuPackageNoPrintStrategy implements IPrintTemplateStrategyService // 返回的结果集合 List> printDataMapList = new ArrayList<>(); if (!isStep) { - //TODO 包装条码补打 + model.getPackageList().forEach(o -> printDataMapList.add(getPrintMap(model, o, customerPart))); + model.setPrintContextList(printDataMapList); } else { model.getPackageList().forEach(o -> printDataMapList.add(getPrintMap(model, o, customerPart))); - List> resultMapList = new ArrayList<>(); - resultMapList.add(packResultMap(model, printDataMapList)); - model.setPrintContextList(resultMapList); + model.getPrintContextList().add(packResultMap(model, printDataMapList)); } return model; @@ -90,17 +89,7 @@ public class WuhuPackageNoPrintStrategy implements IPrintTemplateStrategyService resultMap.put(MesPcnExtConstWords.UNIT, packageDb.getUnit()); resultMap.put(MesPcnExtConstWords.PACK_SPEC_QTY, packageDb.getPackSpecQty().intValue()); resultMap.put(MesPcnExtConstWords.LOT_NO, packageDb.getLotNo().replaceAll(MesPcnExtConstWords.SEPARATOR, MesPcnExtConstWords.SLANT_R)); - // YFWHU|YFNSC901C241223042722|C901|401007574AAABN|9.0|EA|C901|20241223| - // YFNSC901C241223042722 截取原始条码的 第7位到27位 -// resultMap.put(MesPcnExtConstWords.BAR_CODE, packageDb.getPackageNo().length() >= 27 ? packageDb.getPackageNo().substring(6, 27) : packageDb.getPackageNo()); - try { - //截取前2个 "|" 之间的字符串 - Integer indexVerticalBar = packageDb.getPackageNo().indexOf(MesPcnExtConstWords.VERTICAL_BAR) + 1; - resultMap.put(MesPcnExtConstWords.BAR_CODE, packageDb.getPackageNo().substring(indexVerticalBar, packageDb.getPackageNo().indexOf(MesPcnExtConstWords.VERTICAL_BAR, indexVerticalBar))); - } catch (Exception e) { - resultMap.put(MesPcnExtConstWords.BAR_CODE, packageDb.getPackageNo()); - } - + resultMap.put(MesPcnExtConstWords.BAR_CODE, packageDb.getPackageOneCode()); resultMap.put(MesPcnExtConstWords.MODIFY_DATE_TIME, packageDb.getModifyDatetime().replaceAll(MesPcnExtConstWords.SEPARATOR, MesPcnExtConstWords.SLANT_R)); model.getMesPrintedSnLogList().add(getMesPrintedSnLog(packageDb, model.getUserName(), JSONObject.toJSONString(resultMap))); return resultMap; diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/function/MesFunctionDialogElectronicInspectionService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/function/MesFunctionDialogElectronicInspectionService.java index 81d826c..52317c5 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/function/MesFunctionDialogElectronicInspectionService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/station/function/MesFunctionDialogElectronicInspectionService.java @@ -3,9 +3,16 @@ package cn.estsh.i3plus.ext.mes.pcn.apiservice.serviceimpl.station.function; import cn.estsh.i3plus.ext.mes.pcn.api.busi.IMesProductionDispatchContextStepService; import cn.estsh.i3plus.ext.mes.pcn.pojo.context.MesProductionPsOutContext; import cn.estsh.i3plus.mes.pcn.serviceimpl.fsm.BaseSwsService; +import cn.estsh.i3plus.mes.pcn.serviceimpl.fsm.IShippingDispatchService; import cn.estsh.i3plus.mes.pcn.serviceimpl.fsm.function.IFsmModuleFunctionService; +import cn.estsh.i3plus.platform.common.util.MesPcnConstWords; +import cn.estsh.i3plus.pojo.base.enumutil.MesPcnEnumUtil; +import cn.estsh.i3plus.pojo.mes.model.ButtonDynamicModel; import cn.estsh.i3plus.pojo.mes.model.StationCustomDialogBean; import cn.estsh.i3plus.pojo.mes.model.StationRequestBean; +import cn.estsh.i3plus.pojo.mes.model.StationResultBean; +import cn.estsh.i3plus.pojo.mes.util.MesExtEnumUtil; +import com.alibaba.fastjson.JSONObject; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -13,6 +20,7 @@ import org.springframework.util.CollectionUtils; import org.springframework.util.StringUtils; import java.util.List; +import java.util.Map; import java.util.stream.Collectors; /** @@ -23,9 +31,56 @@ import java.util.stream.Collectors; public class MesFunctionDialogElectronicInspectionService extends BaseSwsService implements IFsmModuleFunctionService { @Autowired + private IShippingDispatchService shippingDispatchService; + + @Autowired private IMesProductionDispatchContextStepService productionDispatchContextStepService; @Override + public Boolean doFunction(StationRequestBean reqBean, StationResultBean resultBean, ButtonDynamicModel buttonDynamicModel) { + + this.sendMessage(reqBean, new StationResultBean().writeDbLog(MesPcnEnumUtil.WORK_CELL_SCAN_MONITOR_LOG_TYPE.PICK.getValue()).scanInfo(buttonDynamicModel.getFunctionValue()), + String.format("生产线[%s]工位[%s]电子化检验弹框提交信息成功!提交信息[%s]", reqBean.getWorkCenterCode(), reqBean.getWorkCellCode(), buttonDynamicModel.getFunctionValue()), + MesPcnEnumUtil.STATION_BUSI_TYPE.RUNNING_INFO, MesPcnEnumUtil.STATION_DATA_TYPE.TEXT); + + //functionValue=电子化检验的判断结果 + Map inspectionMap = null; + try { + inspectionMap = StringUtils.isEmpty(buttonDynamicModel.getFunctionValue()) ? null : JSONObject.parseObject(buttonDynamicModel.getFunctionValue(), Map.class); + } catch (Exception e) { + } + + Boolean isSaveFlag = false; + //获取上下文产出条码数据信息集合 + if (!CollectionUtils.isEmpty(inspectionMap)) { + List productionPsOutContextList = productionDispatchContextStepService.getProductionPsOutContext(reqBean); + if (!CollectionUtils.isEmpty(productionPsOutContextList)) { + for (MesProductionPsOutContext productionPsOutContext : productionPsOutContextList) { + if (null == productionPsOutContext) continue; + Integer qcStatus = inspectionMap.get(productionPsOutContext.getProductSn()); + //电子化检验弹框判不合格 + if (!StringUtils.isEmpty(qcStatus) && qcStatus.compareTo(MesExtEnumUtil.PRODUCE_QC_STATUS.QUALIFIED.getValue()) != 0) { + productionPsOutContext.setQcStatus(qcStatus); + isSaveFlag = true; + } + } + //保存上下文产出条码数据信息集合 + if (isSaveFlag) productionDispatchContextStepService.dispatchProductionPsOutContext(reqBean, productionPsOutContextList); + } + } + + reqBean.setClientInfo(shippingDispatchService.getActorClientInfo(reqBean)); + reqBean.setInterfaceType(MesPcnConstWords.SHIPPING); + reqBean.setBusiType(MesPcnEnumUtil.ACTOR_RECEIVE_STRATEGY.WS_CMD_DO_SCAN.getCode()); + reqBean.setButtonCode(buttonDynamicModel.getButtonCode()); + reqBean.setStepDialogStatus(true); + shippingDispatchService.sendScanQueueNextExec(reqBean); + + return true; + + } + + @Override public StationCustomDialogBean stepDialogDispatch(StationRequestBean reqBean, StationCustomDialogBean dialogBean) { //获取上下文产出条码数据信息集合 @@ -36,7 +91,7 @@ public class MesFunctionDialogElectronicInspectionService extends BaseSwsService List snList = productionPsOutContext.stream().filter(o -> !StringUtils.isEmpty(o.getProductSn())).map(MesProductionPsOutContext::getProductSn).distinct().collect(Collectors.toList()); // 条码列表为空则表示不需要弹框 if (CollectionUtils.isEmpty(snList)) return dialogBean.unDialog(); - else return dialogBean.asyn().obj(snList); + else return dialogBean.obj(snList); } else return dialogBean.unDialog(); } diff --git a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesPackageNoGenerateStepService.java b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesPackageNoGenerateStepService.java index 4116d3a..34cfcb3 100644 --- a/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesPackageNoGenerateStepService.java +++ b/modules/i3plus-ext-mes-pcn-apiservice/src/main/java/cn/estsh/i3plus/ext/mes/pcn/apiservice/serviceimpl/step/MesPackageNoGenerateStepService.java @@ -120,8 +120,9 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements //在加工规则中搜集可以打包的数据的数据关联键集合 List foreignKeyList = prodRuleContextList.stream().filter(o -> (null != o && !StringUtils.isEmpty(o.getIsPackage()) && o.getIsPackage().compareTo(CommonEnumUtil.TRUE_OR_FALSE.TRUE.getValue()) == 0)).map(MesProdRuleContext::getForeignKey).collect(Collectors.toList()); - //搜集数据关联键集合对应的产出条码,根据零件号分组 - Map> productSnMap2Part = productionPsOutContextList.stream().filter(o -> (null != o && foreignKeyList.contains(o.getForeignKey()))) + //搜集数据关联键集合对应的[合格状态]的产出条码,根据零件号分组 + Map> productSnMap2Part = productionPsOutContextList.stream() + .filter(o -> (null != o && o.getQcStatus().compareTo(MesExtEnumUtil.PRODUCE_QC_STATUS.QUALIFIED.getValue()) == 0 && foreignKeyList.contains(o.getForeignKey()))) .collect(Collectors.groupingBy(MesProductionPsOutContext::getPartNo, Collectors.mapping(MesProductionPsOutContext::getProductSn, Collectors.toList()))); //获取包装规则信息 @@ -248,11 +249,11 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements return null; } + //根据箱类别代号查询包装定义 + MesPackingDefine packingDefine = StringUtils.isEmpty(packingRule.getPackCode()) ? null : packingRuleService.getPackingDefine(reqBean.getOrganizeCode(), packingRule.getPackCode()); + //判断是否需要查询包装定义 if (StringUtils.isEmpty(packageBarcodeRule) || StringUtils.isEmpty(packageTemplate) || StringUtils.isEmpty(printer)) { - //根据箱类别代号查询包装定义 - MesPackingDefine packingDefine = StringUtils.isEmpty(packingRule.getPackCode()) ? null : - packingRuleService.getPackingDefine(reqBean.getOrganizeCode(), packingRule.getPackCode()); if (null == packingDefine && (StringUtils.isEmpty(packageBarcodeRule) || StringUtils.isEmpty(packageTemplate))) { message = String.format("零件编码[%s]包装物类型对应的包装代码[%s]配置成品包装规则信息中的箱类别代号[%s]未维护包装定义信息!", partNo, packingRuleDetail.getPackageCode(), packingRule.getPackCode()); if (!isAsyn) this.sendMessage(reqBean, new StationResultBean().writeDbLog(), message, MesPcnEnumUtil.STATION_BUSI_TYPE.MESSAGE, MesPcnEnumUtil.STATION_DATA_TYPE.EXP_TEXT); @@ -281,6 +282,8 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements packageRuleContext.setPackageBarcodeRule(packageBarcodeRule); packageRuleContext.setPackageTemplate(packageTemplate); packageRuleContext.setPrinter(printer); + if (null == packingDefine || StringUtils.isEmpty(packingDefine.getIsSendAries()) || + packingDefine.getIsSendAries().compareTo(CommonEnumUtil.TRUE_OR_FALSE.TRUE.getValue()) != 0) packageRuleContext.setSystemSyncStatusWms(MesPcnExtConstWords.ZERO); return packageRuleContext; } @@ -320,7 +323,7 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements //判断当前是否满包, isAsyn=false代表是工位按钮零件打包触发,零头也直接封箱 Boolean isSealed = !isAsyn ? curQty >= packageRuleContext.getPackSpecQty().intValue() : true; //判断包装条码是否存在ID进行新增或者更新操作, 如果满足标包则标记满包状态跟打印状态 - packageDb = savePackageDb(reqBean, packageDb, curQty, isSealed, true); + packageDb = savePackageDb(reqBean, packageDb, curQty, isSealed, isAsyn); //判断统计方式,是否生成包装明细信息, 返回当前未满包的包装条码明细数据 List resultList = insertPackageDetailAndBackUnSealedResultList(reqBean, packageRuleContext, packageDb, productSnList2Cur, isSealed); @@ -345,8 +348,14 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements //生成包装条码信息 private MesPackage insertMesPackage(StationRequestBean reqBean, MesPackageRuleContext packageRuleContext, Boolean isAsyn) { + + //封装流水号入参对象 + GenSerialNoModel serialNoModel = new GenSerialNoModel(packageRuleContext.getPackageBarcodeRule()) + .putDataMap(MesPackageRuleContext.class.getSimpleName(), packageRuleContext) + .partNo(packageRuleContext.getPartNo()).basicInfo(reqBean.getOrganizeCode(), reqBean.getWorkCenterCode(), reqBean.getWorkCellCode()); + //根据编码规则生成包装条码 - String packageNo = doGereratePackageNo(reqBean, packageRuleContext, isAsyn); + String packageNo = doGereratePackageNo(reqBean, serialNoModel, isAsyn); if (StringUtils.isEmpty(packageNo)) return null; MesPackage packageDb = new MesPackage(); packageDb.setPackageNo(packageNo); @@ -366,12 +375,17 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements packageDb.setPackageLabelTemplate(packageRuleContext.getPackageTemplate()); packageDb.setFid(UUID.randomUUID().toString()); packageDb.setOrganizeCode(reqBean.getOrganizeCode()); + packageDb.setSystemSyncStatusWms(packageRuleContext.getSystemSyncStatusWms()); ConvertBean.serviceModelInitialize(packageDb, reqBean.getUserInfo()); + //一维码是在编码规则的策略中调用transform方法生成的, 暂存到dataMap中,key=包装条码 + if (!CollectionUtils.isEmpty(serialNoModel.getDataMap()) && serialNoModel.getDataMap().containsKey(packageNo)) { + packageDb.setPackageOneCode(serialNoModel.getDataMap().get(packageNo).toString()); + } return packageDb; } //判断包装条码是否存在ID进行新增或者更新操作, 如果满足标包则标记满包状态跟打印状态 - private MesPackage savePackageDb(StationRequestBean reqBean, MesPackage packageDb, Integer curQty, Boolean isSealed, Boolean isSave) { + private MesPackage savePackageDb(StationRequestBean reqBean, MesPackage packageDb, Integer curQty, Boolean isSealed, Boolean isAsyn) { if (!StringUtils.isEmpty(packageDb.getId())) { //下面直接根据ID进行修改, 所以此处置为游离态 @@ -386,11 +400,31 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements packageDb.setPrintStatus(MesExtEnumUtil.PRINT_STATUS.PRINTED.getValue()); } - //无须更新 - if (!isSave) return packageDb; - if (StringUtils.isEmpty(packageDb.getId())) return packageRepository.insert(packageDb); + Boolean unChangePackageNo = !isSealed ? true : TimeTool.getToday().equals(packageDb.getLotNo()); + if (!unChangePackageNo) { + //包装条码中因为含有批次号, 隔天封箱需要重新生成包装条码 + //封装流水号入参对象 + GenSerialNoModel serialNoModel = new GenSerialNoModel(packageDb.getPackageLabelTemplate()) + .putDataMap(MesPcnExtConstWords.QTY, packageDb.getQty()) + .putDataMap(MesPcnExtConstWords.UNIT, packageDb.getUnit()) + .partNo(packageDb.getPartNo()).basicInfo(reqBean.getOrganizeCode(), reqBean.getWorkCenterCode(), reqBean.getWorkCellCode()); + + //根据编码规则生成包装条码 + String packageNo = doGereratePackageNo(reqBean, serialNoModel, isAsyn); + if (!StringUtils.isEmpty(packageNo)) { + String sourcePackageNo = packageDb.getPackageNo(); + packageDb.setPackageNo(packageNo); + if (!CollectionUtils.isEmpty(serialNoModel.getDataMap()) && serialNoModel.getDataMap().containsKey(packageNo)) { + packageDb.setPackageOneCode(serialNoModel.getDataMap().get(packageNo).toString()); + } + packageDb.setRemark(String.format("封箱跨天,原包装条码:%s", sourcePackageNo)); + //替换包装明细数据的包装条码 + savePackageDetailDbByPackageNo(reqBean, packageDb, sourcePackageNo); + } + } + //更新操作 savePackageDbById(reqBean, packageDb); @@ -446,10 +480,7 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements } //根据编码规则生成包装条码 - private String doGereratePackageNo(StationRequestBean reqBean, MesPackageRuleContext packageRuleContext, Boolean isAsyn) { - GenSerialNoModel serialNoModel = new GenSerialNoModel(packageRuleContext.getPackageBarcodeRule()) - .putDataMap(MesPackageRuleContext.class.getSimpleName(), packageRuleContext) - .partNo(packageRuleContext.getPartNo()).basicInfo(reqBean.getOrganizeCode(), reqBean.getWorkCenterCode(), reqBean.getWorkCellCode()); + private String doGereratePackageNo(StationRequestBean reqBean, GenSerialNoModel serialNoModel, Boolean isAsyn) { try { return syncFuncService.syncSerialNo(serialNoModel, reqBean.getUserInfo(), reqBean.getOrganizeCode(), 1).getResultList().get(0).toString(); } catch (ImppBusiException e) { @@ -526,14 +557,50 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements //强制打包业务处理 @Override public void doForcePrint(StationRequestBean reqBean, StationResultBean resultBean, StepResult stepResult, List packageDataContextList, MesPackage packageDb) { - //标记满包状态跟打印状态 - savePackageDb(reqBean, packageDb, packageDataContextList.size(), true, false); + //包装条码中因为含有包装数量, 故强制打包需要重新生成包装条码 + //封装流水号入参对象 + GenSerialNoModel serialNoModel = new GenSerialNoModel(packageDataContextList.get(0).getPackageBarcodeRule()) + .putDataMap(MesPcnExtConstWords.QTY, new Double(packageDataContextList.size())) + .putDataMap(MesPcnExtConstWords.UNIT, packageDb.getUnit()) + .partNo(packageDb.getPartNo()).basicInfo(reqBean.getOrganizeCode(), reqBean.getWorkCenterCode(), reqBean.getWorkCellCode()); + + //根据编码规则生成包装条码 + String packageNo = doGereratePackageNo(reqBean, serialNoModel, true); + if (StringUtils.isEmpty(packageNo)) MesPcnException.throwBusiException("根据编码规则[%s]生成包装条码失败!", serialNoModel.getRuleCode()); + + //下面直接根据ID进行修改, 所以此处置为游离态 + entityManager.detach(packageDb); + ConvertBean.serviceModelUpdate(packageDb, reqBean.getUserInfo()); + packageDb.setQty(new Double(packageDataContextList.size())); + packageDb.setLotNo(TimeTool.getToday()); + packageDb.setIsSealed(CommonEnumUtil.TRUE_OR_FALSE.TRUE.getValue()); + packageDb.setPrintStatus(MesExtEnumUtil.PRINT_STATUS.PRINTED.getValue()); + packageDb.setPackageNo(packageNo); + if (!CollectionUtils.isEmpty(serialNoModel.getDataMap()) && serialNoModel.getDataMap().containsKey(packageNo)) { + packageDb.setPackageOneCode(serialNoModel.getDataMap().get(packageNo).toString()); + } + packageDb.setRemark(String.format("强制封箱,原包装条码:%s", packageDataContextList.get(0).getPackageNo())); + List packageList = new ArrayList<>(); packageList.add(packageDb); //进行打印 doPrintPackageNo(reqBean, resultBean, stepResult, packageDataContextList.get(0), null, null, packageList, true); //更新操作 savePackageDbById(reqBean, packageDb); + + //替换包装明细数据的包装条码 + savePackageDetailDbByPackageNo(reqBean, packageDb, packageDataContextList.get(0).getPackageNo()); + } + + //替换包装明细数据的包装条码 + private void savePackageDetailDbByPackageNo(StationRequestBean reqBean, MesPackage packageDb, String sourcePackageNo) { + packageDetailRepository.updateByPropertiesNoSync( + new String[]{MesPcnExtConstWords.ORGANIZE_CODE, MesPcnExtConstWords.PACKAGE_NO}, + new Object[]{reqBean.getOrganizeCode(), sourcePackageNo}, + new String[]{MesPcnExtConstWords.PACKAGE_NO, MesPcnExtConstWords.REMARK, + MesPcnExtConstWords.MODIFY_USER, MesPcnExtConstWords.MODIFY_DATE_TIME, MesPcnExtConstWords.SYSTEM_SYNC_STATUS, MesPcnExtConstWords.SYSTEM_SYNC_DATE_TIME}, + new Object[]{packageDb.getPackageNo(), packageDb.getRemark(), + packageDb.getModifyUser(), packageDb.getModifyDatetime(), CommonEnumUtil.TRUE_OR_FALSE.FALSE.getValue(), MesPcnExtConstWords.EMPTY}); } //更新操作 @@ -541,9 +608,11 @@ public class MesPackageNoGenerateStepService extends BaseStepService implements packageRepository.updateByPropertiesNoSync( new String[]{MesPcnExtConstWords.ORGANIZE_CODE, MesPcnExtConstWords.ID}, new Object[]{reqBean.getOrganizeCode(), packageDb.getId()}, - new String[]{MesPcnExtConstWords.QTY, MesPcnExtConstWords.IS_SEALED, MesPcnExtConstWords.PRINT_STATUS, MesPcnExtConstWords.LOT_NO, + new String[]{MesPcnExtConstWords.PACKAGE_NO, MesPcnExtConstWords.PACKAGE_ONE_CODE, MesPcnExtConstWords.QTY, + MesPcnExtConstWords.IS_SEALED, MesPcnExtConstWords.PRINT_STATUS, MesPcnExtConstWords.LOT_NO, MesPcnExtConstWords.REMARK, MesPcnExtConstWords.MODIFY_USER, MesPcnExtConstWords.MODIFY_DATE_TIME, MesPcnExtConstWords.SYSTEM_SYNC_STATUS, MesPcnExtConstWords.SYSTEM_SYNC_DATE_TIME}, - new Object[]{packageDb.getQty(), packageDb.getIsSealed(), packageDb.getPrintStatus(), packageDb.getLotNo(), + new Object[]{packageDb.getPackageNo(), packageDb.getPackageOneCode(), packageDb.getQty(), + packageDb.getIsSealed(), packageDb.getPrintStatus(), packageDb.getLotNo(), packageDb.getRemark(), packageDb.getModifyUser(), packageDb.getModifyDatetime(), CommonEnumUtil.TRUE_OR_FALSE.FALSE.getValue(), MesPcnExtConstWords.EMPTY}); } diff --git a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/context/MesPackageRuleContext.java b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/context/MesPackageRuleContext.java index 487862c..980dcdd 100644 --- a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/context/MesPackageRuleContext.java +++ b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/context/MesPackageRuleContext.java @@ -58,6 +58,7 @@ public class MesPackageRuleContext implements Serializable { @ApiParam(name = "打印机") public String printer; - + @ApiParam(name = "同步状态WMS") + public Integer systemSyncStatusWms = 2; } diff --git a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java index bbacdbb..7d2dbe6 100644 --- a/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java +++ b/modules/i3plus-ext-mes-pcn-pojo/src/main/java/cn/estsh/i3plus/ext/mes/pcn/pojo/util/MesPcnExtConstWords.java @@ -246,6 +246,8 @@ public class MesPcnExtConstWords { public static final String CUST_ORDER_NO = "custOrderNo"; //包装条码 public static final String PACKAGE_NO = "packageNo"; + //包装一维码 + public static final String PACKAGE_ONE_CODE = "packageOneCode"; //包条码 public static final String PACKAGE_SN = "packageSn"; //包类型