using Volo.Abp.Application.Dtos;
using Yi.Framework.AiHub.Application.Contracts.Dtos.Announcement;

namespace Yi.Framework.AiHub.Application.Contracts.IServices;

/// <summary>
/// 公告服务接口
/// </summary>
public interface IAnnouncementService
{
    /// <summary>
    /// 获取公告信息（前端首页使用）
    /// </summary>
    /// <returns>公告信息</returns>
    Task<List<AnnouncementLogDto>> GetAsync();

    /// <summary>
    /// 获取公告列表（后台管理使用）
    /// </summary>
    /// <param name="input">查询参数</param>
    /// <returns>分页公告列表</returns>
    Task<PagedResultDto<AnnouncementDto>> GetListAsync(AnnouncementGetListInput input);

    /// <summary>
    /// 根据ID获取公告
    /// </summary>
    /// <param name="id">公告ID</param>
    /// <returns>公告详情</returns>
    Task<AnnouncementDto> GetByIdAsync(Guid id);

    /// <summary>
    /// 创建公告
    /// </summary>
    /// <param name="input">创建输入</param>
    /// <returns>创建的公告</returns>
    Task<AnnouncementDto> CreateAsync(AnnouncementCreateInput input);

    /// <summary>
    /// 更新公告
    /// </summary>
    /// <param name="input">更新输入</param>
    /// <returns>更新后的公告</returns>
    Task<AnnouncementDto> UpdateAsync(AnnouncementUpdateInput input);

    /// <summary>
    /// 删除公告
    /// </summary>
    /// <param name="id">公告ID</param>
    Task DeleteAsync(Guid id);
}
