You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

226 lines
5.9 KiB
Plaintext

11 months ago
using System;
using System.Data;
using BP.DA;
using BP.En;
using BP.Port;
namespace BP.JianYu
{
/// <summary>
/// <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD>
/// </summary>
public class FanrenAttr : EntityNoNameAttr
{
/// <summary>
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// </summary>
public const string BZR = "BZR";
public const string Tel = "Tel";
public const string WorkIDOfBatch = "WorkIDOfBatch";
public const string WorkIDOfSubthread = "WorkIDOfSubthread";
/// <summary>
/// <20>ּ<EFBFBD><D6BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// </summary>
public const string FenJianQuNo = "FenJianQuNo";
/// <summary>
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// </summary>
public const string JianQuNo = "JianQuNo";
/// <summary>
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// </summary>
public const string PrisonNo = "PrisonNo";
}
/// <summary>
/// <20><><EFBFBD><EFBFBD>
/// </summary>
public class Fanren : BP.En.EntityNoName
{
#region <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// <summary>
/// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
/// </summary>
public string FenJianQuNo
{
get
{
return this.GetValStrByKey(FanrenAttr.FenJianQuNo);
}
set
{
this.SetValByKey(FanrenAttr.FenJianQuNo, value);
}
}
public string JianQuNo
{
get
{
return this.GetValStrByKey(FanrenAttr.JianQuNo);
}
set
{
this.SetValByKey(FanrenAttr.JianQuNo, value);
}
}
public string PrisonNo
{
get
{
return this.GetValStrByKey(FanrenAttr.PrisonNo);
}
set
{
this.SetValByKey(FanrenAttr.PrisonNo, value);
}
}
/// <summary>
/// <20><><EFBFBD>߳<EFBFBD>ID.
/// </summary>
public int WorkIDOfSubthread
{
get
{
return this.GetValIntByKey(FanrenAttr.WorkIDOfSubthread);
}
set
{
this.SetValByKey(FanrenAttr.WorkIDOfSubthread, value);
}
}
/// <summary>
/// <20><><EFBFBD><EFBFBD>ID
/// </summary>
public int WorkIDOfBatch
{
get
{
return this.GetValIntByKey(FanrenAttr.WorkIDOfBatch);
}
set
{
this.SetValByKey(FanrenAttr.WorkIDOfBatch, 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>
/// <20><><EFBFBD><EFBFBD>
/// </summary>
public Fanren() { }
public Fanren(string no) : base(no)
{
}
/// <summary>
/// Map
/// </summary>
public override Map EnMap
{
get
{
if (this._enMap != null)
return this._enMap;
Map map = new Map("JY_Fanren", "<22><><EFBFBD><EFBFBD>");
#region <20>ֶ<EFBFBD>
map.AddTBStringPK(FanrenAttr.No, null, "<22><><EFBFBD><EFBFBD>", true, true, 3, 3, 50);
map.AddTBString(FanrenAttr.Name, null, "<22><><EFBFBD><EFBFBD>", true, false, 0, 50, 200);
map.AddDDLEntities(FanrenAttr.PrisonNo, null, "<22><><EFBFBD><EFBFBD>", new Prisons(), false);
map.AddTBInt(FanrenAttr.WorkIDOfBatch, 0, "<22><><EFBFBD>ε<EFBFBD>WorkID", true, false);
map.AddDDLEntities(FanrenAttr.JianQuNo, null, "<22><><EFBFBD><EFBFBD>", new JianQus(), false);
map.AddTBInt(FanrenAttr.WorkIDOfSubthread, 0, "<22><><EFBFBD>߳<EFBFBD>WorkID", true, false);
map.AddDDLEntities(FanrenAttr.FenJianQuNo, null, "<22>ּ<EFBFBD><D6BC><EFBFBD>", new FenJianQus(), false);
#endregion
//<2F><><EFBFBD>ռ<EFBFBD><D5BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ѯ.
map.AddSearchAttr(JianQuAttr.PrisonNo);
//<2F><><EFBFBD><EFBFBD><EFBFBD>в<EFBFBD><D0B2><EFBFBD><EFBFBD>ķ<EFBFBD><C4B7><EFBFBD>.
RefMethod rm = new RefMethod();
rm.Title = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
rm.ClassMethodName = this.ToString() + ".DoFlow";
rm.RefMethodType = RefMethodType.LinkeWinOpen;
rm.IsCanBatch = false; //<2F>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
map.AddRefMethod(rm);
this._enMap = map;
return this._enMap;
}
}
public string DoFlow()
{
return "/WF/MyView.htm?WorkID=" + this.WorkIDOfSubthread+"&FID="+this.WorkIDOfBatch+"&FK_Flow=001";
}
protected override bool beforeInsert()
{
FenJianQu en = new FenJianQu(this.FenJianQuNo);
this.PrisonNo = en.PrisonNo;
this.JianQuNo = en.JianQuNo;
return base.beforeInsert();
}
public override Entities GetNewEntities
{
get { return new Fanrens(); }
}
#endregion
}
/// <summary>
/// <20><><EFBFBD><EFBFBD>s
/// </summary>
public class Fanrens : BP.En.EntitiesNoName
{
#region <20><>д
/// <summary>
/// <20>õ<EFBFBD><C3B5><EFBFBD><EFBFBD><EFBFBD> Entity
/// </summary>
public override Entity GetNewEntity
{
get
{
return new Fanren();
}
}
#endregion
#region <20><><EFBFBD><EFBFBD><ECB7BD>
/// <summary>
/// <20><><EFBFBD><EFBFBD>s
/// </summary>
public Fanrens() { }
#endregion
}
}