Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-3
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
office
haoban-3
Commits
be39cd04
Commit
be39cd04
authored
May 18, 2022
by
caoyanzhi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: 退出跳转到gic的登录页
parent
aa327827
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
11 deletions
+11
-11
api.js
src/api/api.js
+3
-3
error.js
src/common/js/error.js
+1
-1
user-info.vue
src/components/layout/components/user-info.vue
+1
-1
index.js
src/router/index.js
+5
-5
gic-error.vue
src/views/errorPage/gic-error.vue
+1
-1
No files found.
src/api/api.js
View file @
be39cd04
...
@@ -65,7 +65,7 @@ Vue.axios.interceptors.response.use(
...
@@ -65,7 +65,7 @@ Vue.axios.interceptors.response.use(
if
(
window
.
location
.
href
.
indexOf
(
'gic-error'
)
!=
-
1
)
{
if
(
window
.
location
.
href
.
indexOf
(
'gic-error'
)
!=
-
1
)
{
return
false
;
return
false
;
}
}
window
.
location
.
href
=
local
+
'/
haoban-3/#/login
'
;
window
.
location
.
href
=
local
+
'/
gic-web/#/login?ishb=1
'
;
}
}
if
(
data
.
data
.
errorCode
==
10
||
data
.
data
.
errorCode
==
7
)
{
if
(
data
.
data
.
errorCode
==
10
||
data
.
data
.
errorCode
==
7
)
{
...
@@ -77,11 +77,11 @@ Vue.axios.interceptors.response.use(
...
@@ -77,11 +77,11 @@ Vue.axios.interceptors.response.use(
},
},
err
=>
{
err
=>
{
if
(
err
.
response
.
status
==
502
)
{
if
(
err
.
response
.
status
==
502
)
{
window
.
location
.
href
=
local
+
'/
haoban-3/#/login
'
;
window
.
location
.
href
=
local
+
'/
gic-web/#/login?ishb=1
'
;
Message
.
error
({
message
:
'服务异常⊙﹏⊙∥'
});
Message
.
error
({
message
:
'服务异常⊙﹏⊙∥'
});
}
}
if
(
err
.
response
.
status
!=
403
)
{
if
(
err
.
response
.
status
!=
403
)
{
window
.
location
.
href
=
local
+
'/
haoban-3/#/login
'
;
window
.
location
.
href
=
local
+
'/
gic-web/#/login?ishb=1
'
;
Message
.
error
({
message
:
'登录失效!'
});
Message
.
error
({
message
:
'登录失效!'
});
}
}
return
Promise
.
resolve
(
err
);
return
Promise
.
resolve
(
err
);
...
...
src/common/js/error.js
View file @
be39cd04
...
@@ -18,7 +18,7 @@ export default {
...
@@ -18,7 +18,7 @@ export default {
} */
} */
if
(
response
.
errorCode
!=
1
)
{
if
(
response
.
errorCode
!=
1
)
{
if
(
response
.
errorCode
==
4
)
{
if
(
response
.
errorCode
==
4
)
{
window
.
location
.
href
=
local
+
'/
haoban-3/#/login
'
;
window
.
location
.
href
=
local
+
'/
gic-web/#/login?ishb=1
'
;
return
false
;
return
false
;
}
}
if
(
response
.
errorCode
==
10
)
{
if
(
response
.
errorCode
==
10
)
{
...
...
src/components/layout/components/user-info.vue
View file @
be39cd04
...
@@ -58,7 +58,7 @@ export default {
...
@@ -58,7 +58,7 @@ export default {
return
;
return
;
}
}
this
.
$message
.
success
(
'退出成功'
);
this
.
$message
.
success
(
'退出成功'
);
this
.
$router
.
push
(
'/login'
)
;
window
.
location
.
href
=
location
.
origin
+
'/gic-web/#/login?ishb=1'
;
})
})
.
finally
(()
=>
this
.
$emit
(
'showLoading'
,
false
));
.
finally
(()
=>
this
.
$emit
(
'showLoading'
,
false
));
}
}
...
...
src/router/index.js
View file @
be39cd04
...
@@ -23,11 +23,11 @@ if (window.sessionStorage.getItem('token')) {
...
@@ -23,11 +23,11 @@ if (window.sessionStorage.getItem('token')) {
store
.
commit
(
types
.
LOGIN
,
window
.
sessionStorage
.
getItem
(
'token'
));
store
.
commit
(
types
.
LOGIN
,
window
.
sessionStorage
.
getItem
(
'token'
));
}
}
export
const
constantRouterMap
=
[
export
const
constantRouterMap
=
[
{
//
{
path
:
'/login'
,
//
path: '/login',
name
:
'登录'
,
//
name: '登录',
component
:
_import
(
'login'
,
'index'
)
//
component: _import('login', 'index')
},
//
},
{
{
path
:
'/loginMore'
,
path
:
'/loginMore'
,
name
:
'登录'
,
name
:
'登录'
,
...
...
src/views/errorPage/gic-error.vue
View file @
be39cd04
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
<div
class=
"bullshit"
>
<div
class=
"bullshit"
>
<!--
<div
class=
"bullshit__oops"
>
404
</div>
-->
<!--
<div
class=
"bullshit__oops"
>
404
</div>
-->
<div
class=
"bullshit__headline"
>
{{
message
}}
</div>
<div
class=
"bullshit__headline"
>
{{
message
}}
</div>
<a
href=
"
#/login
"
class=
"bullshit__return-home"
rel=
"noopener noreferrer"
>
返回好办登录页
</a>
<a
href=
"
/gic-web/#/login?ishb=1
"
class=
"bullshit__return-home"
rel=
"noopener noreferrer"
>
返回好办登录页
</a>
</div>
</div>
</div>
</div>
</div>
</div>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment