main
|
Last change
on this file since d2eccb3 was d2eccb3, checked in by mmilevski <markomilevski3@…>, 4 weeks ago |
|
Minor fixes.
|
-
Property mode
set to
100644
|
|
File size:
858 bytes
|
| Line | |
|---|
| 1 | using System.ComponentModel.DataAnnotations;
|
|---|
| 2 | using KernelRecordsMVC.Domain.Enums;
|
|---|
| 3 | namespace KernelRecordsMVC.Application.ViewModels;
|
|---|
| 4 |
|
|---|
| 5 | public class EditProductViewModel
|
|---|
| 6 | {
|
|---|
| 7 | public long ProductId { get; set; }
|
|---|
| 8 |
|
|---|
| 9 | public long ReleaseId { get; set; }
|
|---|
| 10 |
|
|---|
| 11 | public string ReleaseTitle { get; set; } = null!;
|
|---|
| 12 |
|
|---|
| 13 | public ProductFormat Format { get; set; }
|
|---|
| 14 |
|
|---|
| 15 | [Required]
|
|---|
| 16 | [Range(0.01, 100000)]
|
|---|
| 17 | public decimal Price { get; set; }
|
|---|
| 18 |
|
|---|
| 19 | [Required]
|
|---|
| 20 | [Display(Name = "Product Description")]
|
|---|
| 21 | public string ProductDescription { get; set; } = null!;
|
|---|
| 22 |
|
|---|
| 23 | [Required]
|
|---|
| 24 | [Range(0, long.MaxValue)]
|
|---|
| 25 | public long Stock { get; set; }
|
|---|
| 26 |
|
|---|
| 27 | [Display(Name = "Discount (%)")]
|
|---|
| 28 | [Range(0, 100)]
|
|---|
| 29 | public decimal? Discount { get; set; }
|
|---|
| 30 |
|
|---|
| 31 | [Required]
|
|---|
| 32 | [Display(Name = "Modification Type")]
|
|---|
| 33 | public ModificationType ModificationType { get; set; }
|
|---|
| 34 | } |
|---|
Note:
See
TracBrowser
for help on using the repository browser.