/**  版本信息模板在安装目录下，可自行修改。
* T_IntegratedScheduling_Base.cs
*
* 功 能： N/A
* 类 名： T_IntegratedScheduling_Base
*
* Ver    变更日期             负责人  变更内容
* ───────────────────────────────────
* V0.01  2022/10/19 11:12:17   N/A    初版
*
* Copyright (c) 2012 Maticsoft Corporation. All rights reserved.
*┌──────────────────────────────────┐
*│　此技术信息为本公司机密信息，未经本公司书面同意禁止向第三方披露．　│
*│　版权所有：动软卓越（北京）科技有限公司　　　　　　　　　　　　　　│
*└──────────────────────────────────┘
*/
using System;
using System.Data;
using System.Text;
using System.Data.SqlClient;
 
using RMYY_CallCenter_Api.DB;

namespace RMYY_CallCenter_Api.DAL
{
	/// <summary>
	/// 数据访问类:T_IntegratedScheduling_Base
	/// </summary>
	public partial class T_IntegratedScheduling_Base
	{
		public T_IntegratedScheduling_Base()
		{}
		#region  BasicMethod

		/// <summary>
		/// 得到最大ID
		/// </summary>
		public int GetMaxId()
		{
		return DbHelperSQL.GetMaxID("F_WorkOrderId", "T_IntegratedScheduling_Base"); 
		}

		/// <summary>
		/// 是否存在该记录
		/// </summary>
		public bool Exists(int F_WorkOrderId)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("select count(1) from T_IntegratedScheduling_Base");
			strSql.Append(" where F_WorkOrderId=@F_WorkOrderId");
			SqlParameter[] parameters = {
					new SqlParameter("@F_WorkOrderId", SqlDbType.Int,4)
			};
			parameters[0].Value = F_WorkOrderId;

			return DbHelperSQL.Exists(strSql.ToString(),parameters);
		}


