Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
confucius
Project
Project
Details
Activity
Releases
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
罗超
confucius
Commits
aef46923
Commit
aef46923
authored
Jul 02, 2021
by
Mac
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
2213deb5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
4 deletions
+31
-4
user.js
src/api/users/user.js
+12
-0
personalData.vue
src/pages/user/personalData.vue
+19
-4
No files found.
src/api/users/user.js
View file @
aef46923
...
@@ -99,3 +99,15 @@ export function getEmployeeAddrBook(data)
...
@@ -99,3 +99,15 @@ export function getEmployeeAddrBook(data)
data
data
})
})
}
}
/**
* 个人资料-修改密码
*/
export
function
updateUserPassword
(
data
)
{
return
request
({
url
:
'/UserInfo/UpdateUserPassword'
,
method
:
'post'
,
data
})
}
src/pages/user/personalData.vue
View file @
aef46923
...
@@ -137,6 +137,8 @@
...
@@ -137,6 +137,8 @@
<div
class=
"headportrait"
>
<div
class=
"headportrait"
>
<q-avatar
size=
"120px"
font-size=
"36px"
rounded
style=
"background:#C9F7F5"
text-color=
"white"
>
<q-avatar
size=
"120px"
font-size=
"36px"
rounded
style=
"background:#C9F7F5"
text-color=
"white"
>
<img
:src=
"datamodify.UserIcon"
v-if=
"datamodify.UserIcon"
>
<img
:src=
"datamodify.UserIcon"
v-if=
"datamodify.UserIcon"
>
<span
v-else
>
{{
showObj
.
AccountName
.
substring
(
0
,
1
)
}}
</span>
</q-avatar>
</q-avatar>
<el-upload
class=
"editbianji"
:http-request=
"uploadFileBtn"
:multiple=
"false"
action=
''
<el-upload
class=
"editbianji"
:http-request=
"uploadFileBtn"
:multiple=
"false"
action=
''
accept=
".JPG, .PNG, .JPEG,.jpg, .png, .jpeg"
:show-file-list=
"false"
>
accept=
".JPG, .PNG, .JPEG,.jpg, .png, .jpeg"
:show-file-list=
"false"
>
...
@@ -176,6 +178,7 @@
...
@@ -176,6 +178,7 @@
<div
class=
"box_r_input"
>
<div
class=
"box_r_input"
>
<q-input
v-model=
"passwordMsg.OldPassWord"
label=
"请输入旧密码"
type=
'password'
ref=
'OldPassWord'
<q-input
v-model=
"passwordMsg.OldPassWord"
label=
"请输入旧密码"
type=
'password'
ref=
'OldPassWord'
:rules=
"[val => !!val || '请输入旧密码']"
lazy-rules
filled
/>
:rules=
"[val => !!val || '请输入旧密码']"
lazy-rules
filled
/>
</div>
</div>
<div
class=
"box_r_title"
>
新密码
</div>
<div
class=
"box_r_title"
>
新密码
</div>
<div
class=
"box_r_input"
>
<div
class=
"box_r_input"
>
...
@@ -196,7 +199,8 @@
...
@@ -196,7 +199,8 @@
</template>
</template>
<
script
>
<
script
>
import
{
import
{
setEmployeeBaseInfo
setEmployeeBaseInfo
,
updateUserPassword
}
from
'../../api/users/user'
}
from
'../../api/users/user'
import
{
import
{
getSchoolDropdown
,
getSchoolDropdown
,
...
@@ -225,8 +229,6 @@
...
@@ -225,8 +229,6 @@
datamodify
:
{},
datamodify
:
{},
CompanyList
:
[],
CompanyList
:
[],
passwordMsg
:
Object
.
assign
({},
defaultpassword
),
passwordMsg
:
Object
.
assign
({},
defaultpassword
),
name
:
''
,
age
:
''
,
}
}
},
},
created
()
{
created
()
{
...
@@ -344,7 +346,20 @@
...
@@ -344,7 +346,20 @@
}
}
else
{
else
{
// 掉接口
// 掉接口
console
.
log
(
'掉接口'
)
updateUserPassword
(
this
.
passwordMsg
).
then
(
res
=>
{
if
(
res
.
Code
==
1
)
{
this
.
$q
.
notify
({
type
:
'iconfont icon-chenggong'
,
color
:
'accent'
,
position
:
"top"
,
message
:
res
.
Message
})
this
.
passwordMsg
=
Object
.
assign
({},
defaultpassword
)
}
}).
catch
(()
=>
{
})
}
}
},
},
...
...
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