Add user and role management features

This commit is contained in:
2026-08-18 15:43:55 +05:30
parent e0e691acbf
commit be51351f74
10 changed files with 386 additions and 0 deletions
@@ -0,0 +1,18 @@
namespace Distribution.Features.User;
public interface IUserRepository
{
Task<Models.User?> GetByIdAsync(Guid id);
Task<Models.User?> GetByUsernameAsync(string username);
Task<List<Models.User>> GetAllAsync();
Task AddAsync(Models.User entity);
void Update(Models.User entity);
void Remove(Models.User entity);
Task<List<Models.UserRegionScope>> GetRegionScopesAsync(Guid userId);
Task<List<Models.UserRouteScope>> GetRouteScopesAsync(Guid userId);
Task<List<Models.UserStoreScope>> GetStoreScopesAsync(Guid userId);
Task ReplaceRegionScopesAsync(Guid userId, IEnumerable<Guid> regionIds);
Task ReplaceRouteScopesAsync(Guid userId, IEnumerable<Guid> routeIds);
Task ReplaceStoreScopesAsync(Guid userId, IEnumerable<Guid> storeIds);
}