jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
jcdm-ui/src/views/main/kb/stationTerminal/index.vue | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
jcdm-main/src/main/java/com/jcdm/main/plcserver/sub/OPCUaSubscription.java
@@ -127,13 +127,19 @@ } }else {//自动工位 //所有进站将进站时间写给PLC SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); String currentDate = dateFormat.format(new Date()); miloService.writeToOpcUa(ReadWriteEntity.builder().identifier(thoroughfare + "." + device + ".StartTime").value(currentDate).build()); Object snCodeObject = miloService.readFromOpcUa(thoroughfare + "." + device + ".SNCode").getValue(); if (ObjectUtil.isNull(snCodeObject)){ miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare + "." + device + ".RecordDataDone").value(12).build()); }else{ //所有进站将进站时间写给PLC SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); String currentDate = dateFormat.format(new Date()); miloService.writeToOpcUa(ReadWriteEntity.builder().identifier(thoroughfare + "." + device + ".StartTime").value(currentDate).build()); Integer recordDataDone = 11; miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare + "." + device + ".RecordDataDone").value(recordDataDone).build()); Integer recordDataDone = 11; miloService.writeToOpcShort(ReadWriteEntity.builder().identifier(thoroughfare + "." + device + ".RecordDataDone").value(recordDataDone).build()); } } } else if(Constants.TWO.equals(valueString)){//出站 jcdm-ui/src/views/main/kb/stationTerminal/index.vue
@@ -134,7 +134,7 @@ <span>绝缘等级:</span><span>H</span><br> </div> <div style="margin-top: 4px"> <span>出厂编号:</span><span>2407190000002</span><br> <span>出厂编号:</span><span>{{headContent.sfcCode}}</span><br> </div> </div> </div> @@ -289,7 +289,7 @@ name: "stationTerminal", data() { return { text: 'P9900200461#T2408170000004 #V993983#SSW001.001#HHW001.001#NMCU', text: 'P9900200461#T2408170000004#V993983#SSW001.001#HHW001.001#NMCU', materialCode: '', // 物料编码 carCode: '', showInput: false, @@ -558,7 +558,7 @@ this.cakeLamp.InPlace = 1 // this.test1() // this.test2() this.text = 'P9900200461#T'+this.headContent.sfcCode+' #V993983#SSW001.001#HHW001.001#NMCU' this.text = 'P9900200461#T'+this.headContent.sfcCode+'#V993983#SSW001.001#HHW001.001#NMCU' } }); }, @@ -589,7 +589,7 @@ let qrCode = new QRCode('canvasWrapper1',{ width: 83, height: 83, text: 'P9900200461#T'+this.headContent.sfcCode+' #V993983#SSW001.001#HHW001.001#NMCU', text: 'P9900200461#T'+this.headContent.sfcCode+'#V993983#SSW001.001#HHW001.001#NMCU', colorDark: '#000', colorLight: '#fff' }) @@ -602,7 +602,7 @@ let qrCode = new QRCode('canvasWrapper2',{ width: 83, height: 83, text: 'P9900200461#T'+this.headContent.sfcCode+' #V993983#SSW001.001#HHW001.001#NMCU', text: 'P9900200461#T'+this.headContent.sfcCode+'#V993983#SSW001.001#HHW001.001#NMCU', colorDark: '#000', colorLight: '#fff' }) @@ -716,7 +716,7 @@ if(self.headContent.processesCode === "OP165"){ // self.test1() // self.test2() self.text = 'P9900200461#T'+self.headContent.sfcCode+' #V993983#SSW002.005#HHW001.001#NMCU#' self.text = 'P9900200461#T'+self.headContent.sfcCode+'#V993983#SSW002.005#HHW001.001#NMCU#' } }else if (event.data.includes("[")) {//拧紧