Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
L
learn-online-pc
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
EzijingWeb
learn-online-pc
Commits
993460c6
提交
993460c6
authored
4月 10, 2020
作者:
lihuihui
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
修改密码更换头像
上级
974691aa
隐藏空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
32 行增加
和
2 行删除
+32
-2
OtherAction.js
client/src/action/OtherAction.js
+4
-0
index.js
client/src/action/index.js
+1
-0
other_api.js
client/src/api/other_api.js
+8
-0
setPwd.vue
client/src/pages/other/setPwd.vue
+3
-2
package-lock.json
package-lock.json
+16
-0
没有找到文件。
client/src/action/OtherAction.js
浏览文件 @
993460c6
...
...
@@ -22,4 +22,8 @@ export default class OtherAction extends BaseACTION {
* 文件上传
*/
uploadFile
(
obj
)
{
return
Other
.
uploadFile
(
obj
).
then
(
res
=>
res
)
}
/**
* 调用个人信心 - 修改密码
*/
updatePwd
(
obj
)
{
return
Other
.
updatePwd
(
obj
).
then
(
res
=>
res
)
}
}
client/src/action/index.js
浏览文件 @
993460c6
...
...
@@ -38,6 +38,7 @@ const cAction = {
* @param {[function]} obj.finallyCallback 最终finally回调,必传
*/
export
const
request
=
(
obj
)
=>
{
console
.
log
(
obj
,
'==========='
)
cAction
[
obj
.
actionName
][
obj
.
functionName
](
obj
.
data
).
then
(
res
=>
{
obj
.
thenCallback
(
res
)
}).
catch
(
e
=>
{
...
...
client/src/api/other_api.js
浏览文件 @
993460c6
import
BaseAPI
from
'./base_api'
import
_
from
'lodash'
export
default
class
OtherAPI
extends
BaseAPI
{
/**
...
...
@@ -10,4 +11,11 @@ export default class OtherAPI extends BaseAPI {
* @param {[object]} obj
*/
uploadFile
=
(
obj
=
{})
=>
this
.
post
(
'/util/upload-file'
,
obj
,
{
headers
:
{
'Content-Type'
:
'multipart/form-data'
}
})
/**
* 个人信息 - 修改密码
* @param {[string]} obj.old_password 验证码
* @param {[string]} obj.new_password 新的密码
* @param {[string]} obj.service 这里 一直是定值 h5.ezijing.com
*/
updatePwd
=
(
obj
=
{})
=>
this
.
post
(
'/user_center/change_password'
,
_
.
assignIn
(
obj
,
{
service
:
'h5.ezijing.com'
}),
{
headers
:
{
'Content-Type'
:
'application/x-www-form-urlencoded'
}
})
}
client/src/pages/other/setPwd.vue
浏览文件 @
993460c6
...
...
@@ -27,6 +27,7 @@
<
script
>
import
{
request
}
from
'@action'
import
md5
from
'js-md5'
export
default
{
components
:
{
},
...
...
@@ -65,10 +66,10 @@ export default {
if
(
valid
)
{
request
({
component
:
this
,
actionName
:
'
loginAction
'
,
actionName
:
'
Other
'
,
functionName
:
'updatePwd'
,
data
:
{
old_password
:
M
d5
(
'uokoaduw'
+
this
.
accountSetPwd
.
oldPwd
.
split
(
''
).
reverse
().
join
(
''
)
+
'auhgniq'
),
old_password
:
m
d5
(
'uokoaduw'
+
this
.
accountSetPwd
.
oldPwd
.
split
(
''
).
reverse
().
join
(
''
)
+
'auhgniq'
),
new_password
:
this
.
accountSetPwd
.
newPwdAgain
},
thenCallback
:
data
=>
{
...
...
package-lock.json
0 → 100644
浏览文件 @
993460c6
{
"requires"
:
true
,
"lockfileVersion"
:
1
,
"dependencies"
:
{
"js-cookie"
:
{
"version"
:
"2.2.1"
,
"resolved"
:
"https://registry.npmjs.org/js-cookie/-/js-cookie-2.2.1.tgz"
,
"integrity"
:
"sha512-HvdH2LzI/EAZcUwA8+0nKNtWHqS+ZmijLA30RwZA0bo7ToCckjK5MkGhjED9KoRcXO6BaGI3I9UIzSA1FKFPOQ=="
},
"js-md5"
:
{
"version"
:
"0.7.3"
,
"resolved"
:
"https://registry.npmjs.org/js-md5/-/js-md5-0.7.3.tgz"
,
"integrity"
:
"sha512-ZC41vPSTLKGwIRjqDh8DfXoCrdQIyBgspJVPXHBGu4nZlAEvG3nf+jO9avM9RmLiGakg7vz974ms99nEV0tmTQ=="
}
}
}
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论