增加带参路由多页签支持
Former-commit-id: cbc33a78c59c6468df3e905a1bc1f5c513abf804 [formerly cbc33a78c59c6468df3e905a1bc1f5c513abf804 [formerly cbc33a78c59c6468df3e905a1bc1f5c513abf804 [formerly cbc33a78c59c6468df3e905a1bc1f5c513abf804 [formerly 66e615a1681dbb8ff72633fc3d53cbf5411610f5 [formerly 449c1c2a13a19d6d52537b97c18548c012b360dd]]]]] Former-commit-id: 2a7a63bce617f5acaf5c1e4b13455f001f69118d Former-commit-id: 49a1453a0343e1e52cbb1b7faf1d18ffbb0ae519 Former-commit-id: d303a906c5a794ef68376044fb6d9c578e9e85c9 [formerly bc51b43eaa43b3d1744d7edc36d605a6d3d0cd2e] Former-commit-id: 8867f09a27c99223dfd2cb5e66b2b25ca75b49d9 Former-commit-id: 2f01e346f3474822a2ec1f50e02ffcce05dce8a8 Former-commit-id: 8f68a3470559ea51ee3ab7617347eb0236b607f1 Former-commit-id: dbcf55c5cfcb9f52dc8705397a2423f790d7ed82 Former-commit-id: 58abe040aadabc72c1db5acef2f45a7f30874614
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
:x="contentmenuX"
|
||||
:y="contentmenuY">
|
||||
<d2-contextmenu-list
|
||||
:menulist="tagName === 'index' ? contextmenuListIndex : contextmenuList"
|
||||
:menulist="tagName === '/index' ? contextmenuListIndex : contextmenuList"
|
||||
@rowClick="contextmenuClick"/>
|
||||
</d2-contextmenu>
|
||||
<el-tabs
|
||||
@@ -22,7 +22,7 @@
|
||||
v-for="(page, index) in opened"
|
||||
:key="index"
|
||||
:label="page.meta.title || '未命名'"
|
||||
:name="page.name"/>
|
||||
:name="page.fullPath"/>
|
||||
</el-tabs>
|
||||
</div>
|
||||
</div>
|
||||
@@ -79,7 +79,7 @@ export default {
|
||||
{ icon: 'times', title: '关闭其它', value: 'other' },
|
||||
{ icon: 'times-circle', title: '关闭全部', value: 'all' }
|
||||
],
|
||||
tagName: 'index'
|
||||
tagName: '/index'
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
@@ -163,7 +163,7 @@ export default {
|
||||
*/
|
||||
handleClick (tab, event) {
|
||||
// 找到点击的页面在 tag 列表里是哪个
|
||||
const page = this.opened.find(page => page.name === tab.name)
|
||||
const page = this.opened.find(page => page.fullPath === tab.name)
|
||||
const { name, params, query } = page
|
||||
if (page) {
|
||||
this.$router.push({ name, params, query })
|
||||
|
||||
Reference in New Issue
Block a user