【优化】字段重命名 job id 改为 task id

This commit is contained in:
cherishsince 2024-06-05 10:31:33 +08:00
parent 8d23e1b9d9
commit c0c2305c23
3 changed files with 6 additions and 6 deletions

View File

@ -111,11 +111,11 @@ public class AiImageDO extends BaseDO {
@TableField(typeHandler = JacksonTypeHandler.class) @TableField(typeHandler = JacksonTypeHandler.class)
private List<MidjourneyNotifyReqVO.Button> buttons; private List<MidjourneyNotifyReqVO.Button> buttons;
// TODO @芋艿再瞅瞅
/** /**
* midjourney proxy 关联的 job id * midjourney proxy 关联的 task id
*/ */
private String jobId; private String taskId;
/** /**
* 绘画错误信息 * 绘画错误信息
*/ */

View File

@ -34,7 +34,7 @@ public interface AiImageMapper extends BaseMapperX<AiImageDO> {
* @return * @return
*/ */
default AiImageDO selectByJobId(String id) { default AiImageDO selectByJobId(String id) {
return this.selectOne(new LambdaQueryWrapperX<AiImageDO>().eq(AiImageDO::getJobId, id)); return this.selectOne(new LambdaQueryWrapperX<AiImageDO>().eq(AiImageDO::getTaskId, id));
} }
default PageResult<AiImageDO> selectPage(Long userId, PageParam pageReqVO) { default PageResult<AiImageDO> selectPage(Long userId, PageParam pageReqVO) {

View File

@ -158,7 +158,7 @@ public class AiImageServiceImpl implements AiImageService {
} }
imageMapper.updateById(new AiImageDO() imageMapper.updateById(new AiImageDO()
.setId(aiImageDO.getId()) .setId(aiImageDO.getId())
.setJobId(submitRespVO.getResult()) .setTaskId(submitRespVO.getResult())
); );
return aiImageDO.getId(); return aiImageDO.getId();
} }
@ -228,7 +228,7 @@ public class AiImageServiceImpl implements AiImageService {
midjourneyProxyClient.action( midjourneyProxyClient.action(
new MidjourneyActionReqVO() new MidjourneyActionReqVO()
.setCustomId(customId) .setCustomId(customId)
.setTaskId(aiImageDO.getJobId()) .setTaskId(aiImageDO.getTaskId())
.setNotifyHook(midjourneyNotifyUrl) .setNotifyHook(midjourneyNotifyUrl)
); );
return Boolean.TRUE; return Boolean.TRUE;