From de5ae4a05efc19bb5d476ddc51e6a5a3d6b782be Mon Sep 17 00:00:00 2001 From: RuoYi Date: Fri, 8 Apr 2022 15:42:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=A1=B5=E7=AD=BEopenPage?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E4=BC=A0=E9=80=92=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/plugins/tab.js | 4 ++-- ruoyi-ui/src/views/tool/gen/index.vue | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ruoyi-ui/src/plugins/tab.js b/ruoyi-ui/src/plugins/tab.js index c8058a9..5e8b834 100644 --- a/ruoyi-ui/src/plugins/tab.js +++ b/ruoyi-ui/src/plugins/tab.js @@ -55,10 +55,10 @@ export default { return store.dispatch('tagsView/delOthersViews', obj || router.currentRoute); }, // 添加tab页签 - openPage(title, url) { + openPage(title, url, params) { var obj = { path: url, meta: { title: title } } store.dispatch('tagsView/addView', obj); - return router.push(url); + return router.push({ path: url, query: params }); }, // 修改tab页签 updatePage(obj) { diff --git a/ruoyi-ui/src/views/tool/gen/index.vue b/ruoyi-ui/src/views/tool/gen/index.vue index 4b44b86..381e30f 100644 --- a/ruoyi-ui/src/views/tool/gen/index.vue +++ b/ruoyi-ui/src/views/tool/gen/index.vue @@ -318,7 +318,9 @@ export default { /** 修改按钮操作 */ handleEditTable(row) { const tableId = row.tableId || this.ids[0]; - this.$router.push({ path: '/tool/gen-edit/index/' + tableId, query: { pageNum: this.queryParams.pageNum } }); + const tableName = row.tableName || this.tableNames[0]; + const params = { pageNum: this.queryParams.pageNum }; + this.$tab.openPage("修改[" + tableName + "]生成配置", '/tool/gen-edit/index/' + tableId, params); }, /** 删除按钮操作 */ handleDelete(row) {