去除静态变量Funs.DB
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Model;
|
||||
|
||||
namespace BLL
|
||||
{
|
||||
public static class TestTrainingService
|
||||
{
|
||||
public static Model.SGGLDB db = Funs.DB;
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键获取信息
|
||||
/// </summary>
|
||||
@@ -86,7 +85,7 @@ namespace BLL
|
||||
/// <returns></returns>
|
||||
public static List<Model.Training_TestTraining> GetTestTrainingList()
|
||||
{
|
||||
return (from x in db.Training_TestTraining orderby x.TrainingCode select x).ToList();
|
||||
return (from x in Funs.DB.Training_TestTraining orderby x.TrainingCode select x).ToList();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -95,7 +94,7 @@ namespace BLL
|
||||
/// <returns></returns>
|
||||
public static List<Model.Training_TestTraining> GetEndTestTrainingList()
|
||||
{
|
||||
return (from x in db.Training_TestTraining
|
||||
return (from x in Funs.DB.Training_TestTraining
|
||||
where x.IsEndLever == true
|
||||
orderby x.TrainingCode
|
||||
select x).ToList();
|
||||
|
||||
Reference in New Issue
Block a user