using APT.Infrastructure.EF.Map;
using ATP.BaseData.Domain.Entities.FM;
using Microsoft.EntityFrameworkCore.Metadata.Builders;

namespace ATP.BaseData.Data.Mapping.FM
{
	public  class FMProcessPlatformFileMap : APTEntityBaseMap<T_FM_PROCESS_PLATFORM_FILE>
	{
		public override void Configure(EntityTypeBuilder<T_FM_PROCESS_PLATFORM_FILE> builder)
		{
			base.Configure(builder);
			builder.HasOne(t => t.Nav_ProcessPlatform).WithMany(t => t.Nav_Files).HasForeignKey(t => t.PROCESS_PLATFORM_ID);
			builder.HasOne(t => t.Nav_ImgFile).WithMany().HasForeignKey(t => t.IMG_FILE_ID);
		} 
	}
}
