Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wecloud_im_server
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hewei
wecloud_im_server
Commits
d87c12e7
Commit
d87c12e7
authored
May 18, 2022
by
罗长华
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/xiaohudou_20220427' into xiaohudou_20220427
parents
ced42ebe
a615d63d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
core/src/main/java/com/wecloud/im/action/InboxAction.java
+4
-0
core/src/main/java/com/wecloud/im/controller/ImInboxController.java
+4
-0
No files found.
core/src/main/java/com/wecloud/im/action/InboxAction.java
View file @
d87c12e7
package
com
.
wecloud
.
im
.
action
;
package
com
.
wecloud
.
im
.
action
;
import
com.alibaba.fastjson.JSON
;
import
io.geekidea.springbootplus.framework.common.api.ApiCode
;
import
io.geekidea.springbootplus.framework.common.api.ApiCode
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
...
@@ -40,6 +41,7 @@ public class InboxAction {
...
@@ -40,6 +41,7 @@ public class InboxAction {
@ActionMapping
(
"/msgReceivedUpdate"
)
@ActionMapping
(
"/msgReceivedUpdate"
)
@ApiOperation
(
value
=
"消息修改为已接收状态"
)
@ApiOperation
(
value
=
"消息修改为已接收状态"
)
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateImMsgReceived
(
@Validated
ImMsgReceivedStatusUpdate
data
)
throws
Exception
{
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateImMsgReceived
(
@Validated
ImMsgReceivedStatusUpdate
data
)
throws
Exception
{
log
.
info
(
"消息修改为已接收状态入参 {}"
,
JSON
.
toJSONString
(
data
));
imInboxService
.
updateImMsgReceived
(
data
);
imInboxService
.
updateImMsgReceived
(
data
);
return
WsResponse
.
ok
();
return
WsResponse
.
ok
();
}
}
...
@@ -50,6 +52,7 @@ public class InboxAction {
...
@@ -50,6 +52,7 @@ public class InboxAction {
@ActionMapping
(
"/msgReadUpdate"
)
@ActionMapping
(
"/msgReadUpdate"
)
@ApiOperation
(
value
=
"消息修改为已读状态"
)
@ApiOperation
(
value
=
"消息修改为已读状态"
)
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateInMsgReadUpdate
(
MsgReadStatusUpdateParam
data
)
throws
Exception
{
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateInMsgReadUpdate
(
MsgReadStatusUpdateParam
data
)
throws
Exception
{
log
.
info
(
"消息修改为已读状态入参 {}"
,
JSON
.
toJSONString
(
data
));
if
(
CollectionUtils
.
isEmpty
(
data
.
getMsgIds
()))
{
if
(
CollectionUtils
.
isEmpty
(
data
.
getMsgIds
()))
{
return
WsResponse
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
return
WsResponse
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
}
}
...
@@ -64,6 +67,7 @@ public class InboxAction {
...
@@ -64,6 +67,7 @@ public class InboxAction {
@ActionMapping
(
"/updateMsgReadStatusByConversation"
)
@ActionMapping
(
"/updateMsgReadStatusByConversation"
)
@ApiOperation
(
value
=
"会话消息修改为已读状态"
)
@ApiOperation
(
value
=
"会话消息修改为已读状态"
)
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateMsgReadStatusByConversation
(
UpdateMsgReadStatusByConversationParam
data
)
throws
Exception
{
public
WsResponse
<
Map
<
String
,
Boolean
>>
updateMsgReadStatusByConversation
(
UpdateMsgReadStatusByConversationParam
data
)
throws
Exception
{
log
.
info
(
"会话消息修改为已读状态入参 {}"
,
JSON
.
toJSONString
(
data
));
if
(
data
.
getConversationId
()
==
null
)
{
if
(
data
.
getConversationId
()
==
null
)
{
return
WsResponse
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
return
WsResponse
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
}
}
...
...
core/src/main/java/com/wecloud/im/controller/ImInboxController.java
View file @
d87c12e7
package
com
.
wecloud
.
im
.
controller
;
package
com
.
wecloud
.
im
.
controller
;
import
com.alibaba.fastjson.JSON
;
import
com.wecloud.im.param.ImMsgReceivedStatusUpdate
;
import
com.wecloud.im.param.ImMsgReceivedStatusUpdate
;
import
com.wecloud.im.param.MsgReadStatusUpdateParam
;
import
com.wecloud.im.param.MsgReadStatusUpdateParam
;
import
com.wecloud.im.param.UpdateMsgReadStatusByConversationParam
;
import
com.wecloud.im.param.UpdateMsgReadStatusByConversationParam
;
...
@@ -39,6 +40,7 @@ public class ImInboxController extends BaseController {
...
@@ -39,6 +40,7 @@ public class ImInboxController extends BaseController {
@PostMapping
(
"/msgReceivedUpdate"
)
@PostMapping
(
"/msgReceivedUpdate"
)
@ApiOperation
(
value
=
"消息修改为已接收状态"
)
@ApiOperation
(
value
=
"消息修改为已接收状态"
)
public
ApiResult
<
Boolean
>
updateImMsgReceived
(
@RequestBody
@Validated
ImMsgReceivedStatusUpdate
imMsgReceivedUpdate
)
throws
Exception
{
public
ApiResult
<
Boolean
>
updateImMsgReceived
(
@RequestBody
@Validated
ImMsgReceivedStatusUpdate
imMsgReceivedUpdate
)
throws
Exception
{
log
.
info
(
"消息修改为已接收状态入参 {}"
,
JSON
.
toJSONString
(
imMsgReceivedUpdate
));
imInboxService
.
updateImMsgReceived
(
imMsgReceivedUpdate
);
imInboxService
.
updateImMsgReceived
(
imMsgReceivedUpdate
);
return
ApiResult
.
ok
();
return
ApiResult
.
ok
();
}
}
...
@@ -49,6 +51,7 @@ public class ImInboxController extends BaseController {
...
@@ -49,6 +51,7 @@ public class ImInboxController extends BaseController {
@PostMapping
(
"/msgReadUpdate"
)
@PostMapping
(
"/msgReadUpdate"
)
@ApiOperation
(
value
=
"消息修改为已读状态"
)
@ApiOperation
(
value
=
"消息修改为已读状态"
)
public
ApiResult
<
Boolean
>
updateInMsgReadUpdate
(
@RequestBody
MsgReadStatusUpdateParam
msgReadStatusUpdateParam
)
throws
Exception
{
public
ApiResult
<
Boolean
>
updateInMsgReadUpdate
(
@RequestBody
MsgReadStatusUpdateParam
msgReadStatusUpdateParam
)
throws
Exception
{
log
.
info
(
"消息修改为已读状态 {}"
,
JSON
.
toJSONString
(
msgReadStatusUpdateParam
));
if
(
CollectionUtils
.
isEmpty
(
msgReadStatusUpdateParam
.
getMsgIds
()))
{
if
(
CollectionUtils
.
isEmpty
(
msgReadStatusUpdateParam
.
getMsgIds
()))
{
return
ApiResult
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
return
ApiResult
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
}
}
...
@@ -62,6 +65,7 @@ public class ImInboxController extends BaseController {
...
@@ -62,6 +65,7 @@ public class ImInboxController extends BaseController {
@PostMapping
(
"/updateMsgReadStatusByConversation"
)
@PostMapping
(
"/updateMsgReadStatusByConversation"
)
@ApiOperation
(
value
=
"会话消息修改为已读状态"
)
@ApiOperation
(
value
=
"会话消息修改为已读状态"
)
public
ApiResult
<
Boolean
>
updateMsgReadStatusByConversation
(
@RequestBody
UpdateMsgReadStatusByConversationParam
param
)
throws
Exception
{
public
ApiResult
<
Boolean
>
updateMsgReadStatusByConversation
(
@RequestBody
UpdateMsgReadStatusByConversationParam
param
)
throws
Exception
{
log
.
info
(
"会话消息修改为已读状态入参 {}"
,
JSON
.
toJSONString
(
param
));
if
(
param
.
getConversationId
()
==
null
)
{
if
(
param
.
getConversationId
()
==
null
)
{
return
ApiResult
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
return
ApiResult
.
fail
(
ApiCode
.
PARAMETER_EXCEPTION
);
}
}
...
...
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