查询优化
This commit is contained in:
@@ -20,10 +20,10 @@ namespace BLL
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.DataBase_DataTypeProject> qq = from x in Funs.DB.DataBase_DataTypeProject orderby x.SortIndex select x;
|
||||
///// <summary>
|
||||
///// 定义变量
|
||||
///// </summary>
|
||||
//private static IQueryable<Model.DataBase_DataTypeProject> qq = from x in Funs.DB.DataBase_DataTypeProject orderby x.SortIndex select x;
|
||||
|
||||
/// <summary>
|
||||
/// 获取项目列表
|
||||
@@ -35,7 +35,7 @@ namespace BLL
|
||||
/// <returns></returns>
|
||||
public static IEnumerable getListData(int startRowIndex, int maximumRows)
|
||||
{
|
||||
IQueryable<Model.DataBase_DataTypeProject> q = qq;
|
||||
IQueryable<Model.DataBase_DataTypeProject> q = from x in Funs.DB.DataBase_DataTypeProject orderby x.SortIndex select x;
|
||||
count = q.Count();
|
||||
if (count == 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user