This commit is contained in:
2026-04-03 18:54:02 +08:00
parent aa7f9f9499
commit 15b3c87ac1
2 changed files with 5 additions and 8 deletions
@@ -18,12 +18,8 @@ namespace BLL
{
get;
set;
}
/// <summary>
/// 定义变量
/// </summary>
private static IQueryable<Model.SitePerson_PersonInOut> getDataLists = from x in Funs.DB.SitePerson_PersonInOut select x;
}
/// <summary>
/// 获取分页列表
@@ -37,7 +33,8 @@ namespace BLL
/// <returns></returns>
public static IEnumerable getListData(string projectId, string unitId, string name, string idCard, string inOutWay, DateTime? startDate, DateTime? endDate, Grid Grid1)
{
IQueryable<Model.SitePerson_PersonInOut> getDataList = getDataLists.Where(x => x.ProjectId == projectId && (inOutWay == "0" || x.InOutWay == inOutWay));
IQueryable<Model.SitePerson_PersonInOut> getDataList = from x in Funs.DB.SitePerson_PersonInOut select x;
getDataList = getDataList.Where(x => x.ProjectId == projectId && (inOutWay == "0" || x.InOutWay == inOutWay));
if (!string.IsNullOrEmpty(unitId) && unitId != Const._Null)
{
getDataList = getDataList.Where(e => e.UnitId == unitId);