feat: 增加 snmp => credential , mib file
This commit is contained in:
@@ -5,7 +5,7 @@ import routerPathParams from '@/components/common/mixin/routerPathParams'
|
||||
export default {
|
||||
mixins: [routerPathParams],
|
||||
props: {
|
||||
showTab: {
|
||||
switchTab: {
|
||||
type: String,
|
||||
default: ''
|
||||
}
|
||||
@@ -87,17 +87,15 @@ export default {
|
||||
this.$set(this.searchLabel, 'pageNo', this.pageObj.pageNo)
|
||||
this.$set(this.searchLabel, 'pageSize', this.pageObj.pageSize)
|
||||
this.tools.loading = true
|
||||
if (this.$route.fullPath.match(/\/(\S*)\?/)[1] !== 'snmp') {
|
||||
const dataListParam = {
|
||||
...this.searchLabel,
|
||||
...this.searchCheckBox
|
||||
}
|
||||
if (this.showTab) {
|
||||
dataListParam.showTab = this.showTab
|
||||
}
|
||||
const path = this.$route.fullPath.match(/\/(\S*)\?/)[1]
|
||||
this.updatePath(dataListParam, path)
|
||||
const dataListParam = {
|
||||
...this.searchLabel,
|
||||
...this.searchCheckBox
|
||||
}
|
||||
if (this.switchTab) {
|
||||
dataListParam.switchTab = this.switchTab
|
||||
}
|
||||
const path = this.$route.fullPath.match(/\/(\S*)\?/)[1]
|
||||
this.updatePath(dataListParam, path)
|
||||
this.$get(this.url, { ...this.searchLabel, ...this.searchCheckBox }).then(response => {
|
||||
this.tools.loading = false
|
||||
if (response.code === 200) {
|
||||
@@ -669,7 +667,7 @@ export default {
|
||||
jsonKey: 'val'
|
||||
}
|
||||
}
|
||||
} else if (path === 'template' && this.$route.query.showTab) {
|
||||
} else if (path === 'template' && this.switchTab) {
|
||||
searchKeys = {
|
||||
// key: path 键
|
||||
// value: vue set 参数
|
||||
@@ -717,6 +715,90 @@ export default {
|
||||
jsonKey: 'val'
|
||||
}
|
||||
}
|
||||
} else if (path === 'snmp' && this.switchTab == 'credentials') {
|
||||
searchKeys = {
|
||||
// key: path 键
|
||||
// value: vue set 参数
|
||||
pageNo: { target: this.pageObj, propertyName: 'pageNo', type: 'number' },
|
||||
pageSize: { target: this.pageObj, propertyName: 'pageSize', type: 'number' },
|
||||
orderBy: { target: this.$data, propertyName: 'orderBy', type: 'string' },
|
||||
ids: {
|
||||
target: this.searchLabel,
|
||||
propertyName: 'ids',
|
||||
type: 'string',
|
||||
defaultJson: {
|
||||
disabled: false,
|
||||
label: 'ids',
|
||||
name: 'ID',
|
||||
type: 'input',
|
||||
val: ''
|
||||
},
|
||||
jsonKey: 'val'
|
||||
},
|
||||
name: {
|
||||
target: this.searchLabel,
|
||||
propertyName: 'name',
|
||||
type: 'string',
|
||||
defaultJson: {
|
||||
disabled: false,
|
||||
id: 'name',
|
||||
label: 'name',
|
||||
name: 'Name',
|
||||
type: 'input',
|
||||
val: ''
|
||||
},
|
||||
jsonKey: 'val'
|
||||
},
|
||||
type: {
|
||||
target: this.searchLabel,
|
||||
propertyName: 'type',
|
||||
type: 'string',
|
||||
defaultJson: {
|
||||
disabled: false,
|
||||
label: 'credentialType',
|
||||
name: 'Type',
|
||||
readonly: true,
|
||||
type: 'select',
|
||||
val: ''
|
||||
},
|
||||
jsonKey: 'val'
|
||||
}
|
||||
}
|
||||
} else if (path === 'snmp' && this.switchTab == 'file') {
|
||||
searchKeys = {
|
||||
// key: path 键
|
||||
// value: vue set 参数
|
||||
pageNo: { target: this.pageObj, propertyName: 'pageNo', type: 'number' },
|
||||
pageSize: { target: this.pageObj, propertyName: 'pageSize', type: 'number' },
|
||||
orderBy: { target: this.$data, propertyName: 'orderBy', type: 'string' },
|
||||
ids: {
|
||||
target: this.searchLabel,
|
||||
propertyName: 'ids',
|
||||
type: 'string',
|
||||
defaultJson: {
|
||||
disabled: false,
|
||||
label: 'ids',
|
||||
name: 'ID',
|
||||
type: 'input',
|
||||
val: ''
|
||||
},
|
||||
jsonKey: 'val'
|
||||
},
|
||||
name: {
|
||||
target: this.searchLabel,
|
||||
propertyName: 'name',
|
||||
type: 'string',
|
||||
defaultJson: {
|
||||
disabled: false,
|
||||
id: 'name',
|
||||
label: 'name',
|
||||
name: 'Name',
|
||||
type: 'input',
|
||||
val: ''
|
||||
},
|
||||
jsonKey: 'val'
|
||||
}
|
||||
}
|
||||
}
|
||||
this.initQueryFromPath(searchKeys)
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user