summaryrefslogtreecommitdiff
path: root/Gestor.Infrastructure/Gestor.Infrastructure.Mappings.Configuracoes/ConfiguracaoSistemaMap.cs
blob: 8c66a19e1d274ca0ab6b77a67a774de329b61667 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
using FluentNHibernate.Mapping;
using Gestor.Infrastructure.Entities.Configuracoes;
using Gestor.Infrastructure.Entities.Generic;
using System;
using System.Linq.Expressions;
using System.Runtime.CompilerServices;

namespace Gestor.Infrastructure.Mappings.Configuracoes
{
	public class ConfiguracaoSistemaMap : ClassMap<ConfiguracaoSistemaDb>
	{
		public ConfiguracaoSistemaMap()
		{
			base.Table("ConfigSistema");
			base.LazyLoad();
			base.Id((ConfiguracaoSistemaDb x) => (object)x.Id).GeneratedBy.Identity().Column("Id");
			base.Map((ConfiguracaoSistemaDb x) => (object)x.Configuracao).CustomType<Configuracao>().Column("codigo").Not.Nullable();
		}
	}
}