From 5fe81d9515d71dad1e37f7ee3262a44c52e2599e Mon Sep 17 00:00:00 2001 From: HombreLaser Date: Mon, 28 Nov 2022 17:49:34 -0600 Subject: Añadido validador de límite para premios MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Forms/PrizeDTO.cs | 8 ++++++++ Forms/PrizeForm.cs | 1 + 2 files changed, 9 insertions(+) create mode 100644 Forms/PrizeDTO.cs (limited to 'Forms') diff --git a/Forms/PrizeDTO.cs b/Forms/PrizeDTO.cs new file mode 100644 index 0000000..6741567 --- /dev/null +++ b/Forms/PrizeDTO.cs @@ -0,0 +1,8 @@ +namespace BackendPIA.Forms { + public class PrizeDTO { + public long Id { get; set; } + public string Name { get; set; } + public int Tier { get; set; } + public string Category { get; set; } + } +} \ No newline at end of file diff --git a/Forms/PrizeForm.cs b/Forms/PrizeForm.cs index bc955f8..42074ad 100644 --- a/Forms/PrizeForm.cs +++ b/Forms/PrizeForm.cs @@ -7,6 +7,7 @@ namespace BackendPIA.Forms { [Required] [ForeignKey("RaffleId")] [IsNotClosed] + [MaximumWinners] public long RaffleId { get; set; } [Required] public string? Name { get; set; } -- cgit v1.2.3