查询优化
This commit is contained in:
@@ -34,11 +34,11 @@ namespace BLL
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.Check_ProjectLeaderCheck> getDataLists = from x in Funs.DB.Check_ProjectLeaderCheck
|
||||
select x;
|
||||
///// <summary>
|
||||
///// 定义变量
|
||||
///// </summary>
|
||||
//private static IQueryable<Model.Check_ProjectLeaderCheck> getDataLists = from x in Funs.DB.Check_ProjectLeaderCheck
|
||||
// select x;
|
||||
|
||||
/// <summary>
|
||||
/// 数据列表
|
||||
@@ -49,7 +49,7 @@ namespace BLL
|
||||
public static IEnumerable getListData(string projectId, string startTime, string endTime, Grid Grid1)
|
||||
{
|
||||
Model.SGGLDB db = Funs.DB;
|
||||
IQueryable<Model.Check_ProjectLeaderCheck> getDataList = getDataLists;
|
||||
IQueryable<Model.Check_ProjectLeaderCheck> getDataList = from x in db.Check_ProjectLeaderCheck select x;
|
||||
if (!string.IsNullOrEmpty(projectId))
|
||||
{
|
||||
getDataList = getDataList.Where(x => x.ProjectId == projectId);
|
||||
|
||||
Reference in New Issue
Block a user