using Fengling.Console.Models.Entities;

namespace Fengling.Console.Repositories;

public interface IRoleRepository
{
    Task<ApplicationRole?> GetByIdAsync(long id);
    Task<ApplicationRole?> GetByNameAsync(string name);
    Task<IEnumerable<ApplicationRole>> GetAllAsync();
    Task<IEnumerable<ApplicationRole>> GetPagedAsync(int page, int pageSize, string? name = null, string? tenantId = null);
    Task<int> CountAsync(string? name = null, string? tenantId = null);
    Task AddAsync(ApplicationRole role);
    Task UpdateAsync(ApplicationRole role);
    Task DeleteAsync(ApplicationRole role);
}
