| 
									
										
										
										
											2025-06-06 18:33:09 -03:00
										 |  |  | using GestionIntegral.Api.Dtos.Reportes; | 
					
						
							|  |  |  | using GestionIntegral.Api.Models.Distribucion; | 
					
						
							|  |  |  | using System; | 
					
						
							|  |  |  | using System.Collections.Generic; | 
					
						
							|  |  |  | using System.Data; // Para IDbTransaction | 
					
						
							|  |  |  | using System.Threading.Tasks; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | namespace GestionIntegral.Api.Data.Repositories.Distribucion | 
					
						
							|  |  |  | { | 
					
						
							|  |  |  |     public interface INovedadCanillaRepository | 
					
						
							|  |  |  |     { | 
					
						
							|  |  |  |         // Para obtener novedades y el nombre del canillita | 
					
						
							|  |  |  |         Task<IEnumerable<(NovedadCanilla Novedad, string NombreCanilla)>> GetByCanillaAsync(int idCanilla, DateTime? fechaDesde, DateTime? fechaHasta); | 
					
						
							|  |  |  |         Task<NovedadCanilla?> GetByIdAsync(int idNovedad); | 
					
						
							|  |  |  |         Task<NovedadCanilla?> CreateAsync(NovedadCanilla novedad, int idUsuario, IDbTransaction? transaction = null); | 
					
						
							|  |  |  |         Task<bool> UpdateAsync(NovedadCanilla novedad, int idUsuario, IDbTransaction? transaction = null); | 
					
						
							|  |  |  |         Task<bool> DeleteAsync(int idNovedad, int idUsuario, IDbTransaction? transaction = null); | 
					
						
							|  |  |  |         // Podrías añadir un método para verificar si existe una novedad para un canillita en una fecha específica si es necesario | 
					
						
							|  |  |  |         Task<bool> ExistsByCanillaAndFechaAsync(int idCanilla, DateTime fecha, int? excludeIdNovedad = null); | 
					
						
							|  |  |  |         Task<IEnumerable<NovedadesCanillasReporteDto>> GetReporteNovedadesAsync(int idEmpresa, DateTime fechaDesde, DateTime fechaHasta); | 
					
						
							|  |  |  |         Task<IEnumerable<CanillaGananciaReporteDto>> GetReporteGananciasAsync(int idEmpresa, DateTime fechaDesde, DateTime fechaHasta); | 
					
						
							| 
									
										
										
										
											2025-06-09 19:37:07 -03:00
										 |  |  |         Task<IEnumerable<(NovedadCanillaHistorico Historial, string NombreUsuarioModifico)>> GetHistorialAsync( | 
					
						
							|  |  |  |         DateTime? fechaDesde, DateTime? fechaHasta, | 
					
						
							|  |  |  |         int? idUsuarioModifico, string? tipoModificacion, | 
					
						
							|  |  |  |         int? idNovedadOriginal); | 
					
						
							| 
									
										
										
										
											2025-06-06 18:33:09 -03:00
										 |  |  |     } | 
					
						
							|  |  |  | } |