30 lines
		
	
	
		
			902 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			30 lines
		
	
	
		
			902 B
		
	
	
	
		
			C#
		
	
	
	
	
	
| using System.ComponentModel.DataAnnotations;
 | |
| 
 | |
| namespace GestionIntegral.Api.Dtos.Suscripciones
 | |
| {
 | |
|     public class CreateSuscripcionDto
 | |
|     {
 | |
|         [Required]
 | |
|         public int IdSuscriptor { get; set; }
 | |
|         
 | |
|         [Required]
 | |
|         public int IdPublicacion { get; set; }
 | |
| 
 | |
|         [Required]
 | |
|         public DateTime FechaInicio { get; set; }
 | |
|         
 | |
|         public DateTime? FechaFin { get; set; }
 | |
| 
 | |
|         [Required]
 | |
|         public string Estado { get; set; } = "Activa";
 | |
| 
 | |
|         [Required(ErrorMessage = "Debe especificar los días de entrega.")]
 | |
|         public List<string> DiasEntrega { get; set; } = new List<string>(); // "L", "M", "X"...
 | |
| 
 | |
|         [StringLength(250)]
 | |
|         public string? Observaciones { get; set; }
 | |
|     }
 | |
| }
 | |
| 
 | |
| // Nota: Por ahora, el DTO de actualización puede ser similar al de creación.
 | |
| // Si se necesita una lógica diferente, se crearía un UpdateSuscripcionDto. |