|
|
@ -58,10 +58,9 @@ public class SysContentServiceImpl extends ServiceImpl<SysContentMapper, SysCont |
|
|
|
public R newlyPublishedArticles(PageContentReqVO reqVO) { |
|
|
|
public R newlyPublishedArticles(PageContentReqVO reqVO) { |
|
|
|
QueryWrapper<SysContent> queryWrapper = new QueryWrapper<>(); |
|
|
|
QueryWrapper<SysContent> queryWrapper = new QueryWrapper<>(); |
|
|
|
queryWrapper.eq("site_id", reqVO.getSiteId()); |
|
|
|
queryWrapper.eq("site_id", reqVO.getSiteId()); |
|
|
|
queryWrapper.eq("is_release", 1); |
|
|
|
queryWrapper.eq("is_release", 1).orderByDesc("create_time"); |
|
|
|
queryWrapper.eq("deleted", 1).orderByDesc("create_time"); |
|
|
|
Page<SysContent> page = new Page<SysContent>(reqVO.getPageNum(), reqVO.getPageSize()); |
|
|
|
Page<PageContentRespVO> page = new Page<PageContentRespVO>(reqVO.getPageNum(), reqVO.getPageSize()); |
|
|
|
IPage<SysContent> pageList = baseMapper.selectPage(page, queryWrapper); |
|
|
|
IPage<PageContentRespVO> pageList = baseMapper.articlePaginationList(page, reqVO); |
|
|
|
|
|
|
|
return R.success(pageList); |
|
|
|
return R.success(pageList); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|