更新双工rgv
This commit is contained in:
@@ -2,6 +2,7 @@ package org.nl.acs.device_driver.lnsh.lnsh_rgv;
|
|||||||
|
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.IdUtil;
|
import cn.hutool.core.util.IdUtil;
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
@@ -17,6 +18,8 @@ import org.nl.acs.instruction.service.InstructionService;
|
|||||||
import org.nl.acs.instruction.service.dto.Instruction;
|
import org.nl.acs.instruction.service.dto.Instruction;
|
||||||
import org.nl.acs.log.service.LogServer;
|
import org.nl.acs.log.service.LogServer;
|
||||||
import org.nl.acs.opc.Device;
|
import org.nl.acs.opc.Device;
|
||||||
|
import org.nl.acs.opc.DeviceAppService;
|
||||||
|
import org.nl.acs.opc.DeviceAppServiceImpl;
|
||||||
import org.nl.acs.opc.WcsConfig;
|
import org.nl.acs.opc.WcsConfig;
|
||||||
import org.nl.acs.route.service.RouteLineService;
|
import org.nl.acs.route.service.RouteLineService;
|
||||||
import org.nl.acs.route.service.dto.RouteLineDto;
|
import org.nl.acs.route.service.dto.RouteLineDto;
|
||||||
@@ -29,10 +32,7 @@ import org.nl.wql.core.bean.WQLObject;
|
|||||||
import org.openscada.opc.lib.da.Server;
|
import org.openscada.opc.lib.da.Server;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 嘉耐双工位RGV
|
* 嘉耐双工位RGV
|
||||||
@@ -52,13 +52,23 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
TaskService taskserver = SpringContextHolder.getBean("taskServiceImpl");
|
TaskService taskserver = SpringContextHolder.getBean("taskServiceImpl");
|
||||||
@Autowired
|
@Autowired
|
||||||
LogServer logServer = SpringContextHolder.getBean("logServerImpl");
|
LogServer logServer = SpringContextHolder.getBean("logServerImpl");
|
||||||
|
@Autowired
|
||||||
|
DeviceAppService deviceAppservice = SpringContextHolder.getBean(DeviceAppServiceImpl.class);
|
||||||
|
|
||||||
|
//当前指令1
|
||||||
|
Instruction inst1 = null;
|
||||||
|
//当前指令2
|
||||||
|
Instruction inst2 = null;
|
||||||
|
|
||||||
|
|
||||||
int mode = 0;
|
int mode = 0;
|
||||||
int error = 0;
|
int error = 0;
|
||||||
int last_mode = 0;
|
int last_mode = 0;
|
||||||
int last_error = 0;
|
int last_error = 0;
|
||||||
Boolean isonline = true;
|
Boolean isonline = true;
|
||||||
Boolean requireSucess = false;
|
Boolean requireSucess1 = false;
|
||||||
|
Boolean requireSucess2 = false;
|
||||||
|
|
||||||
int hasGoods = 0;
|
int hasGoods = 0;
|
||||||
String message = null;
|
String message = null;
|
||||||
Boolean iserror = false;
|
Boolean iserror = false;
|
||||||
@@ -113,6 +123,11 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
String specifications = "";
|
String specifications = "";
|
||||||
String last_specifications = "";
|
String last_specifications = "";
|
||||||
|
|
||||||
|
private Date instruction_require_time = new Date();
|
||||||
|
private Date instruction_finished_time = new Date();
|
||||||
|
private Date instruction_apply_time = new Date();
|
||||||
|
private int instruction_require_time_out = 3000;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Device getDevice() {
|
public Device getDevice() {
|
||||||
return this.device;
|
return this.device;
|
||||||
@@ -120,7 +135,7 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void execute() {
|
public void execute() throws Exception {
|
||||||
String message = null;
|
String message = null;
|
||||||
try {
|
try {
|
||||||
device_code = this.getDeviceCode();
|
device_code = this.getDeviceCode();
|
||||||
@@ -145,7 +160,6 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
qty = this.itemProtocol.getQty();
|
qty = this.itemProtocol.getQty();
|
||||||
|
|
||||||
if (mode != last_mode) {
|
if (mode != last_mode) {
|
||||||
this.setRequireSucess(false);
|
|
||||||
logServer.deviceLog(this.device_code,"mode" ,String.valueOf(mode));
|
logServer.deviceLog(this.device_code,"mode" ,String.valueOf(mode));
|
||||||
logServer.deviceLogToacs(this.device_code,"","","信号mode:" + last_mode + "->" + mode);
|
logServer.deviceLogToacs(this.device_code,"","","信号mode:" + last_mode + "->" + mode);
|
||||||
}
|
}
|
||||||
@@ -158,10 +172,16 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
logServer.deviceLogToacs(this.device_code,"","","信号status:" + last_status + "->" + status);
|
logServer.deviceLogToacs(this.device_code,"","","信号status:" + last_status + "->" + status);
|
||||||
}
|
}
|
||||||
if (move_1 != last_move_1) {
|
if (move_1 != last_move_1) {
|
||||||
|
if(move_1 == 0){
|
||||||
|
this.setRequireSucess1(false);
|
||||||
|
}
|
||||||
logServer.deviceLog(this.device_code,"move_1" ,String.valueOf(move_1));
|
logServer.deviceLog(this.device_code,"move_1" ,String.valueOf(move_1));
|
||||||
logServer.deviceLogToacs(this.device_code,"","","信号move_1:" + last_move_1 + "->" + move_1);
|
logServer.deviceLogToacs(this.device_code,"","","信号move_1:" + last_move_1 + "->" + move_1);
|
||||||
}
|
}
|
||||||
if (move_2 != last_move_2) {
|
if (move_2 != last_move_2) {
|
||||||
|
if(move_2 == 0){
|
||||||
|
this.setRequireSucess2(false);
|
||||||
|
}
|
||||||
logServer.deviceLog(this.device_code,"move_2" ,String.valueOf(move_2));
|
logServer.deviceLog(this.device_code,"move_2" ,String.valueOf(move_2));
|
||||||
logServer.deviceLogToacs(this.device_code,"","","信号move_2:" + last_move_2 + "->" + move_2);
|
logServer.deviceLogToacs(this.device_code,"","","信号move_2:" + last_move_2 + "->" + move_2);
|
||||||
}
|
}
|
||||||
@@ -222,6 +242,58 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
logServer.deviceLogToacs(this.device_code,"","","信号specifications:" + last_specifications + "->" + specifications);
|
logServer.deviceLogToacs(this.device_code,"","","信号specifications:" + last_specifications + "->" + specifications);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if (task1 > 0) {
|
||||||
|
//inst_message
|
||||||
|
inst1 = instructionService.findByCodeFromCache(String.valueOf(task1));
|
||||||
|
if (inst1 != null) {
|
||||||
|
if (StrUtil.equals(inst1.getInstruction_status(), "0")) {
|
||||||
|
inst1.setInstruction_status("1");
|
||||||
|
instructionService.update(inst1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( action_1 == 4 && move_1 == 0 && task1 > 0) {
|
||||||
|
//inst_message
|
||||||
|
inst1 = instructionService.findByCodeFromCache(String.valueOf(task1));
|
||||||
|
if (inst1 != null) {
|
||||||
|
if (StrUtil.equals(inst1.getInstruction_status(), "1")) {
|
||||||
|
finish_instruction(inst1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (task2 > 0) {
|
||||||
|
//inst_message
|
||||||
|
inst2 = instructionService.findByCodeFromCache(String.valueOf(task2));
|
||||||
|
if (inst2 != null) {
|
||||||
|
if (StrUtil.equals(inst2.getInstruction_status(), "0")) {
|
||||||
|
inst2.setInstruction_status("1");
|
||||||
|
instructionService.update(inst2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ( action_2 == 4 && move_2 == 0 && task2 > 0) {
|
||||||
|
//inst_message
|
||||||
|
inst2 = instructionService.findByCodeFromCache(String.valueOf(task2));
|
||||||
|
if (inst2 != null) {
|
||||||
|
if (StrUtil.equals(inst2.getInstruction_status(), "1")) {
|
||||||
|
finish_instruction(inst2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
//给后工位下发空盘放货信号
|
||||||
|
if(mode ==3 && action_1 == 2 && action_2 == 2 && move_1 == 1 && move_2 == 1 && task1>0 && task2>0 ){
|
||||||
|
writing("to_command2","2");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//给前工位下发放货信号
|
||||||
|
if(mode ==3 && action_2 == 4 && move_1 == 1 && move_2 == 0 && task1>0 ){
|
||||||
|
writing("to_command1","2");
|
||||||
|
}
|
||||||
|
|
||||||
} catch (Exception var17) {
|
} catch (Exception var17) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -252,8 +324,16 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
log.debug("设备运转模式:等待工作");
|
log.debug("设备运转模式:等待工作");
|
||||||
return;
|
return;
|
||||||
case 2:
|
case 2:
|
||||||
|
//后工位申请任务
|
||||||
|
if (mode == 2 && move_2 == 0 && action_2 == 0 && !requireSucess2) {
|
||||||
|
instruction_require2();
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
|
case 3:
|
||||||
|
//前工位申请任务
|
||||||
|
if (mode == 3 && move_2 == 1 && action_2 == 1 && move_1 == 0 && !requireSucess1) {
|
||||||
|
instruction_require();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (flag) {
|
switch (flag) {
|
||||||
@@ -291,6 +371,168 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//申请前工位任务
|
||||||
|
public synchronized boolean instruction_require() throws Exception {
|
||||||
|
Date date = new Date();
|
||||||
|
if (date.getTime() - this.instruction_apply_time.getTime() < (long) this.instruction_require_time_out) {
|
||||||
|
log.trace("触发时间因为小于{}毫秒,而被无视", this.instruction_require_time_out);
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
this.instruction_apply_time = date;
|
||||||
|
String linkobj = (String)this.getDevice().getExtraValue().get("get_device_code1");
|
||||||
|
String demosub = linkobj.substring(1,linkobj.length()-1);
|
||||||
|
String demoArray[] = demosub.split(",");
|
||||||
|
List<String> device_code_list = Arrays.asList(demoArray);
|
||||||
|
TaskDto task = null;
|
||||||
|
for(int i=0;i<device_code_list.size();i++){
|
||||||
|
task = taskserver.queryTaskByDeviceCode(device_code_list.get(i).replace("\"","")).get(0);
|
||||||
|
if(ObjectUtil.isNotEmpty(task)) break;
|
||||||
|
}
|
||||||
|
if (!ObjectUtil.isEmpty(task)) {
|
||||||
|
String taskid = task.getTask_id();
|
||||||
|
String taskcode = task.getTask_code();
|
||||||
|
String vehiclecode = task.getVehicle_code();
|
||||||
|
String priority = task.getPriority();
|
||||||
|
String start_point_code = task.getStart_point_code();
|
||||||
|
String start_device_code = task.getStart_device_code();
|
||||||
|
String route_plan_code = task.getRoute_plan_code();
|
||||||
|
String next_point_code = task.getNext_point_code();
|
||||||
|
String next_device_code = task.getNext_device_code();
|
||||||
|
Device startdevice = deviceAppservice.findDeviceByCode(start_device_code);
|
||||||
|
Device nextdevice = deviceAppservice.findDeviceByCode(next_device_code);
|
||||||
|
|
||||||
|
Instruction instdto = new Instruction();
|
||||||
|
instdto.setInstruction_id(IdUtil.simpleUUID());
|
||||||
|
instdto.setRoute_plan_code(route_plan_code);
|
||||||
|
instdto.setRemark(task.getRemark());
|
||||||
|
instdto.setMaterial(task.getMaterial());
|
||||||
|
instdto.setQuantity(task.getQuantity());
|
||||||
|
instdto.setTask_id(taskid);
|
||||||
|
instdto.setTask_code(taskcode);
|
||||||
|
instdto.setVehicle_code(vehiclecode);
|
||||||
|
String now = DateUtil.now();
|
||||||
|
instdto.setCreate_time(now);
|
||||||
|
instdto.setCreate_by("auto");
|
||||||
|
instdto.setStart_device_code(start_device_code);
|
||||||
|
instdto.setNext_device_code(next_device_code);
|
||||||
|
instdto.setStart_point_code(start_point_code);
|
||||||
|
instdto.setNext_point_code(next_point_code);
|
||||||
|
instdto.setPriority(priority);
|
||||||
|
instdto.setInstruction_status("0");
|
||||||
|
instdto.setExecute_device_code(start_point_code);
|
||||||
|
|
||||||
|
try {
|
||||||
|
instructionService.create(instdto);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
//创建指令后修改任务状态
|
||||||
|
WQLObject taskwo = WQLObject.getWQLObject("acs_task");
|
||||||
|
task.setTask_status("1");
|
||||||
|
//创建指令后修改任务状态
|
||||||
|
task.setTask_status("1");
|
||||||
|
taskserver.update(task);
|
||||||
|
requireSucess1 = true;
|
||||||
|
|
||||||
|
|
||||||
|
String start_addr = startdevice.getAddress();
|
||||||
|
String next_addr = nextdevice.getAddress();
|
||||||
|
|
||||||
|
writing("to_command1","1");
|
||||||
|
writing("to_onset1",start_addr);
|
||||||
|
writing("to_target1",next_addr);
|
||||||
|
writing("to_task1",instdto.getInstruction_code());
|
||||||
|
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
//申请后工位任务
|
||||||
|
public synchronized boolean instruction_require2() throws Exception {
|
||||||
|
Date date = new Date();
|
||||||
|
if (date.getTime() - this.instruction_apply_time.getTime() < (long) this.instruction_require_time_out) {
|
||||||
|
log.trace("触发时间因为小于{}毫秒,而被无视", this.instruction_require_time_out);
|
||||||
|
return false;
|
||||||
|
} else {
|
||||||
|
this.instruction_apply_time = date;
|
||||||
|
String linkobj = (String)this.getDevice().getExtraValue().get("get_device_code2");
|
||||||
|
String demosub = linkobj.substring(1,linkobj.length()-1);
|
||||||
|
String demoArray[] = demosub.split(",");
|
||||||
|
List<String> device_code_list = Arrays.asList(demoArray);
|
||||||
|
TaskDto task = null;
|
||||||
|
for(int i=0;i<device_code_list.size();i++){
|
||||||
|
task = taskserver.queryTaskByDeviceCode(device_code_list.get(i).replace("\"","")).get(0);
|
||||||
|
if(ObjectUtil.isNotEmpty(task)) break;
|
||||||
|
}
|
||||||
|
if (!ObjectUtil.isEmpty(task)) {
|
||||||
|
String taskid = task.getTask_id();
|
||||||
|
String taskcode = task.getTask_code();
|
||||||
|
String vehiclecode = task.getVehicle_code();
|
||||||
|
String priority = task.getPriority();
|
||||||
|
String start_point_code = task.getStart_point_code();
|
||||||
|
String start_device_code = task.getStart_device_code();
|
||||||
|
String route_plan_code = task.getRoute_plan_code();
|
||||||
|
String next_point_code = task.getNext_point_code();
|
||||||
|
String next_device_code = task.getNext_device_code();
|
||||||
|
Device startdevice = deviceAppservice.findDeviceByCode(start_device_code);
|
||||||
|
Device nextdevice = deviceAppservice.findDeviceByCode(next_device_code);
|
||||||
|
|
||||||
|
Instruction instdto = new Instruction();
|
||||||
|
instdto.setInstruction_id(IdUtil.simpleUUID());
|
||||||
|
instdto.setRoute_plan_code(route_plan_code);
|
||||||
|
instdto.setRemark(task.getRemark());
|
||||||
|
instdto.setMaterial(task.getMaterial());
|
||||||
|
instdto.setQuantity(task.getQuantity());
|
||||||
|
instdto.setTask_id(taskid);
|
||||||
|
instdto.setTask_code(taskcode);
|
||||||
|
instdto.setVehicle_code(vehiclecode);
|
||||||
|
String now = DateUtil.now();
|
||||||
|
instdto.setCreate_time(now);
|
||||||
|
instdto.setCreate_by("auto");
|
||||||
|
instdto.setStart_device_code(start_device_code);
|
||||||
|
instdto.setNext_device_code(next_device_code);
|
||||||
|
instdto.setStart_point_code(start_point_code);
|
||||||
|
instdto.setNext_point_code(next_point_code);
|
||||||
|
instdto.setPriority(priority);
|
||||||
|
instdto.setInstruction_status("0");
|
||||||
|
instdto.setExecute_device_code(start_point_code);
|
||||||
|
|
||||||
|
try {
|
||||||
|
instructionService.create(instdto);
|
||||||
|
} catch (Exception e) {
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
//创建指令后修改任务状态
|
||||||
|
WQLObject taskwo = WQLObject.getWQLObject("acs_task");
|
||||||
|
task.setTask_status("1");
|
||||||
|
//创建指令后修改任务状态
|
||||||
|
task.setTask_status("1");
|
||||||
|
taskserver.update(task);
|
||||||
|
requireSucess2 = true;
|
||||||
|
|
||||||
|
|
||||||
|
String start_addr = startdevice.getAddress();
|
||||||
|
String next_addr = nextdevice.getAddress();
|
||||||
|
|
||||||
|
writing("to_command2","1");
|
||||||
|
writing("to_onset2",start_addr);
|
||||||
|
writing("to_target2",next_addr);
|
||||||
|
writing("to_task2",instdto.getInstruction_code());
|
||||||
|
|
||||||
|
|
||||||
|
} else {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
public boolean exe_error() {
|
public boolean exe_error() {
|
||||||
if (this.error == 0) {
|
if (this.error == 0) {
|
||||||
return true;
|
return true;
|
||||||
@@ -300,6 +542,18 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void writing(String param, String value) {
|
||||||
|
|
||||||
|
String to_param = this.getDevice().getOpc_server_code() + "." + this.getDevice().getOpc_plc_code() + "." + this.getDevice().getDevice_code()
|
||||||
|
+ "." + param;
|
||||||
|
String opcservcerid = this.getDevice().getOpc_server_id();
|
||||||
|
Server server = ReadUtil.getServer(opcservcerid);
|
||||||
|
Map<String, Object> itemMap = new HashMap<String, Object>();
|
||||||
|
itemMap.put(to_param, value);
|
||||||
|
|
||||||
|
ReadUtil.write(itemMap, server);
|
||||||
|
}
|
||||||
|
|
||||||
public boolean exe_business() {
|
public boolean exe_business() {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -317,6 +571,13 @@ public class LnshRGVDeviceDriver extends AbstractOpcDeviceDriver implements Devi
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public synchronized boolean finish_instruction(Instruction inst) throws Exception {
|
||||||
|
instructionService.finish(inst);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public void executing(Server server, Map<String, Object> itemMap) {
|
public void executing(Server server, Map<String, Object> itemMap) {
|
||||||
ReadUtil.write(itemMap, server);
|
ReadUtil.write(itemMap, server);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -56,9 +56,9 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-col>
|
<el-col>
|
||||||
<el-form-item label="取货点" prop="device_code">
|
<el-form-item label="前工位取货点" prop="device_code" label-width="200">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.get_device_code"
|
v-model="form.get_device_code1"
|
||||||
multiple
|
multiple
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
>
|
>
|
||||||
@@ -69,9 +69,24 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="装货点" prop="device_code">
|
<!-- <el-form-item label="装货点" prop="device_code">-->
|
||||||
|
<!-- <el-select-->
|
||||||
|
<!-- v-model="form.load_device_code"-->
|
||||||
|
<!-- filterable-->
|
||||||
|
<!-- multiple-->
|
||||||
|
<!-- placeholder="请选择"-->
|
||||||
|
<!-- >-->
|
||||||
|
<!-- <el-option-->
|
||||||
|
<!-- v-for="item in deviceList"-->
|
||||||
|
<!-- :key="item.device_code"-->
|
||||||
|
<!-- :label="item.device_name"-->
|
||||||
|
<!-- :value="item.device_code"-->
|
||||||
|
<!-- />-->
|
||||||
|
<!-- </el-select>-->
|
||||||
|
<!-- </el-form-item>-->
|
||||||
|
<el-form-item label="前工位放货点" prop="device_code" label-width="200">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.load_device_code"
|
v-model="form.put_device_code1"
|
||||||
filterable
|
filterable
|
||||||
multiple
|
multiple
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
@@ -84,9 +99,39 @@
|
|||||||
/>
|
/>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="放货点" prop="device_code">
|
</el-col>
|
||||||
|
<el-col>
|
||||||
|
<el-form-item label="后工位取货点" prop="device_code" label-width="200">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="form.put_device_code"
|
v-model="form.get_device_code2"
|
||||||
|
multiple
|
||||||
|
placeholder="请选择"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="item in deviceList"
|
||||||
|
:label="item.device_name"
|
||||||
|
:value="item.device_code"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<!-- <el-form-item label="装货点" prop="device_code">-->
|
||||||
|
<!-- <el-select-->
|
||||||
|
<!-- v-model="form.load_device_code"-->
|
||||||
|
<!-- filterable-->
|
||||||
|
<!-- multiple-->
|
||||||
|
<!-- placeholder="请选择"-->
|
||||||
|
<!-- >-->
|
||||||
|
<!-- <el-option-->
|
||||||
|
<!-- v-for="item in deviceList"-->
|
||||||
|
<!-- :key="item.device_code"-->
|
||||||
|
<!-- :label="item.device_name"-->
|
||||||
|
<!-- :value="item.device_code"-->
|
||||||
|
<!-- />-->
|
||||||
|
<!-- </el-select>-->
|
||||||
|
<!-- </el-form-item>-->
|
||||||
|
<el-form-item label="后工位放货点" prop="device_code" label-width="200">
|
||||||
|
<el-select
|
||||||
|
v-model="form.put_device_code2"
|
||||||
filterable
|
filterable
|
||||||
multiple
|
multiple
|
||||||
placeholder="请选择"
|
placeholder="请选择"
|
||||||
@@ -326,9 +371,11 @@ export default {
|
|||||||
plc_code: '',
|
plc_code: '',
|
||||||
opc_id: '',
|
opc_id: '',
|
||||||
opc_code: '',
|
opc_code: '',
|
||||||
get_device_code: '',
|
get_device_code1: '',
|
||||||
|
get_device_code2: '',
|
||||||
load_device_code: '',
|
load_device_code: '',
|
||||||
put_device_code: '',
|
put_device_code: '',
|
||||||
|
put_device_code2: '',
|
||||||
configLoading: false,
|
configLoading: false,
|
||||||
dataOpcservers: [],
|
dataOpcservers: [],
|
||||||
dataOpcPlcs: [],
|
dataOpcPlcs: [],
|
||||||
|
|||||||
Reference in New Issue
Block a user