namespace GridValidationSampleRazor.Models
{
    using System.ComponentModel.DataAnnotations;

    public class ProductsViewModel
    {
        [Required]
        public int ProductID { get; set; }

        [Required]
        [StringLength(80)]
        public string ProductName { get; set; }

        [Required]
        [DataType(DataType.Currency)]
        [Range(1, 100)]
        public decimal? UnitPrice { get; set; }

        public bool Discontinued { get; set; }

        [Required]
        [UIHint("Category")]
        [Display(Name = "Category")]
        public string CategoryID { get; set; }
    }
}