From f3798aa2c951e6cb2f9a5e1c1ee4332a150cd021 Mon Sep 17 00:00:00 2001
From: zyy <1787816799@qq.com>
Date: Tue, 19 Nov 2019 17:48:32 +0800
Subject: [PATCH] =?UTF-8?q?desc:=20=E5=A2=9E=E5=8A=A0=E5=B1=8F=E8=94=BD?=
=?UTF-8?q?=E9=97=A8list?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../dataRelation/parkOperate/index.vue | 126 +++++++++++++++++-
.../dataRelation/safetyDoorOperate/index.vue | 9 +-
src/views/system/commandDictionary/edit.vue | 4 +-
src/views/system/commandDictionary/index.vue | 16 +--
4 files changed, 138 insertions(+), 17 deletions(-)
diff --git a/src/views/mapdraft/dataRelation/parkOperate/index.vue b/src/views/mapdraft/dataRelation/parkOperate/index.vue
index 9cb48cc88..f61a2906d 100644
--- a/src/views/mapdraft/dataRelation/parkOperate/index.vue
+++ b/src/views/mapdraft/dataRelation/parkOperate/index.vue
@@ -1,13 +1,56 @@
- 22222
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 暂无数据
+
+
+
+
+ 批量创建
+ 修改
+
+
diff --git a/src/views/mapdraft/dataRelation/safetyDoorOperate/index.vue b/src/views/mapdraft/dataRelation/safetyDoorOperate/index.vue
index 55508a711..2a6268983 100644
--- a/src/views/mapdraft/dataRelation/safetyDoorOperate/index.vue
+++ b/src/views/mapdraft/dataRelation/safetyDoorOperate/index.vue
@@ -3,8 +3,8 @@
-
-
+
+
-
+
@@ -110,7 +110,7 @@ export default {
this.deviceSelect(this.$store.getters['map/getDeviceByCode'](code));
},
deviceSelect(selected) {
- this.$refs.form.resetFields();
+ this.$refs.ruleForm && this.$refs.ruleForm.resetFields();
if (selected && selected._type.toUpperCase() === 'PSD'.toUpperCase()) { // ESP
this.editModel = deepAssign(this.editModel, selected);
}
@@ -144,6 +144,7 @@ export default {
this.display = false;
this.$message('创建完成');
this.$store.dispatch('map/updateMapStandData', {models: arr, type: 'safetyDoorList'});
+ this.deviceSelect();
} else {
this.$message('暂无车站');
}
diff --git a/src/views/system/commandDictionary/edit.vue b/src/views/system/commandDictionary/edit.vue
index ff7b23146..0af9cd2e8 100644
--- a/src/views/system/commandDictionary/edit.vue
+++ b/src/views/system/commandDictionary/edit.vue
@@ -71,7 +71,7 @@ export default {
formModel: {
id: '',
simulationRole: '',
- controlMode: '',
+ controlMode: [],
lineCode: '',
operateObject: '',
operate: '',
@@ -87,7 +87,7 @@ export default {
items: [
{ prop: 'lineCode', label: this.$t('system.lineCode'), type: 'select', options: this.taskStatusList },
{ prop: 'simulationRole', label: this.$t('system.simulationRole'), type: 'select', options: this.$ConstSelect.simulationRole },
- { prop: 'controlMode', label: this.$t('system.controlMode'), type: 'select', options: this.$ConstSelect.controlMode },
+ { prop: 'controlMode', label: this.$t('system.controlMode'), type: 'select', options: this.$ConstSelect.controlMode, multiple: true },
{ prop: 'operateObject', label: this.$t('system.deviceType'), type: 'select', options: this.$ConstSelect.deviceTypeList, change: true, onChange: this.deviceChange },
{ prop: 'operate', label: this.$t('system.instructionType'), type: 'select', options: this.operateList }
]
diff --git a/src/views/system/commandDictionary/index.vue b/src/views/system/commandDictionary/index.vue
index bf7e251ea..8e13119ab 100644
--- a/src/views/system/commandDictionary/index.vue
+++ b/src/views/system/commandDictionary/index.vue
@@ -56,13 +56,6 @@ export default {
columnValue: (row) => { return this.$convertField(row.lineCode, this.taskStatusList, ['code', 'name']); },
tagType: (row) => { return 'success'; }
},
- {
- title: this.$t('system.controlMode'), // 控制模式
- prop: 'controlMode',
- type: 'tag',
- columnValue: (row) => { return this.$convertField(row.controlMode, this.$ConstSelect.controlMode, ['value', 'label']); },
- tagType: (row) => { return 'success'; }
- },
{
title: this.$t('system.simulationRole'), // 仿真角色
prop: 'simulationRole',
@@ -70,6 +63,13 @@ export default {
columnValue: (row) => { return this.$convertField(row.simulationRole, this.$ConstSelect.simulationRole, ['value', 'label']); },
tagType: (row) => { return 'success'; }
},
+ {
+ title: this.$t('system.controlMode'), // 控制模式
+ prop: 'controlMode',
+ type: 'tagMore',
+ columnValue: (row) => { return this.$convertField(row.controlMode, this.$ConstSelect.controlMode, ['value', 'label'], true); },
+ tagType: (row) => { return 'success'; }
+ },
{
title: this.$t('system.deviceType'), // 操作对象
prop: 'operateObject',
@@ -149,7 +149,7 @@ export default {
return getCommandList(params);
},
convertField(fieldValue, operateObject, converFormat) {
- if (Commands) {
+ if (Commands && Commands[operateObject]) {
const enumList = Object.values(Commands[operateObject]);
if (enumList && converFormat && converFormat.length >= 2) {
const value = converFormat[0];