19 lines
1.1 KiB
C#
19 lines
1.1 KiB
C#
using GestionIntegral.Api.Models.Distribucion;
|
|
using System.Collections.Generic;
|
|
using System.Threading.Tasks;
|
|
using System.Data;
|
|
|
|
namespace GestionIntegral.Api.Data.Repositories.Distribucion
|
|
{
|
|
public interface ICanillaRepository
|
|
{
|
|
Task<IEnumerable<(Canilla Canilla, string? NombreZona, string? NombreEmpresa)>> GetAllAsync(string? nomApeFilter, int? legajoFilter, bool? soloActivos, bool? esAccionista);
|
|
Task<(Canilla? Canilla, string? NombreZona, string? NombreEmpresa)> GetByIdAsync(int id);
|
|
Task<Canilla?> GetByIdSimpleAsync(int id); // Para obtener solo la entidad Canilla
|
|
Task<Canilla?> CreateAsync(Canilla nuevoCanilla, int idUsuario, IDbTransaction transaction);
|
|
Task<bool> UpdateAsync(Canilla canillaAActualizar, int idUsuario, IDbTransaction transaction);
|
|
Task<bool> ToggleBajaAsync(int id, bool darDeBaja, DateTime? fechaBaja, int idUsuario, IDbTransaction transaction);
|
|
Task<bool> ExistsByLegajoAsync(int legajo, int? excludeIdCanilla = null);
|
|
// IsInUse no es tan directo, ya que las liquidaciones se marcan. Se podría verificar dist_EntradasSalidasCanillas no liquidadas.
|
|
}
|
|
} |