using System.Threading.Tasks;
using Datory;
using GxPress.Common.Page;
using GxPress.Request.Media;
using GxPress.Result.Media;

namespace GxPress.Repository.Interface.Media
{
    public interface IMediaRepository:IRepository
    {
         Task<MediaResult> GetAsync(int id);
        /// <summary>
        /// 删除
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
         Task<bool> DeleteAsync(int id);
        /// <summary>
        /// 添加媒体
        /// </summary>
        /// <param name="result"></param>
        /// <returns></returns>
        Task<bool> InsertAsync(MediaResult result);

         Task<bool> UpdateAsync(MediaResult result);
       Task<bool> UpdateAsync(SqlKata.Query query);

        Task<PagedList<Entity.tede2.Media.Media>> GetAllAsync(MediaSearchRequest request);
    }
}
