Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
X
x-training-admin
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
x-training-admin
Commits
c069af20
提交
c069af20
authored
12月 29, 2020
作者:
lihuihui
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改bug
上级
5131b602
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
13 行增加
和
7 行删除
+13
-7
.config.dev.js
.config.dev.js
+1
-1
password.vue
src/pages/account/password.vue
+5
-3
axios.js
src/utils/axios.js
+7
-3
没有找到文件。
.config.dev.js
浏览文件 @
c069af20
...
@@ -35,6 +35,6 @@ module.exports = {
...
@@ -35,6 +35,6 @@ module.exports = {
},
},
others
:
{
others
:
{
loginUrl
:
'https://login2.ezijing.com/
xtraining/login/index
'
loginUrl
:
'https://login2.ezijing.com/'
}
}
}
}
src/pages/account/password.vue
浏览文件 @
c069af20
...
@@ -62,9 +62,11 @@ export default {
...
@@ -62,9 +62,11 @@ export default {
api
api
.
updatePassword
(
this
.
ruleForm
)
.
updatePassword
(
this
.
ruleForm
)
.
then
(
response
=>
{
.
then
(
response
=>
{
this
.
$message
({
message
:
'密码修改成功'
,
type
:
'success'
})
if
(
parseInt
(
response
.
code
)
===
0
)
{
// 重置表单
// 重置表单
this
.
$refs
.
ruleForm
.
resetFields
()
this
.
$message
({
message
:
'密码修改成功'
,
type
:
'success'
})
this
.
$refs
.
ruleForm
.
resetFields
()
}
})
})
.
finally
(()
=>
{
.
finally
(()
=>
{
this
.
submitLoading
=
false
this
.
submitLoading
=
false
...
...
src/utils/axios.js
浏览文件 @
c069af20
...
@@ -30,9 +30,13 @@ httpRequest.interceptors.response.use(
...
@@ -30,9 +30,13 @@ httpRequest.interceptors.response.use(
function
(
response
)
{
function
(
response
)
{
const
{
data
}
=
response
const
{
data
}
=
response
if
(
data
.
code
!==
0
&&
data
.
code
!==
-
1
)
{
if
(
data
.
code
!==
0
&&
data
.
code
!==
-
1
)
{
if
(
data
.
code
===
1
||
data
.
code
===
4001
)
{
if
(
data
.
msg
!==
'修改成功'
)
{
console
.
log
(
'重新登录'
)
return
Message
.
error
(
data
.
msg
)
window
.
location
.
href
=
`
${
webConf
.
others
.
loginUrl
}
?rd=
${
encodeURIComponent
(
window
.
location
.
href
)}
`
}
else
{
if
(
data
.
code
===
1
||
data
.
code
===
4001
)
{
console
.
log
(
'重新登录'
)
window
.
location
.
href
=
`
${
webConf
.
others
.
loginUrl
}
?rd=
${
encodeURIComponent
(
window
.
location
.
href
)}
`
}
}
}
if
(
data
.
message
)
{
if
(
data
.
message
)
{
Message
.
error
(
data
.
message
)
Message
.
error
(
data
.
message
)
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论