|
@@ -115,6 +115,7 @@ export default {
|
|
|
ratio: null,
|
|
ratio: null,
|
|
|
productSelectSchema,
|
|
productSelectSchema,
|
|
|
schema: {
|
|
schema: {
|
|
|
|
|
+ keepalive: true,
|
|
|
condition: { productId: void 0, name: '', tenant: this.group.path },
|
|
condition: { productId: void 0, name: '', tenant: this.group.path },
|
|
|
list: getDevicesByAdmin,
|
|
list: getDevicesByAdmin,
|
|
|
transform: this.transform,
|
|
transform: this.transform,
|
|
@@ -139,6 +140,7 @@ export default {
|
|
|
return data.empty ? h('span', { staticClass: 'u-color--info' }, '暂无备份设备') : data.name
|
|
return data.empty ? h('span', { staticClass: 'u-color--info' }, '暂无备份设备') : data.name
|
|
|
} },
|
|
} },
|
|
|
{ prop: 'productName', label: '产品' },
|
|
{ prop: 'productName', label: '产品' },
|
|
|
|
|
+ { prop: 'address', label: '地址', 'min-width': 100 },
|
|
|
{ type: 'tag', 'width': 100, render ({ empty, activate, onlineStatus }) {
|
|
{ type: 'tag', 'width': 100, render ({ empty, activate, onlineStatus }) {
|
|
|
return empty
|
|
return empty
|
|
|
? null
|
|
? null
|
|
@@ -161,7 +163,7 @@ export default {
|
|
|
}, on: this.onTagClick },
|
|
}, on: this.onTagClick },
|
|
|
{ type: 'invoke', width: 240, render: [
|
|
{ type: 'invoke', width: 240, render: [
|
|
|
{ label: '查看', render ({ empty }) { return !empty }, on: this.onViewDevice },
|
|
{ label: '查看', render ({ empty }) { return !empty }, on: this.onViewDevice },
|
|
|
- { label: '配置', render ({ isMaster }) { return isMaster }, on: this.onConfig },
|
|
|
|
|
|
|
+ { label: '配置', render ({ isMaster }) { return isMaster }, on: this.onSettingDevice },
|
|
|
{ label: '添加备份', render ({ isMaster }) { return isMaster }, on: this.onAddSubDevice },
|
|
{ label: '添加备份', render ({ isMaster }) { return isMaster }, on: this.onAddSubDevice },
|
|
|
{ label: '删除', render ({ empty }) { return !empty }, on: this.onDelDevice }
|
|
{ label: '删除', render ({ empty }) { return !empty }, on: this.onDelDevice }
|
|
|
] }
|
|
] }
|
|
@@ -297,7 +299,7 @@ export default {
|
|
|
},
|
|
},
|
|
|
onViewDevice (item) {
|
|
onViewDevice (item) {
|
|
|
this.$router.push({
|
|
this.$router.push({
|
|
|
- name: 'device-detail',
|
|
|
|
|
|
|
+ name: 'device-management-detail',
|
|
|
params: {
|
|
params: {
|
|
|
id: item.id
|
|
id: item.id
|
|
|
}
|
|
}
|
|
@@ -367,9 +369,9 @@ export default {
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
- onConfig ({ id }) {
|
|
|
|
|
|
|
+ onSettingDevice ({ id }) {
|
|
|
this.$router.push({
|
|
this.$router.push({
|
|
|
- name: 'device-config',
|
|
|
|
|
|
|
+ name: 'device-management-settings',
|
|
|
params: { id }
|
|
params: { id }
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|