module-menu-vue 0.0.83 → 0.0.85
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -103,8 +103,8 @@ export default {
|
|
|
103
103
|
});
|
|
104
104
|
},
|
|
105
105
|
toHref () {
|
|
106
|
-
if (this.sysName === 'admin'
|
|
107
|
-
location.href = `/#${this.systemPath}`
|
|
106
|
+
if (this.sysName === 'admin') {
|
|
107
|
+
location.href = this.stash === "GZW" ? `/data-platform/#${this.systemPath}` : this.stash !== "integration" ? `/#${this.systemPath}` : ''
|
|
108
108
|
}
|
|
109
109
|
},
|
|
110
110
|
async getSessionMenu () {
|
|
@@ -228,7 +228,7 @@ export default {
|
|
|
228
228
|
// 跳转首页
|
|
229
229
|
toHomePage (index) {
|
|
230
230
|
if (index === 0) {
|
|
231
|
-
location.href = this.stash === "integration" ? '/dataadmin/#/index' : '/#/index'
|
|
231
|
+
location.href = this.stash === "integration" ? '/dataadmin/#/index' : this.stash === "GZW" ? '/data-platform/#/index' : '/#/index'
|
|
232
232
|
}
|
|
233
233
|
},
|
|
234
234
|
getNewMenuList () {
|
|
@@ -66,6 +66,7 @@ export default {
|
|
|
66
66
|
if (this.stash === 'integration') {
|
|
67
67
|
this.isShowAppFunc()
|
|
68
68
|
}
|
|
69
|
+
localStorage.setItem('stash', 'GZW')
|
|
69
70
|
},
|
|
70
71
|
methods: {
|
|
71
72
|
async isShowAppFunc() {
|
|
@@ -85,7 +86,7 @@ export default {
|
|
|
85
86
|
handleClickmenu (flag){
|
|
86
87
|
let url = ''
|
|
87
88
|
if (flag === 'single') {
|
|
88
|
-
url = this.stash === "integration" ? '/admin-ui/data-share-portal/personal/info' : '/#/info/index'
|
|
89
|
+
url = this.stash === "integration" ? '/admin-ui/data-share-portal/personal/info' : this.stash === "GZW" ? '/data-platform/#/info/index' : '/#/info/index'
|
|
89
90
|
location.href = url;
|
|
90
91
|
} else if (flag === 'systerm') {
|
|
91
92
|
if (this.stash === "integration") {
|
|
@@ -108,7 +109,7 @@ export default {
|
|
|
108
109
|
}
|
|
109
110
|
})
|
|
110
111
|
}
|
|
111
|
-
location.href = `/#${systemPath}`
|
|
112
|
+
location.href = this.stash === "GZW" ? `/data-platform/#${systemPath}` : `/#${systemPath}`
|
|
112
113
|
}
|
|
113
114
|
} else if (flag === 'app') {
|
|
114
115
|
url = '/dataadmin/#/appSystem/index'
|
|
@@ -123,7 +124,7 @@ export default {
|
|
|
123
124
|
await integrationLogout();
|
|
124
125
|
this.logoutUrl()
|
|
125
126
|
} else {
|
|
126
|
-
const url = this.stash === 'integration' ? '/admin-api/system/auth/logout' : '/auth/token/logout'
|
|
127
|
+
const url = this.stash === 'integration' ? '/admin-api/system/auth/logout' : this.stash === 'GZW' ? '/data-platform/auth/token/logout' : '/auth/token/logout'
|
|
127
128
|
const method = this.stash === 'integration'? 'post' : 'delete'
|
|
128
129
|
Axios(url, method).then(() => {
|
|
129
130
|
this.logoutUrl();
|
|
@@ -136,7 +137,7 @@ export default {
|
|
|
136
137
|
logoutUrl() {
|
|
137
138
|
localStorage.clear();
|
|
138
139
|
sessionStorage.clear();
|
|
139
|
-
location.href = this.stash === 'integration' ? '/admin-ui/login' : '/#/login'
|
|
140
|
+
location.href = this.stash === 'integration' ? '/admin-ui/login' : this.stash === 'GZW' ? '/data-platform/#/login' : '/#/login'
|
|
140
141
|
},
|
|
141
142
|
getName () {
|
|
142
143
|
return getUserName()
|
|
@@ -6,13 +6,6 @@ export const integrationLogout = () => {
|
|
|
6
6
|
})
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
// 轻量级退出登录
|
|
10
|
-
export async function compactLogout() {
|
|
11
|
-
return request({
|
|
12
|
-
url: '/auth/token/logout',
|
|
13
|
-
method: 'delete'
|
|
14
|
-
})
|
|
15
|
-
}
|
|
16
9
|
// 获取到要跳转的系统管理路径
|
|
17
10
|
export const getSysUrl = () => {
|
|
18
11
|
return request('/admin-api/system/auth/homePage', {
|
|
@@ -12,7 +12,9 @@ export const checkToken = async (token) => {
|
|
|
12
12
|
location.href = DEFAULT_LOGOUT_URL;
|
|
13
13
|
}});
|
|
14
14
|
} else {
|
|
15
|
-
|
|
15
|
+
const flag = localStorage.getItem('stash')
|
|
16
|
+
const url = flag === 'GZW' ? `/data-platform/auth/oauth/check_token?token=${token}` : `/auth/oauth/check_token?token=${token}`
|
|
17
|
+
Axios('get', url, '', {})
|
|
16
18
|
.then().catch(() =>{
|
|
17
19
|
this.$message.error({content:'用户凭证已过期,请重新登录', onClose: ()=>{
|
|
18
20
|
localStorage.clear();
|