|
|
|
|
using System;
|
|
|
|
|
using System.Data;
|
|
|
|
|
using BP.DA;
|
|
|
|
|
using BP.En;
|
|
|
|
|
using BP.Port;
|
|
|
|
|
|
|
|
|
|
namespace BP.Demo.BPFramework
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ѧУ <20><><EFBFBD><EFBFBD>
|
|
|
|
|
/// </summary>
|
|
|
|
|
public class SchoolAttr: EntityNoNameAttr
|
|
|
|
|
{
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
/// </summary>
|
|
|
|
|
public const string BZR = "BZR";
|
|
|
|
|
public const string Tel = "Tel";
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ѧУ
|
|
|
|
|
/// </summary>
|
|
|
|
|
public class School :BP.En.EntityNoName
|
|
|
|
|
{
|
|
|
|
|
#region <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
/// </summary>
|
|
|
|
|
public string BZR
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return this.GetValStrByKey(SchoolAttr.BZR);
|
|
|
|
|
}
|
|
|
|
|
set
|
|
|
|
|
{
|
|
|
|
|
this.SetValByKey(SchoolAttr.BZR, value);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region <20><><EFBFBD>캯<EFBFBD><ECBAAF>
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ʵ<><CAB5><EFBFBD><EFBFBD>Ȩ<EFBFBD><EFBFBD><DEBF><EFBFBD>
|
|
|
|
|
/// </summary>
|
|
|
|
|
public override UAC HisUAC
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
UAC uac = new UAC();
|
|
|
|
|
|
|
|
|
|
if (BP.Web.WebUser.No == "zhoupeng" || BP.Web.WebUser.No.Equals("admin")==true)
|
|
|
|
|
{
|
|
|
|
|
uac.IsDelete = true;
|
|
|
|
|
uac.IsUpdate = true;
|
|
|
|
|
uac.IsInsert = true;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
uac.IsDelete = false;
|
|
|
|
|
uac.IsUpdate = false;
|
|
|
|
|
uac.IsInsert = false;
|
|
|
|
|
}
|
|
|
|
|
return uac;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ѧУ
|
|
|
|
|
/// </summary>
|
|
|
|
|
public School(){}
|
|
|
|
|
public School(string no):base(no)
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Map
|
|
|
|
|
/// </summary>
|
|
|
|
|
public override Map EnMap
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
if (this._enMap!=null)
|
|
|
|
|
return this._enMap;
|
|
|
|
|
|
|
|
|
|
Map map = new Map("Demo_School","ѧУ");
|
|
|
|
|
|
|
|
|
|
#region <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|
|
|
|
map.DepositaryOfEntity=Depositary.None; //ʵ<><CAB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>λ<EFBFBD><CEBB>.
|
|
|
|
|
map.IsAllowRepeatName = true;
|
|
|
|
|
map.EnType=EnType.App;
|
|
|
|
|
map.CodeStruct="3"; //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ3λ, <20><>001 <20><> 999 .
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region <20>ֶ<EFBFBD>
|
|
|
|
|
map.AddTBStringPK(SchoolAttr.No, null, "<22><><EFBFBD><EFBFBD>", true, true, 3, 3, 50);
|
|
|
|
|
map.AddTBString(SchoolAttr.Name,null,"<22><><EFBFBD><EFBFBD>",true,false,0,50,200);
|
|
|
|
|
map.AddTBString(SchoolAttr.BZR, null, "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>", true, false, 0, 50, 200);
|
|
|
|
|
map.AddTBString(SchoolAttr.Tel, null, "<22><><EFBFBD><EFBFBD><EFBFBD>ε绰", true, false, 0, 50, 200);
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
this._enMap=map;
|
|
|
|
|
return this._enMap;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
public override Entities GetNewEntities
|
|
|
|
|
{
|
|
|
|
|
get { return new Schools(); }
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
}
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ѧУs
|
|
|
|
|
/// </summary>
|
|
|
|
|
public class Schools : BP.En.EntitiesNoName
|
|
|
|
|
{
|
|
|
|
|
#region <20><>д
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// <20>õ<EFBFBD><C3B5><EFBFBD><EFBFBD><EFBFBD> Entity
|
|
|
|
|
/// </summary>
|
|
|
|
|
public override Entity GetNewEntity
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return new School();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
|
#region <20><><EFBFBD>췽<EFBFBD><ECB7BD>
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// ѧУs
|
|
|
|
|
/// </summary>
|
|
|
|
|
public Schools(){}
|
|
|
|
|
#endregion
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|