//------------------------------------------------------------------------------ // // This code was generated from a template. // // Manual changes to this file may cause unexpected behavior in your application. // Manual changes to this file will be overwritten if the code is regenerated. // //------------------------------------------------------------------------------ using System.Collections.Generic; namespace EMIS.Entities.HRServices { public class TableKeyDictionary { private static Dictionary items; public static Dictionary Items { get { return items; } } static TableKeyDictionary() { items = new Dictionary(); items.Add("Comm_OrgInfo", "dpid"); items.Add("Comm_Posts", "postid"); items.Add("Comm_Users", "userid"); } public static string GetKeyName(TEntity entity) { string tableName = entity.GetType().Name; return items[tableName]; } public static string GetKeyName() { string tableName = typeof(TEntity).Name; return items[tableName]; } } }