|
|
|
@ -9,6 +9,8 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
|
|
import com.huoran.iasf.common.utils.Constant; |
|
|
|
|
import com.huoran.iasf.common.utils.R; |
|
|
|
|
import com.huoran.iasf.entity.SysContent; |
|
|
|
|
import com.huoran.iasf.entity.SysContentFile; |
|
|
|
|
import com.huoran.iasf.mapper.SysContentFileMapper; |
|
|
|
|
import com.huoran.iasf.mapper.SysContentMapper; |
|
|
|
|
import com.huoran.iasf.service.SysContentService; |
|
|
|
|
import com.huoran.iasf.vo.req.ArticleModifiedSortReq; |
|
|
|
@ -39,6 +41,8 @@ public class SysContentServiceImpl extends ServiceImpl<SysContentMapper, SysCont |
|
|
|
|
|
|
|
|
|
@Autowired |
|
|
|
|
private StringRedisTemplate redisTemplate; |
|
|
|
|
@Autowired |
|
|
|
|
private SysContentFileMapper fileMapper; |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public boolean checkIfTheTitleIsRepeat(ContentHeavyTitleReqVO content) { |
|
|
|
@ -77,6 +81,12 @@ public class SysContentServiceImpl extends ServiceImpl<SysContentMapper, SysCont |
|
|
|
|
} |
|
|
|
|
Page<PageContentRespVO> page = new Page<PageContentRespVO>(reqVO.getPageNum(), reqVO.getPageSize()); |
|
|
|
|
IPage<PageContentRespVO> pageList = baseMapper.getPublishedArticles(page, reqVO); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (PageContentRespVO vo : pageList.getRecords()) { |
|
|
|
|
List<SysContentFile> fileList = fileMapper.getFileByContentId(vo.getId()); |
|
|
|
|
vo.setFileList(fileList); |
|
|
|
|
} |
|
|
|
|
return R.success(pageList); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|