Update automapper
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
using System;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Web.Mvc;
|
||||
using Heroic.AutoMapper;
|
||||
using AutoMapper;
|
||||
using InventoryTraker.Web.Core;
|
||||
|
||||
namespace InventoryTraker.Web.Models
|
||||
{
|
||||
public class InventoryAddForm : IMapTo<Inventory>
|
||||
public class InventoryAddForm
|
||||
{
|
||||
[HiddenInput(DisplayValue = false)]
|
||||
[Required]
|
||||
@@ -22,5 +22,13 @@ namespace InventoryTraker.Web.Models
|
||||
public DateTime AddedDate { get; set; }
|
||||
|
||||
public string Memo { get; set; }
|
||||
|
||||
public class AutoMapperProfile : Profile
|
||||
{
|
||||
public AutoMapperProfile()
|
||||
{
|
||||
CreateMap<InventoryAddForm, Inventory>();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user