package com.emotion.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.emotion.common.BasePageRequest;
import com.emotion.common.PageResult;
import com.emotion.dto.request.growth.GrowthTopicCreateRequest;
import com.emotion.dto.request.growth.GrowthTopicUpdateRequest;
import com.emotion.dto.response.growth.GrowthTopicResponse;
import com.emotion.entity.GrowthTopic;

import java.time.LocalDateTime;
import java.util.List;

/**
 * 成长话题服务接口
 * 
 * @author huazhongmin
 * @date 2025-09-08
 */
public interface GrowthTopicService extends IService<GrowthTopic> {
    
    /**
     * 分页查询成长话题
     */
    IPage<GrowthTopic> getPage(BasePageRequest request);
    
    /**
     * 分页查询成长话题响应
     */
    PageResult<GrowthTopicResponse> getPageWithResponse(BasePageRequest request);
    
    /**
     * 根据ID获取成长话题响应
     */
    GrowthTopicResponse getGrowthTopicResponseById(String id);

    /**
     * 创建成长话题
     */
    GrowthTopic createGrowthTopic(String title, String description, String category,
            String difficultyLevel, String tags, LocalDateTime endTime);
    
    /**
     * 创建成长话题并返回响应
     */
    GrowthTopicResponse createGrowthTopicWithResponse(GrowthTopicCreateRequest request);
    
    /**
     * 更新成长话题并返回响应
     */
    GrowthTopicResponse updateGrowthTopicWithResponse(GrowthTopicUpdateRequest request);
    
    /**
     * 删除成长话题
     */
    boolean deleteGrowthTopic(String id);
}
