18 lines
436 B
C#
18 lines
436 B
C#
|
using System;
|
|||
|
using FluentNHibernate.Conventions;
|
|||
|
using System.Reflection;
|
|||
|
using FluentNHibernate;
|
|||
|
|
|||
|
namespace Tanshu.Accounts.Conventions
|
|||
|
{
|
|||
|
public class CustomForeignKeyConvention : ForeignKeyConvention
|
|||
|
{
|
|||
|
protected override string GetKeyName(Member property, Type type)
|
|||
|
{
|
|||
|
return property == null
|
|||
|
? type.Name + "ID"
|
|||
|
: property.Name + "ID";
|
|||
|
}
|
|||
|
}
|
|||
|
}
|