修复Bug,使留言板红点能够正常消失
This commit is contained in:
parent
7731bcd6cb
commit
f123c8b01b
@ -2,6 +2,7 @@ package com.xhpc.board.mapper;
|
||||
|
||||
import com.xhpc.board.domain.QueryUserListRequest;
|
||||
import com.xhpc.board.domain.SendMessageToPlatformRequest;
|
||||
import com.xhpc.board.domain.UserQueryCondition;
|
||||
import com.xhpc.board.pojo.XhpcMessageBoardReceiveUser;
|
||||
|
||||
import java.util.List;
|
||||
@ -62,4 +63,14 @@ public interface XhpcMessageBoardReceiveUserMapper {
|
||||
*/
|
||||
Long totalUserNumber(QueryUserListRequest param);
|
||||
|
||||
/**
|
||||
* 消除留言板对应用户的红点
|
||||
*
|
||||
* @param userQueryCondition 用户信息
|
||||
* @author WH
|
||||
* @date 2022/1/16 20:13
|
||||
* @since version-1.0
|
||||
*/
|
||||
void updateHaveNewInfoIsNull(UserQueryCondition userQueryCondition);
|
||||
|
||||
}
|
||||
@ -346,9 +346,11 @@ public class XhpcMessageBoardServiceImpl implements XhpcMessageBoardService {
|
||||
Long messageId = aMonthRecords.get(index).getMessageId();
|
||||
messageIdList.add(messageId);
|
||||
}
|
||||
//设置查询出来的记录为已读状态,然后再查询,保证查询出来的是否有新信息状态被改变
|
||||
//设置查询出来的记录为已读状态,然后再查询,保证查询出来的信息状态被改变
|
||||
messageBoardMapper.setUserReadedStatus(messageIdList);
|
||||
aMonthRecords = messageBoardMapper.selectBy(userQueryCondition, nextTimeStr);
|
||||
//消除后台留言板红点
|
||||
xhpcMessageBoardReceiveUserMapper.updateHaveNewInfoIsNull(userQueryCondition);
|
||||
//封装数据
|
||||
ArrayList<QueryUserMassageResponse.DataDTO> dataDTOS = new ArrayList<>();
|
||||
for (XhpcMessageBoard aMonthRecord : aMonthRecords) {
|
||||
|
||||
@ -87,6 +87,15 @@
|
||||
AND sender_type = #{senderType}
|
||||
AND del_flag IS NULL;
|
||||
</update>
|
||||
<update id="updateHaveNewInfoIsNull">
|
||||
UPDATE xhpc_message_board_receive_user
|
||||
SET have_new_info = null
|
||||
WHERE tenant_type = #{tenantType}
|
||||
AND tenant_id = #{tenantId}
|
||||
AND sender_account = #{senderAccount}
|
||||
AND sender_type = #{senderType}
|
||||
AND del_flag IS NULL;
|
||||
</update>
|
||||
<select id="findOneByCondition" resultMap="BaseResultMap">
|
||||
SELECT
|
||||
<include refid="Base_Column_List"/>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user