| | |
| | | public void onSubscribe(String identifier, Object value) { |
| | | String ecpStr = "";//异常记录标记 |
| | | try { |
| | | if(null != value && "1".equals(value.toString())) { |
| | | if(null != value && "1".equals(value.toString())) { |
| | | //1、检索SN号 |
| | | //2、过站参数采集 |
| | | //3、扫码枪数据回传 |
| | |
| | | List<BsOrderScheduling> queryOrderList = bsOrderSchedulingService.selectBsOrderSchedulingList(bsOrderSchedulingQuery); |
| | | if (CollUtil.isNotEmpty(queryOrderList)){ |
| | | a = "1"; |
| | | //如果是老车型,判断是否重复扫码 |
| | | if (OPCElement.OP050_CODE_CHECK.equals(Node)){ |
| | | String type = productNewFlag(SNCode); |
| | | if (!"280".equals(type) && !"380".equals(type)){ |
| | | DaPassingStationCollection passCheck = new DaPassingStationCollection(); |
| | | passCheck.setSfcCode(SNCode); |
| | | passCheck.setLocationCode("OP060"); |
| | | List<DaPassingStationCollection> passCheckList = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(passCheck); |
| | | if (CollUtil.isNotEmpty(passCheckList)){ |
| | | //是否返修 |
| | | a = "5"; |
| | | // RmRepairRecord repairRecordCheck = new RmRepairRecord(); |
| | | // repairRecordCheck.setBoxCode(SNCode); |
| | | // repairRecordCheck.setProcessesCode("OP050"); |
| | | // List<RmRepairRecord> repairCheckList = rmRepairRecordService.selectRmRepairRecordList(repairRecordCheck); |
| | | // if (CollUtil.isEmpty(repairCheckList)){ |
| | | // |
| | | // } |
| | | } |
| | | } |
| | | } |
| | | }else { |
| | | a = "4"; |
| | | } |
| | |
| | | } |
| | | logger.info("-----返回codeCheckFeed-----,{}",a); |
| | | // String a="1"; |
| | | //zz上线工位查询hx线是否过站合格 |
| | | if (OPCElement.OP120_ZZ_CODE_CHECK.equals(Node)){ |
| | | //过站记录 |
| | | DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection(); |
| | | PassingStationCollection.setSfcCode(SNCode); |
| | | PassingStationCollection.setLocationCode("OP160"); |
| | | List<DaPassingStationCollection> ZZOP120PassCheck = passingStationCollectionServiceImpl.selectDaPassingStationCollectionList(PassingStationCollection); |
| | | if (CollUtil.isEmpty(ZZOP120PassCheck)){ |
| | | a = ""; |
| | | } else { |
| | | DaPassingStationCollection passingStationCollection = ZZOP120PassCheck.get(0); |
| | | String outRsSign = passingStationCollection.getOutRsSign(); |
| | | if (!OPCElement.QUALIFIED.equals(outRsSign)){ |
| | | a = ""; |
| | | } |
| | | } |
| | | } |
| | | // 1:OK可生产 2:NG不可生产 3:NG可返工 4:PC检索失败(无记录)5:PC检索失败(软件) |
| | | if (StrUtil.isNotBlank(a)){ |
| | | int input = Integer.parseInt(a); |
| | |
| | | ParamCollection.setParamValue(readWriteEntityList.get(i).getValue().toString()); |
| | | } |
| | | ParamCollection.setSfcCode(SNCode); |
| | | ParamCollection.setParamName(list.get(i).getCollectParameterName()); |
| | | ParamCollection.setParamName(list.get(i).getParameterSetName()); |
| | | ParamCollection.setParamUpper(list.get(i).getParamUpper()); |
| | | ParamCollection.setParamLower(list.get(i).getParamLower()); |
| | | ParamCollection.setUnit(list.get(i).getCollectParameterUnit()); |
| | |
| | | } |
| | | DaPassingStationCollection PassingStationCollection=new DaPassingStationCollection(); |
| | | PassingStationCollection.setSfcCode(SNCode); |
| | | PassingStationCollection.setProductCode(bsOrderScheduling.getModel()); |
| | | PassingStationCollection.setLocationCode(parts[1]); |
| | | PassingStationCollection.setOutboundTime(new Date()); |
| | | PassingStationCollection.setInboundTime(new Date(new Date().getTime()-beatTime*1000)); |