using System;
using System.Data;
using BP.DA;
using BP.WF;
using BP.En;
namespace BP.WF
{
///
/// 普通工作
///
public class GEWorkAttr : WorkAttr
{
}
///
/// 普通工作
///
public class GEWork : Work
{
#region 与_SQLCash 操作有关
private SQLCash _SQLCash = null;
public override SQLCash SQLCash
{
get
{
if (_SQLCash == null)
{
_SQLCash = Cash.GetSQL(this.NodeFrmID.ToString());
if (_SQLCash == null)
{
_SQLCash = new SQLCash(this);
Cash.SetSQL(this.NodeFrmID.ToString(), _SQLCash);
}
}
return _SQLCash;
}
set
{
_SQLCash = value;
}
}
#endregion
#region 构造函数
///
/// 普通工作
///
public GEWork()
{
}
///
/// 普通工作
///
/// 节点ID
public GEWork(int nodeid, string nodeFrmID)
{
this.NodeFrmID = nodeFrmID;
this.NodeID = nodeid;
this.SQLCash = null;
}
///
/// 普通工作
///
/// 节点ID
/// OID
public GEWork(int nodeid, string nodeFrmID, Int64 _oid)
{
this.NodeFrmID = nodeFrmID;
this.NodeID = nodeid;
this.OID = _oid;
this.SQLCash = null;
}
#endregion
#region Map
///
/// 重写基类方法
///
public override Map EnMap
{
get
{
//if (this._enMap == null)
this._enMap = BP.Sys.MapData.GenerHisMap(this.NodeFrmID);
return this._enMap;
}
}
///
/// GEWorks
///
public override Entities GetNewEntities
{
get
{
if (this.NodeID == 0)
return new GEWorks();
return new GEWorks(this.NodeID, this.NodeFrmID);
}
}
#endregion
///
/// 重写tostring 返回fromID.
///
///
public override string ToString()
{
return this.NodeFrmID;
}
}
///
/// 普通工作s
///
public class GEWorks : Works
{
#region 重载基类方法
///
/// 节点ID
///
public int NodeID = 0;
#endregion
#region 方法
///
/// 得到它的 Entity
///
public override Entity GetNewEntity
{
get
{
if (this.NodeID == 0)
return new GEWork();
return new GEWork(this.NodeID, this.NodeFrmID);
}
}
///
/// 普通工作ID
///
public GEWorks()
{
}
///
/// 普通工作ID
///
///
public GEWorks(int nodeid, string nodeFrmID)
{
this.NodeID = nodeid;
this.NodeFrmID = nodeFrmID;
}
public string NodeFrmID = "";
#endregion
}
}