去除静态变量Funs.DB
This commit is contained in:
@@ -17,8 +17,6 @@ namespace BLL
|
||||
/// </summary>
|
||||
public static class SitePerson_PersonService
|
||||
{
|
||||
public static Model.SGGLDB db = Funs.DB;
|
||||
|
||||
#region 劳务人员列表
|
||||
/// <summary>
|
||||
/// 记录数
|
||||
@@ -101,7 +99,7 @@ namespace BLL
|
||||
x.WorkPostId,
|
||||
x.WorkPostName,
|
||||
x.ProjectId,
|
||||
ProjectName = db.Base_Project.First(u => u.ProjectId == x.ProjectId).ShortName,
|
||||
ProjectName = Funs.DB.Base_Project.First(u => u.ProjectId == x.ProjectId).ShortName,
|
||||
NativePlace = x.CountryName ?? "" + x.ProvinceName ?? "",
|
||||
x.TeamGroupId,
|
||||
x.TeamGroupName,
|
||||
@@ -126,7 +124,7 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.SitePerson_Person> getInPersonLists = from x in db.SitePerson_Person
|
||||
private static IQueryable<Model.SitePerson_Person> getInPersonLists = from x in Funs.DB.SitePerson_Person
|
||||
where x.States == Const.ProjectPersonStates_1
|
||||
select x;
|
||||
|
||||
@@ -173,7 +171,7 @@ namespace BLL
|
||||
x.CardNo,
|
||||
x.PersonName,
|
||||
x.UnitId,
|
||||
db.Base_Unit.First(u => u.UnitId == x.UnitId).UnitName,
|
||||
Funs.DB.Base_Unit.First(u => u.UnitId == x.UnitId).UnitName,
|
||||
x.IdentityCard,
|
||||
IsInName = "",
|
||||
InOuDate = DateTime.Now.ToShortDateString(),
|
||||
@@ -195,7 +193,7 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.SitePerson_PersonInOutNow> getNowPersonLists = from x in db.SitePerson_PersonInOutNow
|
||||
private static IQueryable<Model.SitePerson_PersonInOutNow> getNowPersonLists = from x in Funs.DB.SitePerson_PersonInOutNow
|
||||
select x;
|
||||
|
||||
/// <summary>
|
||||
@@ -262,7 +260,7 @@ namespace BLL
|
||||
x.PersonId,
|
||||
x.personName,
|
||||
x.identityCard,
|
||||
CardNo =db.SitePerson_Person.First(p=>p.PersonId == x.PersonId && p.ProjectId ==x.ProjectId).CardNo,
|
||||
CardNo =Funs.DB.SitePerson_Person.First(p=>p.PersonId == x.PersonId && p.ProjectId ==x.ProjectId).CardNo,
|
||||
x.UnitName,
|
||||
x.UnitId,
|
||||
x.WorkPostId,
|
||||
|
||||
Reference in New Issue
Block a user