Skip to content
Snippets Groups Projects
IUserService.cs 1.01 KiB
Newer Older
Lucca Santangelo's avatar
Lucca Santangelo committed
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading.Tasks;
Lucca Santangelo's avatar
Lucca Santangelo committed
using Tsi1.BusinessLayer.Dtos;
using Tsi1.BusinessLayer.Helpers;
Lucca Santangelo's avatar
Lucca Santangelo committed
using Tsi1.DataLayer.Entities;

namespace Tsi1.BusinessLayer.Interfaces
{
    public interface IUserService
    {
esantangelo's avatar
esantangelo committed
        Task<ServiceResult<User>> Authenticate(string username, string password, int tenantId);
esantangelo's avatar
esantangelo committed
        Task<ServiceResult<User>> Create(UserRegisterDto dto, string type, int tenantId);
        Task<ServiceResult<List<UserDetailDto>>> GetAll(int tenantId);
esantangelo's avatar
esantangelo committed

        Task<ServiceResult<UserDetailDto>> GetById(int userId);
Lucca Santangelo's avatar
Lucca Santangelo committed

        Task<ServiceResult<User>> GetByUsername(string username, int tenantId);

        Task<ServiceResult<bool>> UpdatePassword(int userId, string password);
esantangelo's avatar
esantangelo committed

        Task<ServiceResult<bool>> Modify(UserModifyDto dto, string type, int userId);

        Task<ServiceResult<int>> GetTenant(int userId);

        Task<ServiceResult<bool>> Delete(int userId);

        Task<ServiceResult<UserTypeDto>> GetUserType(int userId);
Lucca Santangelo's avatar
Lucca Santangelo committed
    }
}