2015-01-06 15:36:14 +11:00
|
|
|
using AutoMapper;
|
|
|
|
|
using Umbraco.Core;
|
|
|
|
|
using Umbraco.Core.Models;
|
|
|
|
|
using Umbraco.Core.Models.Mapping;
|
|
|
|
|
using Relation = Umbraco.Web.Models.ContentEditing.Relation;
|
|
|
|
|
using RelationType = Umbraco.Web.Models.ContentEditing.RelationType;
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web.Models.Mapping
|
|
|
|
|
{
|
2016-03-22 16:29:04 +01:00
|
|
|
internal class RelationModelMapper : ModelMapperConfiguration
|
2015-01-06 15:36:14 +11:00
|
|
|
{
|
2016-03-22 16:29:04 +01:00
|
|
|
public override void ConfigureMappings(IMapperConfiguration config, ApplicationContext applicationContext)
|
2015-01-06 15:36:14 +11:00
|
|
|
{
|
|
|
|
|
//FROM IRelationType TO RelationType
|
|
|
|
|
config.CreateMap<IRelationType, RelationType>();
|
|
|
|
|
|
|
|
|
|
//FROM IRelation TO Relation
|
|
|
|
|
config.CreateMap<IRelation, Relation>();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|