【优化】重命名 publicList

This commit is contained in:
cherishsince 2024-07-15 16:15:06 +08:00
parent 6b69dd74d4
commit ef4fb7ec05
5 changed files with 10 additions and 10 deletions

View File

@ -128,10 +128,10 @@ public class AiImageController {
return success(true);
}
@GetMapping("/release-list")
@GetMapping("/public-list")
@Operation(summary = "发布列表")
public CommonResult<PageResult<AiImageRespVO>> releaseList(AiImageReleaseListReqVO releaseListReqVO) {
PageResult<AiImageDO> pageResult = imageService.releaseList(releaseListReqVO);
public CommonResult<PageResult<AiImageRespVO>> publicList(AiImagePublicListReqVO publicListReqVO) {
PageResult<AiImageDO> pageResult = imageService.publicList(publicListReqVO);
return success(BeanUtils.toBean(pageResult, AiImageRespVO.class));
}
}

View File

@ -6,7 +6,7 @@ import lombok.Data;
@Schema(description = "Ai Image 发布列表 req")
@Data
public class AiImageReleaseListReqVO extends PageParam {
public class AiImagePublicListReqVO extends PageParam {
@Schema(description = "提示词")
private String prompt;

View File

@ -5,7 +5,7 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.module.ai.controller.admin.image.vo.AiImagePageReqVO;
import cn.iocoder.yudao.module.ai.controller.admin.image.vo.AiImageReleaseListReqVO;
import cn.iocoder.yudao.module.ai.controller.admin.image.vo.AiImagePublicListReqVO;
import cn.iocoder.yudao.module.ai.dal.dataobject.image.AiImageDO;
import org.apache.ibatis.annotations.Mapper;
@ -44,7 +44,7 @@ public interface AiImageMapper extends BaseMapperX<AiImageDO> {
AiImageDO::getPlatform, platform);
}
default PageResult<AiImageDO> selectPageOfReleaseList(AiImageReleaseListReqVO releaseListReqVO) {
default PageResult<AiImageDO> selectPageOfPublicList(AiImagePublicListReqVO releaseListReqVO) {
return selectPage(releaseListReqVO, new LambdaQueryWrapperX<AiImageDO>()
.eqIfPresent(AiImageDO::getPublicStatus, Boolean.TRUE)
.eqIfPresent(AiImageDO::getPrompt, releaseListReqVO.getPrompt())

View File

@ -118,9 +118,9 @@ public interface AiImageService {
/**
* 发布列表
* @param releaseListReqVO
* @param publicListReqVO
* @return
*/
PageResult<AiImageDO> releaseList(AiImageReleaseListReqVO releaseListReqVO);
PageResult<AiImageDO> publicList(AiImagePublicListReqVO publicListReqVO);
}

View File

@ -337,8 +337,8 @@ public class AiImageServiceImpl implements AiImageService {
}
@Override
public PageResult<AiImageDO> releaseList(AiImageReleaseListReqVO releaseListReqVO) {
return imageMapper.selectPageOfReleaseList(releaseListReqVO);
public PageResult<AiImageDO> publicList(AiImagePublicListReqVO publicListReqVO) {
return imageMapper.selectPageOfPublicList(publicListReqVO);
}
/**