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
0d944462
Commit
0d944462
authored
Feb 20, 2025
by
罗林杰
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改消息未读
parent
fbe8bbf2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
1 deletion
+19
-1
index.js
api/user/index.js
+7
-0
my.vue
pages/tab/my.vue
+9
-1
message.vue
pagesme/message/message.vue
+3
-0
No files found.
api/user/index.js
View file @
0d944462
...
@@ -210,3 +210,10 @@ export function addMemTraffic(data) {
...
@@ -210,3 +210,10 @@ export function addMemTraffic(data) {
data
:
data
data
:
data
})
})
}
}
// 留言未读数
export
function
noReadMessageAllCount
()
{
return
request
({
url
:
'/app/memLeaveMessage/noReadMessageAllCount'
,
method
:
'get'
,
})
}
pages/tab/my.vue
View file @
0d944462
...
@@ -141,6 +141,7 @@
...
@@ -141,6 +141,7 @@
<view
class=
"box-bottom-right-name"
>
<view
class=
"box-bottom-right-name"
>
{{
item
.
desc
}}
{{
item
.
desc
}}
</view>
</view>
<u-badge
v-if=
"item.name == '我的留言'"
type=
"error"
max=
"99"
:value=
"noReadMessageAllCount"
></u-badge>
<image
:src=
"baseUrl+'/common/right.png'"
class=
"box-bottom-right-img"
mode=
"aspectFill"
></image>
<image
:src=
"baseUrl+'/common/right.png'"
class=
"box-bottom-right-img"
mode=
"aspectFill"
></image>
</view>
</view>
</view>
</view>
...
@@ -170,7 +171,7 @@
...
@@ -170,7 +171,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
{
setUserProfile
}
from
'../../api/login/index'
import
{
setUserProfile
}
from
'../../api/login/index'
import
{
userDetail
}
from
"../../api/user"
;
import
{
noReadMessageAllCount
,
userDetail
}
from
"../../api/user"
;
import
{
articleList
,
getOssUrl
}
from
"../../api/article"
;
import
{
articleList
,
getOssUrl
}
from
"../../api/article"
;
export
default
{
export
default
{
data
()
{
data
()
{
...
@@ -188,6 +189,7 @@ import {articleList, getOssUrl} from "../../api/article";
...
@@ -188,6 +189,7 @@ import {articleList, getOssUrl} from "../../api/article";
userInfo
:{},
//用户信息
userInfo
:{},
//用户信息
token
:
''
,
//token
token
:
''
,
//token
articleInfo
:{},
articleInfo
:{},
noReadMessageAllCount
:
''
,
info
:{},
info
:{},
button
:
[
button
:
[
{
{
...
@@ -242,6 +244,7 @@ import {articleList, getOssUrl} from "../../api/article";
...
@@ -242,6 +244,7 @@ import {articleList, getOssUrl} from "../../api/article";
this
.
articleImg
=
[]
this
.
articleImg
=
[]
this
.
getUserDetail
()
this
.
getUserDetail
()
this
.
getArticleList
()
this
.
getArticleList
()
this
.
getnoReadMessageAllCount
()
},
},
methods
:
{
methods
:
{
//获取用户详情信息
//获取用户详情信息
...
@@ -418,6 +421,11 @@ import {articleList, getOssUrl} from "../../api/article";
...
@@ -418,6 +421,11 @@ import {articleList, getOssUrl} from "../../api/article";
})
})
}
else
if
(
i
==
5
)
{}
}
else
if
(
i
==
5
)
{}
},
},
getnoReadMessageAllCount
(){
noReadMessageAllCount
().
then
(
res
=>
{
this
.
noReadMessageAllCount
=
res
.
data
.
data
})
},
//登录
//登录
login
()
{
login
()
{
uni
.
navigateTo
({
uni
.
navigateTo
({
...
...
pagesme/message/message.vue
View file @
0d944462
...
@@ -15,6 +15,9 @@
...
@@ -15,6 +15,9 @@
<view
class=
"recommendation-card"
@
click=
"gotoBusinessDetail(item)"
>
<view
class=
"recommendation-card"
@
click=
"gotoBusinessDetail(item)"
>
<view
class=
"card-image"
style=
"justify-content: left;display: flex"
>
<view
class=
"card-image"
style=
"justify-content: left;display: flex"
>
<image
class=
"img"
:src=
"item.avatar"
/>
<image
class=
"img"
:src=
"item.avatar"
/>
<view
style=
"margin-top: 20rpx;"
>
<u-badge
:isDot=
"item.noReadCount != 0"
type=
"error"
></u-badge>
</view>
<view
style=
"margin-left: 20rpx;margin-top: 20rpx;font-weight: 400;font-size: 32rpx"
>
<view
style=
"margin-left: 20rpx;margin-top: 20rpx;font-weight: 400;font-size: 32rpx"
>
{{
item
.
memNickName
}}
{{
item
.
memNickName
}}
<view
class=
"message"
>
<view
class=
"message"
>
...
...
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