diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/standard_inspect_site/StandardInspectSiteDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/standard_inspect_site/StandardInspectSiteDeviceDriver.java index 706f5e37d..a94354146 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/standard_inspect_site/StandardInspectSiteDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/conveyor/standard_inspect_site/StandardInspectSiteDeviceDriver.java @@ -437,6 +437,10 @@ public class StandardInspectSiteDeviceDriver extends AbstractOpcDeviceDriver imp move = LangProcess.msg("universal_two_yes"); jo.put("hasGoods", true); } + action = LangProcess.msg("universal_actionMessage1"); + if(this.action == 1){ + action = LangProcess.msg("universal_actionMessage2"); + } jo.put("device_name", this.getDevice().getDevice_name()); jo.put("mode", mode); jo.put("move", move); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/box_storage_out_conveyor/BoxStorageOutConveyorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/box_storage_out_conveyor/BoxStorageOutConveyorDeviceDriver.java index 1359c9851..9774bbaf5 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/box_storage_out_conveyor/BoxStorageOutConveyorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/one_conveyor/box_storage_out_conveyor/BoxStorageOutConveyorDeviceDriver.java @@ -593,7 +593,8 @@ public class BoxStorageOutConveyorDeviceDriver extends AbstractOpcDeviceDriver i @Override public JSONObject getDeviceStatusName() { - JSONObject jo = new JSONObject(); + Map map = new LinkedHashMap<>(); + String mode = ""; String move = ""; String carrier_direction = ""; @@ -609,13 +610,13 @@ public class BoxStorageOutConveyorDeviceDriver extends AbstractOpcDeviceDriver i if (this.getMove() == 0) { move = LangProcess.msg("universal_no"); - jo.put("hasGoods", false); + map.put("hasGoods", false); } else if (this.getMove() == 1) { move = LangProcess.msg("universal_yes"); - jo.put("hasGoods", true); + map.put("hasGoods", true); } else if (this.getMove() == 2) { move = LangProcess.msg("universal_two_yes"); - jo.put("hasGoods", true); + map.put("hasGoods", true); } if (this.carrier_direction == 1) { @@ -623,29 +624,30 @@ public class BoxStorageOutConveyorDeviceDriver extends AbstractOpcDeviceDriver i } else if (this.carrier_direction == 2) { carrier_direction = LangProcess.msg("universal_rollback"); } - String requireSucess = "0"; + String requireSucess = LangProcess.msg("universal_actionMessage4"); if (this.requireSucess) { - requireSucess = "1"; + requireSucess = LangProcess.msg("universal_actionMessage5"); } - jo.put("device_name", this.getDevice().getDevice_name()); - jo.put("mode", mode); - jo.put("move", move); - jo.put("carrier_direction", carrier_direction); - jo.put("task", task); - jo.put("last_task", last_task); - jo.put("task_code", task_code); - jo.put("inst_message", this.inst_message); - jo.put("last_inst_message", this.last_inst_message); - jo.put("isOnline", this.getIsonline()); - jo.put("error", ErrorUtil.getDictDetail("error_type", String.valueOf(this.getError()))); - jo.put("isError", this.getIserror()); - jo.put("message", LangProcess.msg(message)); - jo.put("hand_barcode", hand_barcode); - jo.put("barcode", this.getMove() == 0 ? null : checkInst() == null ? vehicle_code : checkInst().getVehicle_code()); - jo.put("is_click", true); - jo.put("requireSucess", requireSucess); - jo.put("driver_type", "siemens_conveyor"); - jo.put("notCreateInstMessage", LangProcess.msg(notCreateInstMessage)); + map.put("device_name", this.getDevice().getDevice_name()); + map.put("mode", mode); + map.put("move", move); + map.put("carrier_direction", carrier_direction); + map.put("task", task); + map.put("last_task", last_task); + /*map.put("task_code", task_code);*/ + map.put("isOnline", this.getIsonline()); + map.put("isError", this.getIserror()); + map.put("hand_barcode", hand_barcode); + map.put("barcode", this.getMove() == 0 ? null : checkInst() == null ? vehicle_code : checkInst().getVehicle_code()); + map.put("is_click", true); + map.put("error", ErrorUtil.getDictDetail("error_type", String.valueOf(this.getError()))); + map.put("requireSucess", requireSucess); + map.put("driver_type", "siemens_conveyor"); + map.put("message", LangProcess.msg(message)); + map.put("inst_message", this.inst_message); + map.put("last_inst_message", this.last_inst_message); + map.put("notCreateInstMessage", LangProcess.msg(notCreateInstMessage)); + JSONObject jo = new JSONObject(map); return jo; } diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/rgv/RgvDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/rgv/RgvDeviceDriver.java index 2da704d38..c7f5fc870 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/rgv/RgvDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/rgv/RgvDeviceDriver.java @@ -311,7 +311,8 @@ public class RgvDeviceDriver extends AbstractOpcDeviceDriver implements DeviceDr @Override public JSONObject getDeviceStatusName() { - JSONObject jo = new JSONObject(); + Map map = new LinkedHashMap<>(); + String mode = ""; String move = ""; String action = ""; @@ -328,20 +329,20 @@ public class RgvDeviceDriver extends AbstractOpcDeviceDriver implements DeviceDr if (this.getMove() == 0) { move = LangProcess.msg("universal_no"); - jo.put("hasGoods", false); + map.put("hasGoods", false); } else if (this.getMove() == 1) { move = LangProcess.msg("universal_yes"); - jo.put("hasGoods", true); + map.put("hasGoods", true); } else if (this.getMove() == 2) { move = LangProcess.msg("universal_two_yes"); - jo.put("hasGoods", true); + map.put("hasGoods", true); } - String requireSucess = "0"; + String requireSucess = LangProcess.msg("universal_actionMessage4"); if (this.requireSucess) { - requireSucess = "1"; + requireSucess = LangProcess.msg("universal_actionMessage5"); } - jo.put("requireSucess", requireSucess); + map.put("requireSucess", requireSucess); if (this.getAction() == 1) { action = LangProcess.msg("universal_delivery"); } else if (this.getAction() == 2) { @@ -352,21 +353,22 @@ public class RgvDeviceDriver extends AbstractOpcDeviceDriver implements DeviceDr action = LangProcess.msg("universal_releasing_completed"); } - jo.put("device_name", this.getDevice().getDevice_name()); - jo.put("mode", mode); - jo.put("move", move); - jo.put("action", action); - jo.put("task", task); - jo.put("walk_y", walk_y); - jo.put("isOnline", this.getIsonline()); - jo.put("error", ErrorUtil.getDictDetail("error_type", String.valueOf(this.getError()))); - jo.put("isError", this.getIserror()); - jo.put("message", message); - jo.put("notCreateTaskMessage", notCreateTaskMessage); - jo.put("notCreateInstMessage",notCreateInstMessage); - jo.put("feedMessage", feedMessage); - jo.put("driver_type", "siemens_conveyor"); - jo.put("is_click", true); + map.put("device_name", this.getDevice().getDevice_name()); + map.put("mode", mode); + map.put("move", move); + /*jo.put("action", action);*/ + /*jo.put("task", task);*/ + /*jo.put("walk_y", this.walk_y);*/ + map.put("isOnline", this.getIsonline()); + map.put("error", ErrorUtil.getDictDetail("error_type", String.valueOf(this.getError()))); + map.put("isError", this.getIserror()); + map.put("message", message); + /*jo.put("notCreateTaskMessage", notCreateTaskMessage); + jo.put("notCreateInstMessage",notCreateInstMessage);*/ + map.put("feedMessage", feedMessage); + map.put("driver_type", "siemens_conveyor"); + map.put("is_click", true); + JSONObject jo = new JSONObject(map); return jo; } diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java index 4385083f6..2e8810a36 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/oven_manipulator/OvenGantryManipulatorDeviceDriver.java @@ -236,7 +236,7 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i remark = remark + "光电信号(move)为有货状态,"; } if (task != 0) { - remark = "universal_remark4"; + remark = "任务不等于0"; if (ObjectUtil.isNotEmpty(this.inst)) { this.inst = null; } @@ -1082,7 +1082,6 @@ public class OvenGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver i @Override public JSONObject getDeviceStatusName() { Map map = new LinkedHashMap<>(); - String mode = ""; String move = ""; String action = ""; diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/plug_pull_device_site/PlugPullDeviceSiteDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/plug_pull_device_site/PlugPullDeviceSiteDeviceDriver.java index 3c065bf39..68b186ad4 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/plug_pull_device_site/PlugPullDeviceSiteDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/plug_pull_device_site/PlugPullDeviceSiteDeviceDriver.java @@ -211,11 +211,11 @@ public class PlugPullDeviceSiteDeviceDriver extends AbstractOpcDeviceDriver impl if (mode == 0) { this.setIsonline(false); - message = "universal_off-line"; + message = LangProcess.msg("universal_off-line"); //有报警 } else if (error != 0) { this.setIserror(true); - message = "universal_message3"; + message = LangProcess.msg("universal_message3"); //无报警 } else { this.setIsonline(true); diff --git a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/pull_head_manipulator/PullHeadManipulatorDeviceDriver.java b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/pull_head_manipulator/PullHeadManipulatorDeviceDriver.java index 037f15b01..91fe480fe 100644 --- a/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/pull_head_manipulator/PullHeadManipulatorDeviceDriver.java +++ b/acs2/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device_driver/two_conveyor/pull_head_manipulator/PullHeadManipulatorDeviceDriver.java @@ -256,11 +256,11 @@ public class PullHeadManipulatorDeviceDriver extends AbstractOpcDeviceDriver imp if (mode == 0) { this.setIsonline(false); - message = "universal_off-line"; + message = LangProcess.msg("universal_off-line"); //有报警 } else if (error != 0) { this.setIserror(true); - message = "universal_message3"; + message = LangProcess.msg("universal_message3"); //无报警 } else { this.setIsonline(true); diff --git a/acs2/nladmin-ui/src/views/system/monitor/device/index.vue b/acs2/nladmin-ui/src/views/system/monitor/device/index.vue index c9b68ee7a..5f84af01f 100644 --- a/acs2/nladmin-ui/src/views/system/monitor/device/index.vue +++ b/acs2/nladmin-ui/src/views/system/monitor/device/index.vue @@ -654,6 +654,9 @@ export default { } else if (val === 'task') { const obj = { name: i18n.t('monitor.click.task_number'), value: data[val] } this.arr.push(obj) + } else if (val === 'last_task') { + const obj = { name: '上次任务号', value: data[val] } + this.arr.push(obj) } else if (val === 'is_disable') { const obj = { name: i18n.t('monitor.click.disable'), value: data[val] } this.arr.push(obj)