Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cust-app
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
李伟
cust-app
Commits
db23adb9
Commit
db23adb9
authored
Jan 16, 2025
by
罗林杰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改图片上传
parent
5769fee8
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
8 deletions
+18
-8
educationcertification.vue
pagesme/me/educationcertification.vue
+5
-2
updateInformation.vue
pagesme/me/updateInformation.vue
+13
-6
No files found.
pagesme/me/educationcertification.vue
View file @
db23adb9
...
...
@@ -25,6 +25,7 @@
<
script
>
import
ELM
from
'@/components/elm-toast/index.vue'
;
import
{
updateUser
,
userDetail
}
from
"../../api/user"
;
import
{
getOssUrl
}
from
"../../api/article"
;
export
default
{
data
()
{
return
{
...
...
@@ -54,8 +55,10 @@
loadPage
()
{
userDetail
(
uni
.
getStorageSync
(
'userInfo'
).
memberId
).
then
(
res
=>
{
//处理图片
if
(
res
.
data
.
data
.
educationPictureUrl
!==
null
&&
res
.
data
.
data
.
educationPictureUrl
!==
''
){
this
.
educationPictureUrl
=
(
res
.
data
.
data
.
educationPictureUrl
.
replace
(
/
\\
/g
,
'/'
))
if
(
res
.
data
.
data
.
memEducationPictureId
!==
null
&&
res
.
data
.
data
.
memEducationPictureId
!==
''
){
getOssUrl
(
res
.
data
.
data
.
memEducationPictureId
).
then
(
imgRes
=>
{
this
.
educationPictureUrl
=
imgRes
.
data
.
data
})
}
})
},
...
...
pagesme/me/updateInformation.vue
View file @
db23adb9
...
...
@@ -237,6 +237,7 @@
import
{
updateUser
,
userDetail
}
from
"../../api/user"
;
import
{
calculateAge
,
parseDate
}
from
"../../common"
;
import
{
getCity
,
getValue
}
from
"../../common/options"
;
import
{
getOssUrl
}
from
"../../api/article"
;
export
default
{
data
()
{
...
...
@@ -422,15 +423,21 @@ import {updateUser, userDetail} from "../../api/user";
userDetail
(
uni
.
getStorageSync
(
'userInfo'
).
memberId
).
then
(
res
=>
{
this
.
userInfo
=
res
.
data
.
data
//处理头像
if
(
this
.
judgment
(
res
.
data
.
data
.
avatarUrl
)){
this
.
userInfo
.
avatarUrl
=
(
res
.
data
.
data
.
avatarUrl
.
replace
(
/
\\
/g
,
'/'
))
if
(
this
.
judgment
(
res
.
data
.
data
.
avatar
)){
getOssUrl
(
res
.
data
.
data
.
avatar
).
then
(
imgRes
=>
{
this
.
userInfo
.
avatarUrl
=
imgRes
.
data
.
data
})
}
//处理信息图片
if
(
this
.
judgment
(
res
.
data
.
data
.
pictureUrls
)){
this
.
userInfo
.
pictureUrls
=
res
.
data
.
data
.
pictureUrls
.
split
(
','
)
this
.
userInfo
.
pictureUrls
.
forEach
((
item
,
index
)
=>
{
this
.
userInfo
.
pictureUrls
[
index
]
=
(
item
.
replace
(
/
\\
/g
,
'/'
))
if
(
this
.
judgment
(
res
.
data
.
data
.
memPictureId
)){
const
urlArray
=
JSON
.
parse
(
res
.
data
.
data
.
memPictureId
)
let
url
=
[]
urlArray
.
id
.
forEach
(
item
=>
{
getOssUrl
(
item
).
then
(
imgRes
=>
{
url
.
push
(
imgRes
.
data
.
data
)
})
})
this
.
userInfo
.
pictureUrls
=
url
}
//处理学历
if
(
this
.
judgment
(
res
.
data
.
data
.
memMaxEducation
)){
...
...
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