BCards/src/BCards.Web/Repositories/ICategoryRepository.cs
2025-06-24 23:25:02 -03:00

14 lines
448 B
C#

using BCards.Web.Models;
namespace BCards.Web.Repositories;
public interface ICategoryRepository
{
Task<List<Category>> GetAllActiveAsync();
Task<Category?> GetBySlugAsync(string slug);
Task<Category?> GetByIdAsync(string id);
Task<Category> CreateAsync(Category category);
Task<Category> UpdateAsync(Category category);
Task DeleteAsync(string id);
Task<bool> SlugExistsAsync(string slug, string? excludeId = null);
}