		/// <summary>
		/// 增加一条数据
		/// </summary>
		public int Add(RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base model)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("insert into T_IntegratedScheduling_Base(");
			strSql.Append("F_WorkOrderCode,F_WorkOrderCategory,F_Content,F_Applicant,F_ApplicationDept,F_Phone,F_Location,F_ToPlace,F_WorkOrderState,F_DealMan,F_DealDept,F_ReplayCount,F_RemindCount,F_CallId,F_CallRecordId,F_AssignTime,F_AssignUser,F_Endtime,F_Deadline,F_UpdateTime,F_CreateTime,F_CreateUser,F_CreateUserDept,F_File,F_IsDelete,F_LeaveRecordId,F_CFNum,F_EmergencyTypes)");
			strSql.Append(" values (");
			strSql.Append("@F_WorkOrderCode,@F_WorkOrderCategory,@F_Content,@F_Applicant,@F_ApplicationDept,@F_Phone,@F_Location,@F_ToPlace,@F_WorkOrderState,@F_DealMan,@F_DealDept,@F_ReplayCount,@F_RemindCount,@F_CallId,@F_CallRecordId,@F_AssignTime,@F_AssignUser,@F_Endtime,@F_Deadline,@F_UpdateTime,@F_CreateTime,@F_CreateUser,@F_CreateUserDept,@F_File,@F_IsDelete,@F_LeaveRecordId,@F_CFNum,@F_EmergencyTypes)");
			strSql.Append(";select @@IDENTITY");
			SqlParameter[] parameters = {
					new SqlParameter("@F_WorkOrderCode", SqlDbType.NVarChar,100),
					new SqlParameter("@F_WorkOrderCategory", SqlDbType.NVarChar,100),
					new SqlParameter("@F_Content", SqlDbType.NVarChar,1000),
					new SqlParameter("@F_Applicant", SqlDbType.NVarChar,50),
					new SqlParameter("@F_ApplicationDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Phone", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Location", SqlDbType.NVarChar,200),
					new SqlParameter("@F_ToPlace", SqlDbType.NVarChar,200),
					new SqlParameter("@F_WorkOrderState", SqlDbType.Int,4),
					new SqlParameter("@F_DealMan", SqlDbType.NVarChar,20),
					new SqlParameter("@F_DealDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_ReplayCount", SqlDbType.Int,4),
					new SqlParameter("@F_RemindCount", SqlDbType.Int,4),
					new SqlParameter("@F_CallId", SqlDbType.NVarChar,50),
					new SqlParameter("@F_CallRecordId", SqlDbType.Int,4),
					new SqlParameter("@F_AssignTime", SqlDbType.DateTime),
					new SqlParameter("@F_AssignUser", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Endtime", SqlDbType.DateTime),
					new SqlParameter("@F_Deadline", SqlDbType.DateTime),
					new SqlParameter("@F_UpdateTime", SqlDbType.DateTime),
					new SqlParameter("@F_CreateTime", SqlDbType.DateTime),
					new SqlParameter("@F_CreateUser", SqlDbType.NVarChar,20),
					new SqlParameter("@F_CreateUserDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_File", SqlDbType.NVarChar,500),
					new SqlParameter("@F_IsDelete", SqlDbType.Int,4),
                    
                    new SqlParameter("@F_LeaveRecordId", SqlDbType.Int,4),
                 new SqlParameter("@F_EmergencyTypes", SqlDbType.NVarChar,50),   
            new SqlParameter("@F_CFNum", SqlDbType.Int,4)
            };
			parameters[0].Value = model.F_WorkOrderCode;
			parameters[1].Value = model.F_WorkOrderCategory;
			parameters[2].Value = model.F_Content;
			parameters[3].Value = model.F_Applicant;
			parameters[4].Value = model.F_ApplicationDept;
			parameters[5].Value = model.F_Phone;
			parameters[6].Value = model.F_Location;
			parameters[7].Value = model.F_ToPlace;
			parameters[8].Value = model.F_WorkOrderState;
			parameters[9].Value = model.F_DealMan;
			parameters[10].Value = model.F_DealDept;
			parameters[11].Value = model.F_ReplayCount;
			parameters[12].Value = model.F_RemindCount;
			parameters[13].Value = model.F_CallId;
			parameters[14].Value = model.F_CallRecordId;
			parameters[15].Value = model.F_AssignTime;
			parameters[16].Value = model.F_AssignUser;
			parameters[17].Value = model.F_Endtime;
			parameters[18].Value = model.F_Deadline;
			parameters[19].Value = model.F_UpdateTime;
			parameters[20].Value = model.F_CreateTime;
			parameters[21].Value = model.F_CreateUser;
			parameters[22].Value = model.F_CreateUserDept;
			parameters[23].Value = model.F_File;
			parameters[24].Value = model.F_IsDelete;
            parameters[25].Value = model.F_LeaveRecordId;
            parameters[26].Value = model.F_EmergencyTypes;

            parameters[27].Value = model.F_CFNum;

            object obj = DbHelperSQL.GetSingle(strSql.ToString(),parameters);
			if (obj == null)
			{
				return 0;
			}
			else
			{
				return Convert.ToInt32(obj);
			}
		}
		/// <summary>
		/// 更新一条数据
		/// </summary>
		public bool Update(RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base model)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("update T_IntegratedScheduling_Base set ");
			strSql.Append("F_WorkOrderCode=@F_WorkOrderCode,");
			strSql.Append("F_WorkOrderCategory=@F_WorkOrderCategory,");
			strSql.Append("F_Content=@F_Content,");
			strSql.Append("F_Applicant=@F_Applicant,");
			strSql.Append("F_ApplicationDept=@F_ApplicationDept,");
			strSql.Append("F_Phone=@F_Phone,");
			strSql.Append("F_Location=@F_Location,");
			strSql.Append("F_ToPlace=@F_ToPlace,");
			strSql.Append("F_WorkOrderState=@F_WorkOrderState,");
			strSql.Append("F_DealMan=@F_DealMan,");
			strSql.Append("F_DealDept=@F_DealDept,");
			strSql.Append("F_ReplayCount=@F_ReplayCount,");
			strSql.Append("F_RemindCount=@F_RemindCount,");
			strSql.Append("F_CallId=@F_CallId,");
			strSql.Append("F_CallRecordId=@F_CallRecordId,");
			strSql.Append("F_AssignTime=@F_AssignTime,");
			strSql.Append("F_AssignUser=@F_AssignUser,");
			strSql.Append("F_Endtime=@F_Endtime,");
			strSql.Append("F_Deadline=@F_Deadline,");
			strSql.Append("F_UpdateTime=@F_UpdateTime,");
			strSql.Append("F_CreateTime=@F_CreateTime,");
			strSql.Append("F_CreateUser=@F_CreateUser,");
			strSql.Append("F_CreateUserDept=@F_CreateUserDept,");
			strSql.Append("F_File=@F_File,");
			strSql.Append("F_IsDelete=@F_IsDelete,");
            strSql.Append("F_Score=@F_Score,");
            strSql.Append("MYD=@MYD,");
            strSql.Append("F_AcceptTime=@F_AcceptTime,");
            strSql.Append("F_EmergencyTypes=@F_EmergencyTypes,");

            strSql.Append("F_CollectFile=@F_CollectFile,");
            strSql.Append("F_CollectTime=@F_CollectTime,");

            strSql.Append("F_CFNum=@F_CFNum");
            



            strSql.Append(" where F_WorkOrderId=@F_WorkOrderId");
			SqlParameter[] parameters = {
					new SqlParameter("@F_WorkOrderCode", SqlDbType.NVarChar,100),
					new SqlParameter("@F_WorkOrderCategory", SqlDbType.NVarChar,100),
					new SqlParameter("@F_Content", SqlDbType.NVarChar,1000),
					new SqlParameter("@F_Applicant", SqlDbType.NVarChar,50),
					new SqlParameter("@F_ApplicationDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Phone", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Location", SqlDbType.NVarChar,200),
					new SqlParameter("@F_ToPlace", SqlDbType.NVarChar,200),
					new SqlParameter("@F_WorkOrderState", SqlDbType.Int,4),
					new SqlParameter("@F_DealMan", SqlDbType.NVarChar,20),
					new SqlParameter("@F_DealDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_ReplayCount", SqlDbType.Int,4),
					new SqlParameter("@F_RemindCount", SqlDbType.Int,4),
					new SqlParameter("@F_CallId", SqlDbType.NVarChar,50),
					new SqlParameter("@F_CallRecordId", SqlDbType.Int,4),
					new SqlParameter("@F_AssignTime", SqlDbType.DateTime),
					new SqlParameter("@F_AssignUser", SqlDbType.NVarChar,20),
					new SqlParameter("@F_Endtime", SqlDbType.DateTime),
					new SqlParameter("@F_Deadline", SqlDbType.DateTime),
					new SqlParameter("@F_UpdateTime", SqlDbType.DateTime),
					new SqlParameter("@F_CreateTime", SqlDbType.DateTime),
					new SqlParameter("@F_CreateUser", SqlDbType.NVarChar,20),
					new SqlParameter("@F_CreateUserDept", SqlDbType.NVarChar,20),
					new SqlParameter("@F_File", SqlDbType.NVarChar,500),
					new SqlParameter("@F_IsDelete", SqlDbType.Int,4),
                    new SqlParameter("@F_Score", SqlDbType.Int,4),
                       new SqlParameter("@MYD", SqlDbType.Int,4),
                    new SqlParameter("@F_AcceptTime", SqlDbType.DateTime),
                      new SqlParameter("@F_EmergencyTypes", SqlDbType.NVarChar,50) ,
new SqlParameter("@F_CollectFile", SqlDbType.NVarChar,500),
 new SqlParameter("@F_CollectTime", SqlDbType.DateTime),


            new SqlParameter("@F_CFNum", SqlDbType.Int,4),
                    

                    new SqlParameter("@F_WorkOrderId", SqlDbType.Int,4)};
			parameters[0].Value = model.F_WorkOrderCode;
			parameters[1].Value = model.F_WorkOrderCategory;
			parameters[2].Value = model.F_Content;
			parameters[3].Value = model.F_Applicant;
			parameters[4].Value = model.F_ApplicationDept;
			parameters[5].Value = model.F_Phone;
			parameters[6].Value = model.F_Location;
			parameters[7].Value = model.F_ToPlace;
			parameters[8].Value = model.F_WorkOrderState;
			parameters[9].Value = model.F_DealMan;
			parameters[10].Value = model.F_DealDept;
			parameters[11].Value = model.F_ReplayCount;
			parameters[12].Value = model.F_RemindCount;
			parameters[13].Value = model.F_CallId;
			parameters[14].Value = model.F_CallRecordId;
			parameters[15].Value = model.F_AssignTime;
			parameters[16].Value = model.F_AssignUser;
			parameters[17].Value = model.F_Endtime;
			parameters[18].Value = model.F_Deadline;
			parameters[19].Value = model.F_UpdateTime;
			parameters[20].Value = model.F_CreateTime;
			parameters[21].Value = model.F_CreateUser;
			parameters[22].Value = model.F_CreateUserDept;
			parameters[23].Value = model.F_File;
			parameters[24].Value = model.F_IsDelete;

            parameters[25].Value = model.F_Score;
            parameters[26].Value = model.MYD;
            parameters[27].Value = model.F_AcceptTime;
            parameters[28].Value = model.F_EmergencyTypes;
       

            parameters[29].Value = model.F_CollectFile;
            parameters[30].Value = model.F_CollectTime;

            parameters[31].Value = model.F_CFNum;
            parameters[32].Value = model.F_WorkOrderId;

			int rows=DbHelperSQL.ExecuteSql(strSql.ToString(),parameters);
			if (rows > 0)
			{
				return true;
			}
			else
			{
				return false;
			}
		}

		/// <summary>
		/// 删除一条数据
		/// </summary>
		public bool Delete(int F_WorkOrderId)
		{
			
			StringBuilder strSql=new StringBuilder();
			strSql.Append("delete from T_IntegratedScheduling_Base ");
			strSql.Append(" where F_WorkOrderId=@F_WorkOrderId");
			SqlParameter[] parameters = {
					new SqlParameter("@F_WorkOrderId", SqlDbType.Int,4)
			};
			parameters[0].Value = F_WorkOrderId;

			int rows=DbHelperSQL.ExecuteSql(strSql.ToString(),parameters);
			if (rows > 0)
			{
				return true;
			}
			else
			{
				return false;
			}
		}
		/// <summary>
		/// 批量删除数据
		/// </summary>
		public bool DeleteList(string F_WorkOrderIdlist )
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("delete from T_IntegratedScheduling_Base ");
			strSql.Append(" where F_WorkOrderId in ("+F_WorkOrderIdlist + ")  ");
			int rows=DbHelperSQL.ExecuteSql(strSql.ToString());
			if (rows > 0)
			{
				return true;
			}
			else
			{
				return false;
			}
		}


