using System; using System.Data; using BP.DA; using BP.En; using BP.Port; namespace BP.Pub { /// /// 年月 /// public class NYAttr : EntityNoNameAttr { #region 基本属性 #endregion } /// /// 年月 /// public class NY : EntityNoName { #region 构造函数 public override UAC HisUAC { get { UAC uac = new UAC(); uac.OpenForSysAdmin(); return uac; } } /// /// 年月 /// public NY() { } public NY(string no) : base(no) { } /// /// Map /// public override Map EnMap { get { if (this._enMap != null) return this._enMap; Map map = new Map("Pub_NY", "年月"); #region 基本属性 map.EnDBUrl = new DBUrl(DBUrlType.AppCenterDSN); map.DepositaryOfMap = Depositary.Application; map.DepositaryOfEntity = Depositary.None; map.setEnType(EnType.App); map.CodeStruct = "4"; #endregion #region 字段 map.AddTBStringPK(NYAttr.No, null, "编号", true, false, 0, 50, 50); map.AddTBString(NYAttr.Name, null, "名称", true, false, 0, 50, 200); #endregion this._enMap = map; return this._enMap; } } public override Entities GetNewEntities { get { return new NYs(); } } #endregion } /// /// 年月 /// public class NYs : EntitiesNoName { #region 年月 /// /// 得到它的 Entity /// public override Entity GetNewEntity { get { return new NY(); } } #endregion #region 构造方法 /// /// 年月s /// public NYs() { } #endregion } }