using System;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;
using Heroic.AutoMapper;
using InventoryTraker.Web.Core;

namespace InventoryTraker.Web.Models
{
	public class InventoryAddForm : IMapTo<Inventory>
	{
		[HiddenInput(DisplayValue = false)]
		[Required]
		public int InventoryTypeId { get; set; }

		[Required]
		public DateTime ExpirationDate { get; set; }

		[Required, Range(1, int.MaxValue, ErrorMessage = "Quantity must be greater than 0")]
		public int Quantity { get; set; }

		[Required, Display(Name = "Arrival Date")]
		public DateTime AddedDate { get; set; }

		public string Memo { get; set; }
	}
}