前端修改 机械手双工位任务完成修改 工单反馈mes修改为系统参数控制
This commit is contained in:
@@ -214,26 +214,26 @@ public class HfGantryManipulatorDeviceDriver extends AbstractOpcDeviceDriver imp
|
||||
if (StrUtil.equals(inst2.getInstruction_status(), "1")) {
|
||||
this.finish_instruction(inst2);
|
||||
//获取当前工单数量
|
||||
TaskDto taskDto = taskserver.findByCode(inst2.getTask_code());
|
||||
if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
String next_device_code = inst2.getNext_device_code();
|
||||
Device device = appService.findDeviceByCode(next_device_code);
|
||||
HfStationDeviceDriver hfStationDeviceDriver;
|
||||
String current_num = "";
|
||||
if (device.getDeviceDriver() instanceof HfStationDeviceDriver) {
|
||||
hfStationDeviceDriver = (HfStationDeviceDriver) device.getDeviceDriver();
|
||||
current_num = String.valueOf(hfStationDeviceDriver.getCurrent_order_num());
|
||||
}
|
||||
JSONArray array = new JSONArray();
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("task_id", taskDto.getExt_task_id());
|
||||
map.put("task_status", "2");
|
||||
map.put("material_num", current_num);
|
||||
array.add(map);
|
||||
acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
}
|
||||
}
|
||||
// TaskDto taskDto = taskserver.findByCode(inst2.getTask_code());
|
||||
// if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
// if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
// String next_device_code = inst2.getNext_device_code();
|
||||
// Device device = appService.findDeviceByCode(next_device_code);
|
||||
// HfStationDeviceDriver hfStationDeviceDriver;
|
||||
// String current_num = "";
|
||||
// if (device.getDeviceDriver() instanceof HfStationDeviceDriver) {
|
||||
// hfStationDeviceDriver = (HfStationDeviceDriver) device.getDeviceDriver();
|
||||
// current_num = String.valueOf(hfStationDeviceDriver.getCurrent_order_num());
|
||||
// }
|
||||
// JSONArray array = new JSONArray();
|
||||
// JSONObject map = new JSONObject();
|
||||
// map.put("task_id", taskDto.getExt_task_id());
|
||||
// map.put("task_status", "2");
|
||||
// map.put("material_num", current_num);
|
||||
// array.add(map);
|
||||
// acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
// }
|
||||
// }
|
||||
logServer.deviceInfo("反馈电气信号", this.getDevice_code(), "机械手任务完成,开始反馈电气信号");
|
||||
this.writing("to_onset", "0");
|
||||
this.writing("to_target", "0");
|
||||
|
||||
@@ -206,18 +206,18 @@ public class HfTwoRGVDeviceDriver extends AbstractOpcDeviceDriver implements Dev
|
||||
if (inst1 != null) {
|
||||
if (StrUtil.equals(inst1.getInstruction_status(), "1")) {
|
||||
finish_instruction(inst1);
|
||||
JSONArray array = new JSONArray();
|
||||
TaskDto taskDto = taskserver.findByCode(inst1.getTask_code());
|
||||
if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("task_id", taskDto.getExt_task_id());
|
||||
map.put("task_status", "2");
|
||||
map.put("finished_type", "1");
|
||||
array.add(map);
|
||||
acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
}
|
||||
}
|
||||
// JSONArray array = new JSONArray();
|
||||
// TaskDto taskDto = taskserver.findByCode(inst1.getTask_code());
|
||||
// if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
// if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
// JSONObject map = new JSONObject();
|
||||
// map.put("task_id", taskDto.getExt_task_id());
|
||||
// map.put("task_status", "2");
|
||||
// map.put("finished_type", "1");
|
||||
// array.add(map);
|
||||
// acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
// }
|
||||
// }
|
||||
logServer.deviceInfo("反馈电气信号", this.getDevice_code(), "RGV前工位任务完成,开始反馈电气信号");
|
||||
this.writing("to_command1", "0");
|
||||
this.writing("to_onset1", "0");
|
||||
@@ -249,18 +249,18 @@ public class HfTwoRGVDeviceDriver extends AbstractOpcDeviceDriver implements Dev
|
||||
if (inst2 != null) {
|
||||
if (StrUtil.equals(inst2.getInstruction_status(), "1")) {
|
||||
finish_instruction(inst2);
|
||||
JSONArray array = new JSONArray();
|
||||
TaskDto taskDto = taskserver.findByCode(inst2.getTask_code());
|
||||
if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
JSONObject map = new JSONObject();
|
||||
map.put("task_id", taskDto.getExt_task_id());
|
||||
map.put("task_status", "2");
|
||||
map.put("finished_type", "1");
|
||||
array.add(map);
|
||||
acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
}
|
||||
}
|
||||
// JSONArray array = new JSONArray();
|
||||
// TaskDto taskDto = taskserver.findByCode(inst2.getTask_code());
|
||||
// if (ObjectUtil.isNotEmpty(taskDto)) {
|
||||
// if (StrUtil.isNotEmpty(taskDto.getExt_task_id())) {
|
||||
// JSONObject map = new JSONObject();
|
||||
// map.put("task_id", taskDto.getExt_task_id());
|
||||
// map.put("task_status", "2");
|
||||
// map.put("finished_type", "1");
|
||||
// array.add(map);
|
||||
// acsToWmsService.feedbackTaskStatusToWms(array);
|
||||
// }
|
||||
// }
|
||||
logServer.deviceInfo("反馈电气信号", this.getDevice_code(), "RGV后工位任务完成,开始反馈电气信号");
|
||||
this.writing("to_command2", "0");
|
||||
this.writing("to_onset2", "0");
|
||||
|
||||
Reference in New Issue
Block a user