diff --git a/nladmin-system/src/main/java/org/nl/acs/device_driver/hailiang/hailiang_feeding_trunk/HaiLiangFeedingTrunkDeviceDriver.java b/nladmin-system/src/main/java/org/nl/acs/device_driver/hailiang/hailiang_feeding_trunk/HaiLiangFeedingTrunkDeviceDriver.java index 7259071..f43280a 100644 --- a/nladmin-system/src/main/java/org/nl/acs/device_driver/hailiang/hailiang_feeding_trunk/HaiLiangFeedingTrunkDeviceDriver.java +++ b/nladmin-system/src/main/java/org/nl/acs/device_driver/hailiang/hailiang_feeding_trunk/HaiLiangFeedingTrunkDeviceDriver.java @@ -119,7 +119,8 @@ public class HaiLiangFeedingTrunkDeviceDriver extends AbstractOpcDeviceDriver im int last_coating_frequency = 0; int last_strapping_order_detail =0; int last_order_feeding_finish =0; - + int detail_coating_qualified_qty =0; + int last_detail_coating_qualified_qty=0; Boolean send_letter_flag_back = false; Boolean send_letter_flag = false; @@ -159,6 +160,8 @@ public class HaiLiangFeedingTrunkDeviceDriver extends AbstractOpcDeviceDriver im detail_strapping_oneqty = this.itemProtocol.getDetail_strapping_oneqty(); //当前工单明细号裹膜数 detail_coating_qty =this.itemProtocol.getDetail_coating_qty(); + //当前工单明细号裹膜合格数 + detail_coating_qualified_qty = this.itemProtocol.getDetail_coating_qualified_qty(); //当前贴标工单明细号 labeling_order_detail = this.itemProtocol.getLabeling_order_detail(); //捆扎明细 @@ -377,6 +380,11 @@ public class HaiLiangFeedingTrunkDeviceDriver extends AbstractOpcDeviceDriver im logServer.deviceLog(this.device_code,"order_feeding_finish" ,String.valueOf(order_feeding_finish)); logServer.deviceLogToacs(this.device_code,"","","信号order_feeding_finish:" + last_order_feeding_finish+ "->" + order_feeding_finish); } + if(detail_coating_qualified_qty != last_detail_coating_qualified_qty) + { + logServer.deviceLog(this.device_code,"detail_coating_qualified_qty" ,String.valueOf(detail_coating_qualified_qty)); + logServer.deviceLogToacs(this.device_code,"","","信号detail_coating_qualified_qty:" + last_detail_coating_qualified_qty+ "->" + detail_coating_qualified_qty); + } try{ if(order >0 && order_detail>0){ @@ -484,9 +492,11 @@ public class HaiLiangFeedingTrunkDeviceDriver extends AbstractOpcDeviceDriver im last_one_speed = one_speed; last_coating_frequency = coating_frequency; last_order_feeding_finish = order_feeding_finish; + last_detail_coating_qualified_qty = detail_coating_qualified_qty; } + //捆扎 public synchronized boolean update_strapping_detail(String order, String order_detail) throws Exception { Date date = new Date(); if (date.getTime() - this.detail_time_out < (long) this.detail_time_out) { @@ -499,8 +509,11 @@ public class HaiLiangFeedingTrunkDeviceDriver extends AbstractOpcDeviceDriver im if(ObjectUtil.isEmpty(dto)){ return false; } - dto.setPresent_labeling_number(String.valueOf(detail_labeling_qty)); - dto.setQualified_lettering_number(String.valueOf(detail_labeling_qualified_qty)); + dto.setPresent_strap_number(String.valueOf(detail_strapping_qty)); + dto.setQualified_strap_pack_number(String.valueOf(detail_strapping_oneqty)); + dto.setPresent_wraping_number(String.valueOf(detail_coating_qty)); + dto.setQualified_wraping_number(String.valueOf(detail_coating_qualified_qty)); + produceshiftorderdetailService.update(dto); return true; } diff --git a/nladmin-system/src/main/java/org/nl/acs/order/service/impl/Test.java b/nladmin-system/src/main/java/org/nl/acs/order/service/impl/Test.java deleted file mode 100644 index cc4d945..0000000 --- a/nladmin-system/src/main/java/org/nl/acs/order/service/impl/Test.java +++ /dev/null @@ -1,29 +0,0 @@ -package org.nl.acs.order.service.impl; - -public class Test { - - public static void main(String[] args) { - - Process printProcess; - String printName ="Zebra ZE500-4 RH (300 dpi)"; - try - { - printProcess = Runtime - .getRuntime() - .exec(new String[] { - "C:\\Users\\noblelift\\Desktop\\条码标签设计软件和打印程序\\BarcodePrint\\BarcodePrint.exe", - "PrinterName=" + printName, - "LabelName=Label1.ct", "Text1="+ "12211","Text2="+"23422","Text3="+"3533","Text4="+"6444"}); - } - catch (Exception e) - { - System.out.println("aaa"); - - } - - //System.out.println(17%15); - - } - - -}