查询优化

This commit is contained in:
2026-04-23 15:18:39 +08:00
parent 746cb57619
commit c2eeffa0de
16 changed files with 223 additions and 143 deletions
@@ -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);