		/// <summary>
		/// 得到一个对象实体
		/// </summary>
		public RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base GetModel(string F_WorkOrderCode)
		{
			
			StringBuilder strSql=new StringBuilder();
			strSql.Append("select  top 1 *  from T_IntegratedScheduling_Base ");
			strSql.Append(" where F_WorkOrderCode=@F_WorkOrderCode");
			SqlParameter[] parameters = {
					new SqlParameter("@F_WorkOrderCode",SqlDbType.NVarChar,100)
			};
			parameters[0].Value = F_WorkOrderCode;

			RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base model=new RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base();
			DataSet ds=DbHelperSQL.Query(strSql.ToString(),parameters);
			if(ds.Tables[0].Rows.Count>0)
			{
				return DataRowToModel(ds.Tables[0].Rows[0]);
			}
			else
			{
				return null;
			}
		}


		/// <summary>
		/// 得到一个对象实体
		/// </summary>
		public RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base DataRowToModel(DataRow row)
		{
			RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base model=new RMYY_CallCenter_Api.Model.T_IntegratedScheduling_Base();
			if (row != null)
			{
                if (row["F_CollectTime"] != null && row["F_CollectTime"].ToString() != "")
                {
                    model.F_CollectTime = DateTime.Parse(row["F_CollectTime"].ToString());
                }
            
              if (row["F_CollectFile"] != null)
                {
                    model.F_CollectFile = row["F_CollectFile"].ToString();
                }


                if (row["F_WorkOrderId"]!=null && row["F_WorkOrderId"].ToString()!="")
				{
					model.F_WorkOrderId=int.Parse(row["F_WorkOrderId"].ToString());
				}

                if (row["F_EmergencyTypes"] != null)
                {
                    model.F_EmergencyTypes = row["F_EmergencyTypes"].ToString();
                }

                if (row["F_WorkOrderCode"]!=null)
				{
					model.F_WorkOrderCode=row["F_WorkOrderCode"].ToString();
				}
				if(row["F_WorkOrderCategory"]!=null)
				{
					model.F_WorkOrderCategory=row["F_WorkOrderCategory"].ToString();
				}
				if(row["F_Content"]!=null)
				{
					model.F_Content=row["F_Content"].ToString();
				}
				if(row["F_Applicant"]!=null)
				{
					model.F_Applicant=row["F_Applicant"].ToString();
				}
				if(row["F_ApplicationDept"]!=null)
				{
					model.F_ApplicationDept=row["F_ApplicationDept"].ToString();
				}
				if(row["F_Phone"]!=null)
				{
					model.F_Phone=row["F_Phone"].ToString();
				}
				if(row["F_Location"]!=null)
				{
					model.F_Location=row["F_Location"].ToString();
				}
				if(row["F_ToPlace"]!=null)
				{
					model.F_ToPlace=row["F_ToPlace"].ToString();
				}
				if(row["F_WorkOrderState"]!=null && row["F_WorkOrderState"].ToString()!="")
				{
					model.F_WorkOrderState=int.Parse(row["F_WorkOrderState"].ToString());
				}
				if(row["F_DealMan"]!=null)
				{
					model.F_DealMan=row["F_DealMan"].ToString();
				}
				if(row["F_DealDept"]!=null)
				{
					model.F_DealDept=row["F_DealDept"].ToString();
				}
				if(row["F_ReplayCount"]!=null && row["F_ReplayCount"].ToString()!="")
				{
					model.F_ReplayCount=int.Parse(row["F_ReplayCount"].ToString());
				}
				if(row["F_RemindCount"]!=null && row["F_RemindCount"].ToString()!="")
				{
					model.F_RemindCount=int.Parse(row["F_RemindCount"].ToString());
				}
				if(row["F_CallId"]!=null)
				{
					model.F_CallId=row["F_CallId"].ToString();
				}
               
                    if (row["F_CallRecordId"]!=null && row["F_CallRecordId"].ToString() != "")
				{
					 
                    model.F_CallRecordId = int.Parse(row["F_CallRecordId"].ToString());
                }
				if(row["F_AssignTime"]!=null && row["F_AssignTime"].ToString()!="")
				{
					model.F_AssignTime=DateTime.Parse(row["F_AssignTime"].ToString());
				}
				if(row["F_AssignUser"]!=null)
				{
					model.F_AssignUser=row["F_AssignUser"].ToString();
				}
                if (row["F_AcceptTime"] != null && row["F_AcceptTime"].ToString() != "")
                {
                    model.F_AcceptTime = DateTime.Parse(row["F_AcceptTime"].ToString());
                }
                if (row["F_Endtime"]!=null && row["F_Endtime"].ToString()!="")
				{
					model.F_Endtime=DateTime.Parse(row["F_Endtime"].ToString());
				}
				if(row["F_Deadline"]!=null && row["F_Deadline"].ToString()!="")
				{
					model.F_Deadline=DateTime.Parse(row["F_Deadline"].ToString());
				}
				if(row["F_UpdateTime"]!=null && row["F_UpdateTime"].ToString()!="")
				{
					model.F_UpdateTime=DateTime.Parse(row["F_UpdateTime"].ToString());
				}
				if(row["F_CreateTime"]!=null && row["F_CreateTime"].ToString()!="")
				{
					model.F_CreateTime=DateTime.Parse(row["F_CreateTime"].ToString());
				}
				if(row["F_CreateUser"]!=null)
				{
					model.F_CreateUser=row["F_CreateUser"].ToString();
				}
				if(row["F_CreateUserDept"]!=null)
				{
					model.F_CreateUserDept=row["F_CreateUserDept"].ToString();
				}
				if(row["F_File"]!=null)
				{
					model.F_File=row["F_File"].ToString();
				}
				if(row["F_IsDelete"]!=null && row["F_IsDelete"].ToString()!="")
				{
					model.F_IsDelete=int.Parse(row["F_IsDelete"].ToString());
				}
                if (row["F_LeaveRecordId"] != null && row["F_LeaveRecordId"].ToString() != "")
                {
                    model.F_LeaveRecordId = int.Parse(row["F_LeaveRecordId"].ToString());
                }
                

            }
			return model;
		}

