mirror of
https://github.com/jumpserver/lina.git
synced 2026-01-15 14:24:39 +00:00
Merge pull request #4108 from jumpserver/pr@dev@fix_plateform_tab
fixed: Fixed an issue where the correct tab could not be located after creating the platform
This commit is contained in:
@@ -198,10 +198,12 @@ export default {
|
||||
type: Function,
|
||||
default(res, method, vm, addContinue) {
|
||||
const route = this.getNextRoute(res, method)
|
||||
|
||||
if (!(route.params && route.params.id)) {
|
||||
route['params'] = deepmerge(route['params'] || {}, { 'id': res.id })
|
||||
}
|
||||
route['query'] = deepmerge(route['query'], { 'order': this.extraQueryOrder, 'updated': new Date().getTime() })
|
||||
|
||||
this.$emit('submitSuccess', res)
|
||||
|
||||
this.emitPerformSuccessMsg(method, res, addContinue)
|
||||
|
||||
@@ -125,7 +125,8 @@ export default {
|
||||
},
|
||||
dropdown: []
|
||||
}
|
||||
}
|
||||
},
|
||||
lastTab: ''
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -133,10 +134,14 @@ export default {
|
||||
return `/api/v1/assets/platforms/?category=${this.tab.activeMenu}`
|
||||
}
|
||||
},
|
||||
deactivated() {
|
||||
window.localStorage.setItem('lastTab', this.tab.activeMenu)
|
||||
},
|
||||
activated() {
|
||||
setTimeout(() => {
|
||||
this.tab.activeMenu = window.localStorage.getItem('lastTab')
|
||||
this.$refs.genericListTable.reloadTable()
|
||||
}, 500)
|
||||
}, 300)
|
||||
},
|
||||
async mounted() {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user