11
This commit is contained in:
@@ -45,7 +45,10 @@ namespace BLL
|
||||
public static IEnumerable getListData(string projectId, string checkMan, string type, string workAreaName, string responsibilityUnitName, DateTime? startTime, DateTime? endTime, DateTime? startRectificationTime, DateTime? endRectificationTime
|
||||
, string states, string personId, string unitId, Grid Grid1)
|
||||
{
|
||||
IQueryable<Model.View_Hazard_HazardRegisterList> getDataList = getDataLists;
|
||||
var db= Funs.DB;
|
||||
IQueryable<Model.View_Hazard_HazardRegisterList> getDataList = from x in db.View_Hazard_HazardRegisterList
|
||||
where x.ProblemTypes == "1"
|
||||
select x;
|
||||
if (!string.IsNullOrEmpty(projectId))
|
||||
{
|
||||
getDataList = getDataList.Where(e => e.ProjectId == projectId);
|
||||
@@ -101,7 +104,7 @@ namespace BLL
|
||||
return null;
|
||||
}
|
||||
getDataList = SortConditionHelper.SortingAndPaging(getDataList, Grid1.SortField, Grid1.SortDirection, Grid1.PageIndex, Grid1.PageSize);
|
||||
return from x in getDataList
|
||||
return (from x in getDataList
|
||||
select new
|
||||
{
|
||||
x.HazardRegisterId,
|
||||
@@ -122,7 +125,7 @@ namespace BLL
|
||||
x.CheckManName,
|
||||
x.RegisterDate,
|
||||
x.StatesStr,
|
||||
};
|
||||
}).ToList();
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
@@ -19,12 +19,8 @@ namespace BLL
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.SitePerson_PersonInOut> getDataLists = from x in Funs.DB.SitePerson_PersonInOut select x;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 获取分页列表
|
||||
@@ -38,7 +34,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);
|
||||
|
||||
@@ -17,11 +17,6 @@ namespace BLL
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.SitePerson_PersonItem> getDataLists = from x in Funs.DB.SitePerson_PersonItem select x;
|
||||
|
||||
/// <summary>
|
||||
/// 获取分页列表
|
||||
/// </summary>
|
||||
@@ -36,6 +31,8 @@ namespace BLL
|
||||
/// <returns></returns>
|
||||
public static IEnumerable getListData(string projectId, string unitId, string personId, string name, string idCard, DateTime? startDate, DateTime? endDate, Grid Grid1)
|
||||
{
|
||||
Model.SGGLDB db = Funs.DB;
|
||||
var getDataLists = from x in db.SitePerson_PersonItem select x;
|
||||
IQueryable<Model.SitePerson_PersonItem> getDataList = getDataLists.Where(e => e.PersonId == personId);
|
||||
if (!string.IsNullOrEmpty(projectId) && projectId != Const._Null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user