|
@@ -255,12 +255,15 @@ public class CommunityChatMsgController extends BaseController {
|
|
|
@GetMapping("/getReturnRecord")
|
|
|
public AjaxResult getReturnRecord(String status, String searchValue) {
|
|
|
Long userId = SecurityUtils.getUserId();
|
|
|
+ int pageNum = Convert.toInt(ServletUtils.getParameter("pageNum"), 1);
|
|
|
+ int pageSize = Convert.toInt(ServletUtils.getParameter("pageSize"), 10);
|
|
|
+ int offset = (pageNum - 1) * pageSize;
|
|
|
List<SysUserVo> sysUserChatVos = null;
|
|
|
List<CommunityReturnRecord> returnRecords = communityReturnRecordService
|
|
|
.getReturnRecord(userId, status);
|
|
|
if (returnRecords != null && !returnRecords.isEmpty()) {
|
|
|
List<Long> returnIds = returnRecords.stream().map(CommunityReturnRecord::getId).collect(Collectors.toList());
|
|
|
- sysUserChatVos = communityChatMsgService.getChatListWithLatestMessage(userId, "anonymous", searchValue, returnIds);
|
|
|
+ sysUserChatVos = communityChatMsgService.getChatListWithLatestMessage(userId, "anonymous", searchValue, returnIds,offset,pageSize);
|
|
|
}
|
|
|
return AjaxResult.success(sysUserChatVos);
|
|
|
}
|