psh 2 years ago
parent
commit
c4d496e1c6
  1. 5
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/auto/initial/ApplicationAutoInitialExecuter.java
  2. 16
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/auto/run/AutoRunServiceImpl.java
  3. 3
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java
  4. 3
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java
  5. 6
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/DeviceAppServiceImpl.java
  6. 3
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/DeviceManageServiceImpl.java
  7. 18
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/OpcServerServiceImpl.java
  8. 4
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/route/service/impl/RouteLineServiceImpl.java
  9. 4
      acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/task/service/impl/TaskServiceImpl.java
  10. 16
      acs/nladmin-ui/src/views/acs/device/storageCell/index.vue
  11. 48
      acs/nladmin-ui/src/views/system/logicflow/editor/components/DiagramToolbar.vue
  12. 320
      acs/nladmin-ui/src/views/system/monitor/device/index.vue

5
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/auto/initial/ApplicationAutoInitialExecuter.java

@ -10,6 +10,9 @@ import java.util.List;
@Component @Component
public class ApplicationAutoInitialExecuter { public class ApplicationAutoInitialExecuter {
/**
* 获取所有实现ApplicationAutoInitial接口的bean对象
*/
@Autowired(required = false) @Autowired(required = false)
List<ApplicationAutoInitial> applicationAutoInitial; List<ApplicationAutoInitial> applicationAutoInitial;
//是否启动 //是否启动
@ -25,7 +28,7 @@ public class ApplicationAutoInitialExecuter {
while (it.hasNext()) { while (it.hasNext()) {
ApplicationAutoInitial service = (ApplicationAutoInitial) it.next(); ApplicationAutoInitial service = (ApplicationAutoInitial) it.next();
service.autoInitial(); service.autoInitial(); // 执行实现的autoInitial方法
} }

16
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/auto/run/AutoRunServiceImpl.java

@ -13,15 +13,18 @@ import org.springframework.stereotype.Service;
import java.util.*; import java.util.*;
/**
* 初始化启动线程
*/
@Service @Service
@Slf4j @Slf4j
public class AutoRunServiceImpl implements AutoRunService, ApplicationAutoInitial { public class AutoRunServiceImpl implements AutoRunService, ApplicationAutoInitial {
@Autowired(required = false) @Autowired(required = false)
private List<AbstractAutoRunnable> abstractAutoRunnableList; private List<AbstractAutoRunnable> abstractAutoRunnableList;
private List<String> autoRun_code_index = new ArrayList(); private List<AbstractAutoRunnable> thread_autoRun = new ArrayList(); // 线程类
private List<Thread> threads = new ArrayList(); private List<String> autoRun_code_index = new ArrayList(); // key
private List<AbstractAutoRunnable> thread_autoRun = new ArrayList(); private List<Thread> threads = new ArrayList(); // 运行线程
private List<String> thread_code_index = new ArrayList(); private List<String> thread_code_index = new ArrayList(); // key
@Override @Override
public synchronized void startThread(String threadCode) { public synchronized void startThread(String threadCode) {
@ -172,8 +175,13 @@ public class AutoRunServiceImpl implements AutoRunService, ApplicationAutoInitia
: new LinkedList(); : new LinkedList();
} }
/**
* 自动初始化线程
* @throws Exception
*/
@Override @Override
public void autoInitial() throws Exception { public void autoInitial() throws Exception {
// 获取所有的类型为AbstractAutoRunnable的bean
List<AbstractAutoRunnable> list = this.getAllAutoThread(); List<AbstractAutoRunnable> list = this.getAllAutoThread();
Iterator it = list.iterator(); Iterator it = list.iterator();

3
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/device/service/impl/DeviceServiceImpl.java

@ -1776,6 +1776,9 @@ public class DeviceServiceImpl extends CommonServiceImpl<DeviceMapper, Device> i
this.reload(); this.reload();
} }
/**
* 加载货位信息
*/
@Override @Override
public void reload() { public void reload() {
this.storageCells = queryAllStorageCell(); this.storageCells = queryAllStorageCell();

3
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/instruction/service/impl/InstructionServiceImpl.java

@ -159,6 +159,9 @@ public class InstructionServiceImpl extends CommonServiceImpl<InstructionMapper,
} }
}*/ }*/
/**
* 加载指令数据
*/
@Override @Override
public void autoInitial() { public void autoInitial() {
this.reload(); this.reload();

6
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/DeviceAppServiceImpl.java

@ -20,8 +20,8 @@ import java.util.*;
@Slf4j @Slf4j
@Service @Service
public class DeviceAppServiceImpl implements DeviceAppService, ApplicationAutoInitial { public class DeviceAppServiceImpl implements DeviceAppService, ApplicationAutoInitial {
private List<Device> devices = new ArrayList(); private List<Device> devices = new ArrayList(); // 所有设备链表
private List<String> code_indexs = new ArrayList(); private List<String> code_indexs = new ArrayList(); // 设备对应的下表
@Autowired @Autowired
private DeviceManageService deviceManageService; private DeviceManageService deviceManageService;
@Autowired @Autowired
@ -315,7 +315,7 @@ public class DeviceAppServiceImpl implements DeviceAppService, ApplicationAutoIn
} }
public synchronized void reload() { public synchronized void reload() {
List<DeviceManageDto> deviceManageDtos = this.deviceManageService.queryAllWithExtra(); List<DeviceManageDto> deviceManageDtos = deviceManageService.queryAllWithExtra();
this.devices = new ArrayList(); this.devices = new ArrayList();
Collections.synchronizedList(this.devices); Collections.synchronizedList(this.devices);
this.code_indexs = new ArrayList(); this.code_indexs = new ArrayList();

3
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/DeviceManageServiceImpl.java

@ -42,13 +42,16 @@ public class DeviceManageServiceImpl implements DeviceManageService {
@Override @Override
public List<DeviceManageDto> queryAllWithExtra() { public List<DeviceManageDto> queryAllWithExtra() {
// JSONArray arr = WQLObject.getWQLObject("acs_device").query().getResultJSONArray(0); // JSONArray arr = WQLObject.getWQLObject("acs_device").query().getResultJSONArray(0);
// 获取所有的设备
List<Device> deviceList= new LambdaQueryChainWrapper<>(deviceMapper).list(); List<Device> deviceList= new LambdaQueryChainWrapper<>(deviceMapper).list();
JSONArray arr = JSONArray.parseArray(JSON.toJSONString(deviceList)); JSONArray arr = JSONArray.parseArray(JSON.toJSONString(deviceList));
// 获取列表扩展
// JSONArray extArr = WQLObject.getWQLObject("acs_device_extra").query().getResultJSONArray(0); // JSONArray extArr = WQLObject.getWQLObject("acs_device_extra").query().getResultJSONArray(0);
List<DeviceExtra> deviceExtraList= new LambdaQueryChainWrapper<>(deviceExtraMapper).list(); List<DeviceExtra> deviceExtraList= new LambdaQueryChainWrapper<>(deviceExtraMapper).list();
JSONArray extArr = JSONArray.parseArray(JSON.toJSONString(deviceExtraList)); JSONArray extArr = JSONArray.parseArray(JSON.toJSONString(deviceExtraList));
// 设备+扩展DTO
List<DeviceExtraManageDto> extras = extArr.toJavaList(DeviceExtraManageDto.class); List<DeviceExtraManageDto> extras = extArr.toJavaList(DeviceExtraManageDto.class);
// WQLObject runpointTab = WQLObject.getWQLObject("acs_device_runpoint"); // WQLObject runpointTab = WQLObject.getWQLObject("acs_device_runpoint");

18
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/opc/OpcServerServiceImpl.java

@ -31,19 +31,24 @@ import java.util.Map;
public class OpcServerServiceImpl implements OpcServerService, ApplicationAutoInitial { public class OpcServerServiceImpl implements OpcServerService, ApplicationAutoInitial {
private static final Logger log = LoggerFactory.getLogger(OpcServerServiceImpl.class); private static final Logger log = LoggerFactory.getLogger(OpcServerServiceImpl.class);
@Autowired OpcServerManageService opcServerManageService; @Autowired
OpcServerManageService opcServerManageService;
Map<String, OpcServerManageDto> opcServerManageDtos = new HashMap(); Map<String, OpcServerManageDto> opcServerManageDtos = new HashMap();
Map<String, Server> servers = Collections.synchronizedMap(new HashMap()); Map<String, Server> servers = Collections.synchronizedMap(new HashMap());
Map<String, Group> groups = Collections.synchronizedMap(new HashMap()); Map<String, Group> groups = Collections.synchronizedMap(new HashMap());
public OpcServerServiceImpl() {} public OpcServerServiceImpl() {
}
/**
* 加载opc服务启动opc线程
* @throws Exception
*/
public void autoInitial() throws Exception { public void autoInitial() throws Exception {
this.reload(); this.reload(); // 加载opc服务
if (OpcConfig.auto_start_opc) { if (OpcConfig.auto_start_opc) {
Thread t = Thread t =
new Thread() { new Thread(() -> {
public void run() {
Iterator var1 = OpcServerServiceImpl.this.opcServerManageDtos.values().iterator(); Iterator var1 = OpcServerServiceImpl.this.opcServerManageDtos.values().iterator();
while (var1.hasNext()) { while (var1.hasNext()) {
@ -56,8 +61,7 @@ public class OpcServerServiceImpl implements OpcServerService, ApplicationAutoIn
OpcServerServiceImpl.log.warn("启动无法载入servers", var4); OpcServerServiceImpl.log.warn("启动无法载入servers", var4);
} }
} }
} });
};
t.start(); t.start();
} }
} }

4
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/route/service/impl/RouteLineServiceImpl.java

@ -514,6 +514,10 @@ public class RouteLineServiceImpl extends CommonServiceImpl<RouteLineMapper, Rou
return false; return false;
} }
/**
* 加载路由路线
* @throws SQLException
*/
@Override @Override
public void reload() throws SQLException { public void reload() throws SQLException {
Object[] param = new Object[0]; Object[] param = new Object[0];

4
acs/nladmin-system/nlsso-server/src/main/java/org/nl/acs/task/service/impl/TaskServiceImpl.java

@ -246,6 +246,10 @@ public class TaskServiceImpl extends CommonServiceImpl<TaskMapper, Task> impleme
FileUtil.downloadExcel(list, response); FileUtil.downloadExcel(list, response);
}*/ }*/
/**
* 获取未完成任务
* @throws Exception
*/
@Override @Override
public void autoInitial() throws Exception { public void autoInitial() throws Exception {
Class var1 = TaskInstructionLock.class; Class var1 = TaskInstructionLock.class;

16
acs/nladmin-ui/src/views/acs/device/storageCell/index.vue

@ -12,6 +12,22 @@
style="width: 200px;" style="width: 200px;"
class="filter-item" class="filter-item"
/> />
<el-input
v-model="query.parent_storage_code"
size="small"
clearable
placeholder="输入父级货位编码"
style="width: 200px;"
class="filter-item"
/>
<el-input
v-model="query.address"
size="small"
clearable
placeholder="输入agv站点"
style="width: 200px;"
class="filter-item"
/>
<rrOperation /> <rrOperation />
</div> </div>
<!--如果想在工具栏加入更多按钮可以使用插槽方式 slot = 'left' or 'right'--> <!--如果想在工具栏加入更多按钮可以使用插槽方式 slot = 'left' or 'right'-->

48
acs/nladmin-ui/src/views/system/logicflow/editor/components/DiagramToolbar.vue

@ -24,40 +24,64 @@
<step-foward size="18" /> <step-foward size="18" />
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_lock">锁定</el-button> <el-tooltip class="item" effect="dark" content="锁定" placement="top">
<svg-icon class="toolbar-item" icon-class="lock" @click="$_lock"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_unlock">解锁</el-button> <el-tooltip class="item" effect="dark" content="解锁" placement="top">
<svg-icon class="toolbar-item" icon-class="unlock" @click="$_unlock"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_verticalAlign">垂直居中</el-button> <el-tooltip class="item" effect="dark" content="垂直对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="verticalAlign" @click="$_verticalAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_horizontalAlign">水平居中</el-button> <el-tooltip class="item" effect="dark" content="水平对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="horizontalAlign" @click="$_horizontalAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_leftAlign">向左对齐</el-button> <el-tooltip class="item" effect="dark" content="左边对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="leftAlign" @click="$_leftAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_rightAlign">向右对齐</el-button> <el-tooltip class="item" effect="dark" content="右边对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="rightAlign" @click="$_rightAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_upAlign">向上对齐</el-button> <el-tooltip class="item" effect="dark" content="顶部对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="upAlign" @click="$_upAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_downAlign">向下对齐</el-button> <el-tooltip class="item" effect="dark" content="底部对齐" placement="top">
<svg-icon class="toolbar-item" icon-class="downAlign" @click="$_downAlign"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_horizontalDistribution">水平分布</el-button> <el-tooltip class="item" effect="dark" content="水平分布" placement="top">
<svg-icon class="toolbar-item" icon-class="verticalDistribution" @click="$_horizontalDistribution"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_verticalDistribution">垂直分布</el-button> <el-tooltip class="item" effect="dark" content="垂直分布" placement="top">
<svg-icon class="toolbar-item" icon-class="horizontalDistribution" @click="$_verticalDistribution"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_cleanGraph">清空画布</el-button> <el-tooltip class="item" effect="dark" content="清空画布" placement="top">
<svg-icon class="toolbar-item" icon-class="clear" @click="$_cleanGraph"/>
</el-tooltip>
</div> </div>
<div style="margin-right: 5px"> <div style="margin-right: 5px">
<el-button size="mini" type="primary" @click="$_saveGraph">保存</el-button> <el-tooltip class="item" effect="dark" content="保存" placement="top">
<svg-icon class="toolbar-item" icon-class="save" @click="$_saveGraph"/>
</el-tooltip>
</div> </div>
<div> <div>
<el-select v-model="linetype" size="mini" @change="$_changeLineType" style="width: 80px"> <el-select v-model="linetype" size="mini" @change="$_changeLineType" style="width: 80px">

320
acs/nladmin-ui/src/views/system/monitor/device/index.vue

@ -37,10 +37,10 @@
</el-form-item> </el-form-item>
<el-form-item label="设备状态" label-width="80px"> <el-form-item label="设备状态" label-width="80px">
<el-radio-group v-model="form.hasGoodStatus"> <el-radio-group v-model="form.option">
<el-radio-button :label="0">无货</el-radio-button> <el-radio-button :label="0">禁止进出</el-radio-button>
<el-radio-button :label="1">有托盘</el-radio-button> <el-radio-button :label="1">允许进入</el-radio-button>
<el-radio-button :label="2">有托盘有货</el-radio-button> <el-radio-button :label="2">允许离开</el-radio-button>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -59,8 +59,8 @@
<el-form-item label="设备状态" label-width="80px"> <el-form-item label="设备状态" label-width="80px">
<el-radio-group v-model="form.hasGoodStatus"> <el-radio-group v-model="form.hasGoodStatus">
<el-radio-button :label="0">无货</el-radio-button> <el-radio-button :label="0">无货</el-radio-button>
<el-radio-button :label="1">空料斗</el-radio-button> <el-radio-button :label="1">有托盘</el-radio-button>
<el-radio-button :label="2">满料斗</el-radio-button> <el-radio-button :label="2">有托盘有货</el-radio-button>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="物料编码" prop="material_type" label-width="80px"> <el-form-item label="物料编码" prop="material_type" label-width="80px">
@ -79,21 +79,84 @@
<el-form-item label="设备编号" prop="device_code" label-width="120px"> <el-form-item label="设备编号" prop="device_code" label-width="120px">
<el-input v-model="form.device_code" :disabled="true" /> <el-input v-model="form.device_code" :disabled="true" />
</el-form-item> </el-form-item>
<el-form-item label="缺料请求成功" prop="requireSucess" label-width="120px"> <el-form-item label="禁用机械手" prop="is_disable" label-width="120px">
<el-radio-group v-model="form.is_disable">
<el-radio-button :label="0">正常</el-radio-button>
<el-radio-button :label="1">禁用</el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item label="请求标记" prop="requireSucess" label-width="120px">
<el-radio-group v-model="form.requireSucess"> <el-radio-group v-model="form.requireSucess">
<el-radio-button :label="0"></el-radio-button> <el-radio-button :label="0"></el-radio-button>
<el-radio-button :label="1"></el-radio-button> <el-radio-button :label="1"></el-radio-button>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label="空想请求成功" prop="fullrequireSucess" label-width="120px"> </el-form>
<el-radio-group v-model="form.fullrequireSucess"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible4 = false"> </el-button>
<el-button type="primary" @click="dialogSave"> </el-button>
</div>
</el-dialog>
<el-dialog title="设备设置" :visible.sync="dialogFormVisible5" width="35%">
<el-form :model="form" size="small">
<el-form-item label="设备编号" prop="device_code" label-width="120px">
<el-input v-model="form.device_code" :disabled="true" />
</el-form-item>
<el-form-item label="请求标记" prop="requireSucess" label-width="120px">
<el-radio-group v-model="form.requireSucess">
<el-radio-button :label="0"></el-radio-button> <el-radio-button :label="0"></el-radio-button>
<el-radio-button :label="1"></el-radio-button> <el-radio-button :label="1"></el-radio-button>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible4 = false"> </el-button> <el-button @click="dialogFormVisible5 = false"> </el-button>
<el-button type="primary" @click="dialogSave"> </el-button>
</div>
</el-dialog>
<el-dialog title="设备设置" :visible.sync="dialogFormVisible7" width="35%">
<el-form :model="form" size="small">
<el-form-item label="设备编号" prop="device_code" label-width="120px">
<el-input v-model="form.device_code" :disabled="true" />
</el-form-item>
<el-form-item label="条码" label-width="120px">
<el-input v-model="form.hand_barcode" :disabled="false" />
</el-form-item>
<el-form-item label="请求标记" prop="requireSucess" label-width="120px">
<el-radio-group v-model="form.requireSucess">
<el-radio-button :label="0"></el-radio-button>
<el-radio-button :label="1"></el-radio-button>
</el-radio-group>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible7 = false"> </el-button>
<el-button type="primary" @click="dialogSave"> </el-button>
</div>
</el-dialog>
<el-dialog title="设备设置" :visible.sync="dialogFormVisible6" width="35%">
<el-form :model="form" size="small">
<el-form-item label="设备编号" prop="device_code" label-width="120px">
<el-input v-model="form.device_code" :disabled="true" />
</el-form-item>
<el-form-item label="申请指令标记" prop="requireSucess" label-width="120px">
<el-radio-group v-model="form.requireSucess">
<el-radio-button :label="0"></el-radio-button>
<el-radio-button :label="1"></el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item label="请求任务标记" prop="applySucess" label-width="120px">
<el-radio-group v-model="form.applySucess">
<el-radio-button :label="0"></el-radio-button>
<el-radio-button :label="1"></el-radio-button>
</el-radio-group>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible5 = false"> </el-button>
<el-button type="primary" @click="dialogSave"> </el-button> <el-button type="primary" @click="dialogSave"> </el-button>
</div> </div>
</el-dialog> </el-dialog>
@ -105,7 +168,7 @@
<el-input v-model="form.device_code" :disabled="true" /> <el-input v-model="form.device_code" :disabled="true" />
</el-form-item> </el-form-item>
<el-form-item label="条码" label-width="80px"> <el-form-item label="条码" prop="device_code" label-width="80px">
<el-input v-model="form.barcode" :disabled="false" /> <el-input v-model="form.barcode" :disabled="false" />
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -127,6 +190,7 @@ import '@logicflow/extension/lib/style/index.css'
import { LogicFlow } from '@logicflow/core' import { LogicFlow } from '@logicflow/core'
import { registerCustomElement } from '@/views/system/logicflow/editor/components/node' import { registerCustomElement } from '@/views/system/logicflow/editor/components/node'
let data = {} let data = {}
let lf = '' let lf = ''
export default { export default {
@ -145,14 +209,20 @@ export default {
dialogFormVisible2: false, dialogFormVisible2: false,
dialogFormVisible3: false, dialogFormVisible3: false,
dialogFormVisible4: false, dialogFormVisible4: false,
dialogFormVisible5: false,
dialogFormVisible6: false,
dialogFormVisible7: false,
form: { form: {
device_code: '', device_code: '',
hasGoodStatus: null, hasGoodStatus: null,
barcode: '', barcode: '',
hand_barcode: '',
suspended: null, suspended: null,
material_type: '', material_type: '',
requireSucess: '', requireSucess: '',
fullrequireSucess: '' fullrequireSucess: '',
is_disable: '',
applySucess: ''
}, },
allDeviceMsg: [], allDeviceMsg: [],
msgTop: '200px', msgTop: '200px',
@ -274,12 +344,26 @@ export default {
if (clickObj.data.device_type === 'scanner') { // if (clickObj.data.device_type === 'scanner') { //
this.dialogFormVisible1 = true this.dialogFormVisible1 = true
} else { } else {
console.log(clickObj.data.driver_type)
if (clickObj.data.driver_type === 'standard_ordinary_site') { if (clickObj.data.driver_type === 'standard_ordinary_site') {
this.dialogFormVisible3 = true this.dialogFormVisible3 = true
} else if (clickObj.data.driver_type === 'hailiang_packer_station') { } else if (clickObj.data.driver_type === 'hailiang_packer_station') {
this.dialogFormVisible4 = true this.dialogFormVisible4 = true
} else if (clickObj.data.driver_type === 'hailiang_xj_plc_test') { } else if (clickObj.data.driver_type === 'hailiang_xj_plc_test') {
this.$refs.child1.setForm(clickObj) this.$refs.child1.setForm(clickObj)
} else if (clickObj.data.driver_type === 'slit_two_manipulator') {
this.dialogFormVisible4 = true
} else if (clickObj.data.driver_type === 'siemens_conveyor') {
// if (clickObj.data.device_name.includes('1016')) {
// this.dialogFormVisible7 = true
// } else {
// this.dialogFormVisible5 = true
// }
this.dialogFormVisible7 = true
} else if (clickObj.data.driver_type === 'siemens_conveyor_ckk') {
this.dialogFormVisible7 = true
} else if (clickObj.data.driver_type === 'standard_conveyor_control_with_scanner') {
this.dialogFormVisible6 = true
} else { } else {
this.dialogFormVisible = true this.dialogFormVisible = true
} }
@ -291,6 +375,10 @@ export default {
this.form.material_type = clickObj.data.material_type this.form.material_type = clickObj.data.material_type
this.form.requireSucess = clickObj.data.requireSucess this.form.requireSucess = clickObj.data.requireSucess
this.form.fullrequireSucess = clickObj.data.fullrequireSucess this.form.fullrequireSucess = clickObj.data.fullrequireSucess
this.form.is_disable = clickObj.data.is_disable1
this.form.applySucess = clickObj.data.applySucess
this.form.barcode = clickObj.data.barcode
this.form.hand_barcode = clickObj.data.hand_barcode
}, },
moveShow(nodeData) { // ---- moveShow(nodeData) { // ----
let item = '' let item = ''
@ -326,10 +414,10 @@ export default {
const obj = { name: '光电信号', value: data[val] } const obj = { name: '光电信号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'mode') { } else if (val === 'mode') {
const obj = { name: '工作模式', value: data[val] } const obj = { name: '模式', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'error') { } else if (val === 'error') {
const obj = { name: '故障代码', value: data[val] } const obj = { name: '报警', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'ip') { } else if (val === 'ip') {
const obj = { name: 'IP地址', value: data[val] } const obj = { name: 'IP地址', value: data[val] }
@ -337,21 +425,33 @@ export default {
} else if (val === 'number') { } else if (val === 'number') {
const obj = { name: '托盘数量', value: data[val] } const obj = { name: '托盘数量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'instruction_message') { } else if (val === 'inst_message') {
const obj = { name: '指令信息', value: data[val] } const obj = { name: '指令信息', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'last_instruction_message') { } else if (val === 'message') {
const obj = { name: '备注信息', value: data[val] }
this.arr.push(obj)
} else if (val === 'inst_message') {
const obj = { name: '当前指令信息', value: data[val] }
this.arr.push(obj)
} else if (val === 'last_inst_message') {
const obj = { name: '上次指令信息', value: data[val] } const obj = { name: '上次指令信息', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'container') { } else if (val === 'barcode') {
const obj = { name: '载具号', value: data[val] } const obj = { name: '载具号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'barcode_length') {
const obj = { name: '载具长度', value: data[val] }
this.arr.push(obj)
} else if (val === 'last_container') { } else if (val === 'last_container') {
const obj = { name: '上次载具号', value: data[val] } const obj = { name: '上次载具号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'instruction_code') { } else if (val === 'instruction_code') {
const obj = { name: '指令号', value: data[val] } const obj = { name: '指令号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'task_code') {
const obj = { name: '任务号', value: data[val] }
this.arr.push(obj)
} else if (val === 'last_instruction_code') { } else if (val === 'last_instruction_code') {
const obj = { name: '上次指令号', value: data[val] } const obj = { name: '上次指令号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
@ -373,140 +473,140 @@ export default {
} else if (val === 'applySucess') { } else if (val === 'applySucess') {
const obj = { name: '是否申请指令', value: data[val] } const obj = { name: '是否申请指令', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'message') { } else if (val === 'requireApplyLabelingSuccess') {
const obj = { name: '说明', value: data[val] } const obj = { name: '是否申请贴标', value: data[val] }
this.arr.push(obj)
} else if (val === 'requireApplyLaStrangulationSuccess') {
const obj = { name: '是否申请捆扎', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'status') { } else if (val === 'status') {
const obj = { name: '设备状态', value: data[val] } const obj = { name: '设备状态', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'open_time') { } else if (val === 'weight') {
const obj = { name: '开机时间', value: data[val] } const obj = { name: '重量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'close_time') { } else if (val === 'move_1') {
const obj = { name: '关机时间', value: data[val] } const obj = { name: '前工位光电信号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'standby_time') { } else if (val === 'open') {
const obj = { name: '待机时间', value: data[val] } const obj = { name: '开到位', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'production_time') { } else if (val === 'close') {
const obj = { name: '生产时间', value: data[val] } const obj = { name: '关到位', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'error_time') { } else if (val === 'phase') {
const obj = { name: '故障时间', value: data[val] } const obj = { name: 'AGV交互阶段', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'weight') { } else if (val === 'phase_name') {
const obj = { name: '生产重量', value: data[val] } const obj = { name: 'AGV交互阶段说明', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'order_No') { } else if (val === 'option') {
const obj = { name: '工单号', value: data[val] } const obj = { name: 'AGV动作', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'mix_num') { } else if (val === 'agv_power') {
const obj = { name: '碾次', value: data[val] } const obj = { name: 'AGV电量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'barcode') { } else if (val === 'move_2') {
const obj = { name: '条码', value: data[val] } const obj = { name: '后工位光电信号', value: data[val] }
this.arr.push(obj)
} else if (val === 'qualified') {
const obj = { name: '合格数量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'unqualified') { } else if (val === 'action_1') {
const obj = { name: '不合格数量', value: data[val] } const obj = { name: '前工位动作信号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'put_station') { } else if (val === 'action_2') {
const obj = { name: '当前码盘工位', value: data[val] } const obj = { name: '后工位动作信号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'encoder_qty') { } else if (val === 'walk_y') {
const obj = { name: '码盘数量', value: data[val] } const obj = { name: '行走列', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'outKiln_move') { } else if (val === 'task1') {
const obj = { name: '出窑光电', value: data[val] } const obj = { name: '前工位任务号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'outKiln_barcode') { } else if (val === 'task2') {
const obj = { name: '出窑条码', value: data[val] } const obj = { name: '后工位任务号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'outKiln_device') { } else if (val === 'task') {
const obj = { name: '出窑设备', value: data[val] } const obj = { name: '任务号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'car_sum') { } else if (val === 'is_disable') {
const obj = { name: '窑车总数', value: data[val] } const obj = { name: '是否禁用', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'nullCar_qty') { } else if (val === 'temperature') {
const obj = { name: '空窑车数', value: data[val] } const obj = { name: '当前温度', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'burning_car_qty') { } else if (val === 'finish') {
const obj = { name: '在烧窑车数', value: data[val] } const obj = { name: '烘箱完成', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'container_qty') { } else if (val === 'countdown_house') {
const obj = { name: '托盘数', value: data[val] } const obj = { name: '恒温倒计时(时)', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'tray_crib_qty') { } else if (val === 'countdown_min') {
const obj = { name: '托盘垛数', value: data[val] } const obj = { name: '恒温倒计时(分)', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'total_container') { } else if (val === 'countdown_sec') {
const obj = { name: '托盘总数量', value: data[val] } const obj = { name: '恒温倒计时(秒)', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'total_split') { } else if (val === 'door') {
const obj = { name: '累计拆垛数量', value: data[val] } const obj = { name: '门状态', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'getStation') { } else if (val === 'notCreateTaskMessage') {
const obj = { name: '当前抓取工位', value: data[val] } const obj = { name: '任务创建失败原因', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'putStation') { } else if (val === 'notCreateInstMessage') {
const obj = { name: '当前码盘工位', value: data[val] } const obj = { name: '指令创建失败原因', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'move_1') { } else if (val === 'feedMessage') {
const obj = { name: '前工位光电信号', value: data[val] } const obj = { name: '未反馈电气信号原因', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'move_2') { } else if (val === 'requireSucess') {
const obj = { name: '后工位光电信号', value: data[val] } const obj = { name: '请求成功标记', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'action_1') { } else if (val === 'applySucess') {
const obj = { name: '前工位动作信号', value: data[val] } const obj = { name: 'applySucess', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'action_2') { } else if (val === 'out_finish') {
const obj = { name: '后工位动作信号', value: data[val] } const obj = { name: '出库完成', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'walk_y') { } else if (val === 'inventory_qty') {
const obj = { name: '行走列', value: data[val] } const obj = { name: '库存数量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'task1') { } else if (val === 'hand_barcode') {
const obj = { name: '前工位任务号', value: data[val] } const obj = { name: '手补条码', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'task2') { } else if (val === 'x') {
const obj = { name: '后工位任务号', value: data[val] } const obj = { name: 'X坐标', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'labeling_qty') { } else if (val === 'y') {
const obj = { name: '贴标数量', value: data[val] } const obj = { name: 'Y坐标', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'container_type') { } else if (val === 'angle') {
const obj = { name: '托盘类型', value: data[val] } const obj = { name: '角度', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'specifications') { } else if (val === 'electricity') {
const obj = { name: '规格', value: data[val] } const obj = { name: '电量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'onoff_status') { } else if (val === 'status_name') {
const obj = { name: '开关机状态', value: data[val] } const obj = { name: '状态', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'task_qty') { } else if (val === 'fault') {
const obj = { name: '当前任务数量', value: data[val] } const obj = { name: '异常', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'finishTask_qty') { } else if (val === 'map_id') {
const obj = { name: '完成任务数量', value: data[val] } const obj = { name: '楼层', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'AlongSide') { } else if (val === 'power') {
const obj = { name: 'A长边', value: data[val] } const obj = { name: '电量', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'BshortSide') { } else if (val === 'pallet') {
const obj = { name: 'B短边', value: data[val] } const obj = { name: '托盘', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'Htrapezoidal') { } else if (val === 'load') {
const obj = { name: 'H梯形高', value: data[val] } const obj = { name: '有无货', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'Wthickness') { } else if (val === 'alarm') {
const obj = { name: 'W厚度', value: data[val] } const obj = { name: '报警', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} else if (val === 'qty') { } else if (val === 'task_id') {
const obj = { name: '数量', value: data[val] } const obj = { name: '任务号', value: data[val] }
this.arr.push(obj) this.arr.push(obj)
} }
} }
@ -554,11 +654,16 @@ export default {
this.dialogFormVisible = false this.dialogFormVisible = false
this.dialogFormVisible3 = false this.dialogFormVisible3 = false
this.dialogFormVisible4 = false this.dialogFormVisible4 = false
this.dialogFormVisible5 = false
this.dialogFormVisible6 = false
this.dialogFormVisible7 = false
this.initStageData() this.initStageData()
}).catch(err => { }).catch(err => {
this.dialogFormVisible = false this.dialogFormVisible = false
this.dialogFormVisible3 = false this.dialogFormVisible3 = false
this.dialogFormVisible4 = false this.dialogFormVisible4 = false
this.dialogFormVisible5 = false
this.dialogFormVisible7 = false
console.log(err.response.data.message) console.log(err.response.data.message)
}) })
}, },
@ -591,12 +696,15 @@ body {
background-color: #f8f9fa; background-color: #f8f9fa;
height: 100%; height: 100%;
} }
.newDialog /deep/ .el-dialog__header { .newDialog /deep/ .el-dialog__header {
padding: 1vh 1vw 0 1vw; padding: 1vh 1vw 0 1vw;
} }
.newDialog /deep/ .el-dialog__body { .newDialog /deep/ .el-dialog__body {
padding: 1vh 1vw; padding: 1vh 1vw;
} }
.toolbar-sty { .toolbar-sty {
position: absolute; position: absolute;
margin-top: 5px; margin-top: 5px;

Loading…
Cancel
Save