Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
foreign
/
customer-service
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
2b323c6f
authored
Dec 22, 2021
by
Sixong.Zhu
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
u
parent
62ac38f4
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
store/index.ts
store/index.ts
View file @
2b323c6f
...
...
@@ -548,9 +548,12 @@ export default {
state
[
ChatStore
.
STATE_CURRENT_UNREAD_MESSAGE_COUNT
]
=
sum
;
},
async
[
ChatStore
.
ACTION_UPDATE_CHAT_UNREAD_MESSAGE_COUNT
](
{
dispatch
},
{
dispatch
,
state
},
p
:
{
chat
:
number
;
unread
:
number
}
)
{
const
list
=
state
[
ChatStore
.
STATE_MY_CHAT_ROOM_LIST
]
as
ChatType
[];
const
t
=
list
.
find
(
i
=>
i
.
id
===
p
.
chat
)
t
&&
(
t
.
unread_msg_count
=
p
.
unread
)
return
dbController
.
updateChat4UnreadCount
(
p
.
chat
,
p
.
unread
)
.
then
(()
=>
...
...
@@ -752,7 +755,7 @@ export default {
};
if
(
e
.
type
===
MessageType
.
Withdraw
)
{
dbController
.
removeMessage
(
e
.
chat_id
,
[
+
e
.
msg
])
.
removeMessage
(
e
.
chat_id
,
e
.
msg
.
startsWith
(
'['
)
?
JSON
.
parse
(
e
.
msg
)
:
[
+
e
.
msg
])
.
finally
(()
=>
thenAction
());
}
else
{
thenAction
();
...
...
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