去除静态变量Funs.DB
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Model;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
@@ -9,8 +10,6 @@ namespace BLL
|
||||
/// </summary>
|
||||
public static class ProblemAnalysisService
|
||||
{
|
||||
public static Model.SGGLDB db = Funs.DB;
|
||||
|
||||
#region AnalysisColumn
|
||||
/// <summary>
|
||||
/// 统计列
|
||||
@@ -56,7 +55,7 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 安全巡检
|
||||
/// </summary>
|
||||
public static IQueryable<Model.HSSE_Hazard_HazardRegister> getHazardRegisterLists = from x in db.HSSE_Hazard_HazardRegister
|
||||
public static IQueryable<Model.HSSE_Hazard_HazardRegister> getHazardRegisterLists = from x in Funs.DB.HSSE_Hazard_HazardRegister
|
||||
where x.States != Const.State_4 && x.ProjectId != Const.Project_TestProjectId && x.ProjectId != null
|
||||
select x;
|
||||
/// <summary>
|
||||
@@ -163,7 +162,7 @@ namespace BLL
|
||||
}
|
||||
else
|
||||
{
|
||||
var getTypes = from x in db.HSSE_Hazard_HazardRegisterTypes
|
||||
var getTypes = from x in Funs.DB.HSSE_Hazard_HazardRegisterTypes
|
||||
where x.HazardRegisterType == type
|
||||
orderby x.TypeCode
|
||||
select x;
|
||||
@@ -252,7 +251,7 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 隐患整改单
|
||||
/// </summary>
|
||||
public static IQueryable<Model.Check_RectifyNotices> getRectifyNoticesLists = from x in db.Check_RectifyNotices
|
||||
public static IQueryable<Model.Check_RectifyNotices> getRectifyNoticesLists = from x in Funs.DB.Check_RectifyNotices
|
||||
where x.States != Const.State_0 && x.States != null && x.ProjectId != Const.Project_TestProjectId && x.ProjectId != null
|
||||
select x;
|
||||
/// <summary>
|
||||
@@ -409,13 +408,13 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 教育培训
|
||||
/// </summary>
|
||||
public static IQueryable<Model.EduTrain_TrainRecord> getTrainRecordLists = from x in db.EduTrain_TrainRecord
|
||||
public static IQueryable<Model.EduTrain_TrainRecord> getTrainRecordLists = from x in Funs.DB.EduTrain_TrainRecord
|
||||
where x.ProjectId != Const.Project_TestProjectId && x.ProjectId != null
|
||||
select x;
|
||||
/// <summary>
|
||||
/// 教育培训明细
|
||||
/// </summary>
|
||||
public static IQueryable<Model.EduTrain_TrainRecordDetail> getTrainRecordDetailLists = from x in db.EduTrain_TrainRecordDetail
|
||||
public static IQueryable<Model.EduTrain_TrainRecordDetail> getTrainRecordDetailLists = from x in Funs.DB.EduTrain_TrainRecordDetail
|
||||
select x;
|
||||
/// <summary>
|
||||
/// 教育培训统计
|
||||
|
||||
Reference in New Issue
Block a user