		/// <summary>
		/// 获得数据列表
		/// </summary>
		public DataSet GetList(string strWhere)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("select *");
			strSql.Append(" FROM T_IntegratedScheduling_Base ");
			if(strWhere.Trim()!="")
			{
				strSql.Append(" where "+strWhere);
			}
			return DbHelperSQL.Query(strSql.ToString());
		}

		/// <summary>
		/// 获得前几行数据
		/// </summary>
		public DataSet GetList(int Top,string strWhere,string filedOrder)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("select ");
			if(Top>0)
			{
				strSql.Append(" top "+Top.ToString());
			}
			strSql.Append(" F_WorkOrderId,F_WorkOrderCode,F_WorkOrderCategory,F_Content,F_Applicant,F_ApplicationDept,F_Phone,F_Location,F_ToPlace,F_WorkOrderState,F_DealMan,F_DealDept,F_ReplayCount,F_RemindCount,F_CallId,F_CallRecordId,F_AssignTime,F_AssignUser,F_Endtime,F_Deadline,F_UpdateTime,F_CreateTime,F_CreateUser,F_CreateUserDept,F_File,F_IsDelete,F_LeaveRecordId,F_AcceptTime,F_EmergencyTypes ,F_CollectTime,F_CollectFile");
			strSql.Append(" FROM T_IntegratedScheduling_Base ");
			if(strWhere.Trim()!="")
			{
				strSql.Append(" where "+strWhere);
			}
			strSql.Append(" order by " + filedOrder);
			return DbHelperSQL.Query(strSql.ToString());
		}

		/// <summary>
		/// 获取记录总数
		/// </summary>
		public int GetRecordCount(string strWhere)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("select count(1) FROM T_IntegratedScheduling_Base ");
			if(strWhere.Trim()!="")
			{
				strSql.Append(" where "+strWhere);
			}
			object obj = DbHelperSQL.GetSingle(strSql.ToString());
			if (obj == null)
			{
				return 0;
			}
			else
			{
				return Convert.ToInt32(obj);
			}
		}
		/// <summary>
		/// 分页获取数据列表
		/// </summary>
		public DataSet GetListByPage(string strWhere, string orderby, int startIndex, int endIndex)
		{
			StringBuilder strSql=new StringBuilder();
			strSql.Append("SELECT * FROM ( ");
			strSql.Append(" SELECT ROW_NUMBER() OVER (");
			if (!string.IsNullOrEmpty(orderby.Trim()))
			{
				strSql.Append("order by T." + orderby );
			}
			else
			{
				strSql.Append("order by T.F_WorkOrderId desc");
			}
			strSql.Append(")AS Row, T.*  from T_IntegratedScheduling_Base T ");
			if (!string.IsNullOrEmpty(strWhere.Trim()))
			{
				strSql.Append(" WHERE " + strWhere);
			}
			strSql.Append(" ) TT");
			strSql.AppendFormat(" WHERE TT.Row between {0} and {1}", startIndex, endIndex);
			return DbHelperSQL.Query(strSql.ToString());
		}

	 

		#endregion  BasicMethod
		#region  ExtensionMethod

		#endregion  ExtensionMethod
	}
}

