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
62683b57
Commit
62683b57
authored
Jan 25, 2025
by
罗林杰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改留言
parent
4e469be4
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
133 additions
and
5 deletions
+133
-5
index.js
api/user/index.js
+10
-0
pages.json
pages.json
+10
-0
addMessage.vue
pagesUser/addMessage.vue
+103
-0
userInfo.vue
pagesUser/userInfo.vue
+6
-1
updateInformation.vue
pagesme/me/updateInformation.vue
+4
-4
No files found.
api/user/index.js
View file @
62683b57
...
@@ -87,4 +87,14 @@ export function rankList(data){
...
@@ -87,4 +87,14 @@ export function rankList(data){
url
:
'/app/open/memInfo/rank'
,
url
:
'/app/open/memInfo/rank'
,
data
data
});
});
}
/**
* 留言
*/
export
function
addMessage
(
data
){
return
request
({
url
:
'/app/memInfo/leaveMessage'
,
data
:
data
,
method
:
'POST'
,
});
}
}
\ No newline at end of file
pages.json
View file @
62683b57
...
@@ -89,6 +89,16 @@
...
@@ -89,6 +89,16 @@
"navigationStyle"
:
"custom"
"navigationStyle"
:
"custom"
}
}
},
},
{
"path"
:
"addMessage"
,
"style"
:
{
"navigationBarTitleText"
:
""
,
"backgroundColorTop"
:
"#F4F5F9"
,
"backgroundColorBottom"
:
"#F4F5F9"
,
"navigationBarBackgroundColor"
:
"#F4F5F9"
,
"backgroundColor"
:
"#F4F5F9"
}
},
{
{
"path"
:
"userArticleList"
,
"path"
:
"userArticleList"
,
"style"
:
{
"style"
:
{
...
...
pagesUser/addMessage.vue
0 → 100644
View file @
62683b57
<
template
>
<view
class=
"content"
>
<view
class=
"text"
>
<u-textarea
v-model=
"message"
:cursorSpacing=
"100"
:height=
"165"
:show-confirm-bar=
"false"
:maxlength=
"50"
placeholder=
"请输入内容"
count
></u-textarea>
</view>
<view
class=
"adding"
@
click=
"saveAbout"
>
保存
</view>
<ELM
ref=
"elm"
:msg=
"tipMsg"
:isConfirm=
"isConfirm"
@
confirm=
"confirm"
></ELM>
</view>
</
template
>
<
script
>
import
ELM
from
'@/components/elm-toast/index.vue'
;
import
{
addMessage
}
from
"../api/user"
;
export
default
{
data
()
{
return
{
userId
:
''
,
message
:
''
,
type
:
0
,
tipMsg
:
''
,
isConfirm
:
false
}
},
components
:
{
ELM
},
onLoad
(
option
)
{
this
.
type
=
option
.
type
;
this
.
userId
=
option
.
userId
;
uni
.
setNavigationBarTitle
({
title
:
"留言"
})
},
onPageScroll
(
e
)
{
if
(
e
.
scrollTop
>
50
)
{}
else
{}
},
methods
:
{
async
saveAbout
()
{
uni
.
showLoading
({
title
:
'保存中...'
})
const
data
=
{
targetId
:
this
.
userId
,
content
:
this
.
message
}
addMessage
(
data
).
then
(
res
=>
{
if
(
res
.
data
.
code
==
200
)
{
this
.
isConfirm
=
true
;
this
.
tipMsg
=
"保存成功"
;
this
.
$refs
.
elm
.
showDialog
();
}
else
{
this
.
tipMsg
=
res
.
data
.
msg
;
this
.
$refs
.
elm
.
showDialog
();
}
})
},
confirm
()
{
this
.
isConfirm
=
false
;
uni
.
navigateBack
({
delta
:
1
})
},
}
}
</
script
>
<
style
lang=
"less"
>
page {
background-color: #F4F5F9;
}
.content {
width: 100%;
height: 100%;
}
.text {
width: 100%;
height: 365rpx;
background: #ffffff;
border-top: 1rpx solid #eee;
}
.adding {
width: 614rpx;
height: 84rpx;
background: linear-gradient(86deg, #C2D2F9 0%, #C5C2F3 100%);
border-radius: 42rpx 42rpx 42rpx 42rpx;
font-size: 28rpx;
font-family: 'PingFang SC-Regular, PingFang SC';
font-weight: 400;
color: #415C9E;
line-height: 84rpx;
position: fixed;
bottom: 54rpx;
left: 68rpx;
text-align: center;
}
</
style
>
pagesUser/userInfo.vue
View file @
62683b57
...
@@ -204,7 +204,7 @@
...
@@ -204,7 +204,7 @@
<image
:src=
"baseUrl+'/user/con1-no.png'"
style=
"width: 100%;height: 100%;;"
mode=
"aspectFill"
></image>
<image
:src=
"baseUrl+'/user/con1-no.png'"
style=
"width: 100%;height: 100%;;"
mode=
"aspectFill"
></image>
</view>
</view>
<!--
<view
v-else-if=
"isFollowed === 1"
class=
"right"
@
click=
"logion(userData.userId, false, baseUrl+'/user/con1-no.png')"
>
-->
<!--
<view
v-else-if=
"isFollowed === 1"
class=
"right"
@
click=
"logion(userData.userId, false, baseUrl+'/user/con1-no.png')"
>
-->
<view
v-else-if=
"isFollowed === 1"
class=
"right"
>
<view
v-else-if=
"isFollowed === 1"
@
click=
"addMessage(userData.userId)"
class=
"right"
>
<image
:src=
"baseUrl+'/user/message.png'"
style=
"width: 100%;height: 100%;;"
mode=
"aspectFill"
></image>
<image
:src=
"baseUrl+'/user/message.png'"
style=
"width: 100%;height: 100%;;"
mode=
"aspectFill"
></image>
</view>
</view>
</view>
</view>
...
@@ -468,6 +468,11 @@ import {addFollow, deleteFollow, isFollow, likeUser, userDetail} from "../api/us
...
@@ -468,6 +468,11 @@ import {addFollow, deleteFollow, isFollow, likeUser, userDetail} from "../api/us
})
})
}
}
})
})
},
addMessage
(
id
){
uni
.
navigateTo
({
url
:
"/pagesUser/addMessage?userId="
+
id
})
},
},
backbar
()
{
backbar
()
{
uni
.
navigateBack
({
uni
.
navigateBack
({
...
...
pagesme/me/updateInformation.vue
View file @
62683b57
...
@@ -169,7 +169,7 @@
...
@@ -169,7 +169,7 @@
</view>
</view>
</view>
</view>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view>
{{
userInfo
.
memIntroduce
}}
</view>
<view>
{{
userInfo
.
memIntroduce
?
userInfo
.
memIntroduce
:
''
}}
</view>
</view>
</view>
</view>
</view>
<!-- 兴趣爱好-->
<!-- 兴趣爱好-->
...
@@ -184,7 +184,7 @@
...
@@ -184,7 +184,7 @@
</view>
</view>
</view>
</view>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view>
{{
userInfo
.
memHobby
}}
</view>
<view>
{{
userInfo
.
memHobby
?
userInfo
.
memHobby
:
''
}}
</view>
</view>
</view>
</view>
</view>
<!-- 心仪的Ta-->
<!-- 心仪的Ta-->
...
@@ -199,7 +199,7 @@
...
@@ -199,7 +199,7 @@
</view>
</view>
</view>
</view>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view>
{{
userInfo
.
memHalfDesire
}}
</view>
<view>
{{
userInfo
.
memHalfDesire
?
userInfo
.
memHalfDesire
:
''
}}
</view>
</view>
</view>
</view>
</view>
<!-- 未来规划-->
<!-- 未来规划-->
...
@@ -214,7 +214,7 @@
...
@@ -214,7 +214,7 @@
</view>
</view>
</view>
</view>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view
class=
" mt25 fs28"
style=
"color: #434343; "
>
<view>
{{
userInfo
.
memFuturePlan
}}
</view>
<view>
{{
userInfo
.
memFuturePlan
?
userInfo
.
memFuturePlan
:
''
}}
</view>
</view>
</view>
</view>
</view>
...
...
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