| | |
| | | |
| | | @Override |
| | | public void saveCampaignTimeParameters(DaParamCollection daParamCollection) { |
| | | String locationCode = daParamCollection.getLocationCode(); |
| | | String thoroughfare = Constants.thoroughfareMap.get(locationCode); |
| | | |
| | | BsFormulaChildInfo childInfo = daParamCollection.getFormulaChildEntity(); |
| | | if(StringUtils.isNotBlank(childInfo.getResults())){ |
| | | if(!childInfo.getResults().equals("OK")){ |
| | | try { |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier("JCDM035."+daParamCollection.getLocationCode()+".RecordDataDone").value(22).build()); |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare+"."+daParamCollection.getLocationCode()+".RecordDataDone").value(22).build()); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | |
| | | } |
| | | }else { |
| | | try { |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier("JCDM035."+daParamCollection.getLocationCode()+".RecordDataDone").value(22).build()); |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare+"."+daParamCollection.getLocationCode()+".RecordDataDone").value(22).build()); |
| | | } catch (Exception e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | |
| | | this.saveParameters(daParamCollection); |
| | | |
| | | //给opc发21 |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier("JCDM035."+daParamCollection.getLocationCode()+".RecordDataDone").value(21).build()); |
| | | miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare+"."+daParamCollection.getLocationCode()+".RecordDataDone").value(21).build()); |
| | | /* if(daParamCollection.getLocationCode().equals("M1OP100-1") || daParamCollection.getLocationCode().equals("M1OP100-2") ){ |
| | | try{ |
| | | //更新工单状态为已执行 |