feat(script-favorite): add ScriptFavoriteService interface
- toggleFavorite: toggle favorite status for a script - getFavoritePage: paginated list of user's favorite scripts - getFavoritedScriptIds: batch check which scripts are favorited - isFavorited: check single script favorite status - getFavoriteCount: count user's total favorites
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
package com.emotion.service;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.emotion.common.PageResult;
|
||||
import com.emotion.dto.response.EpicScriptResponse;
|
||||
import com.emotion.dto.response.ScriptFavoriteResponse;
|
||||
import com.emotion.entity.ScriptFavorite;
|
||||
|
||||
import java.util.Set;
|
||||
|
||||
/**
|
||||
* 剧本收藏服务接口
|
||||
*
|
||||
* @author huazhongmin
|
||||
* @date 2026-07-19
|
||||
*/
|
||||
public interface ScriptFavoriteService extends IService<ScriptFavorite> {
|
||||
|
||||
ScriptFavoriteResponse toggleFavorite(String scriptId);
|
||||
|
||||
PageResult<EpicScriptResponse> getFavoritePage(long current, long size);
|
||||
|
||||
Set<String> getFavoritedScriptIds(Set<String> scriptIds);
|
||||
|
||||
boolean isFavorited(String scriptId);
|
||||
|
||||
long getFavoriteCount();
|
||||
}
|
||||
Reference in New Issue
Block a user