20240523 菜单精简
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
using FineUIPro;
|
||||
using Model;
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Linq;
|
||||
@@ -22,7 +23,7 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.Bo_Sheng_Unit> getUnits = from x in db.Bo_Sheng_Unit
|
||||
private static IQueryable<Model.Bo_Sheng_Unit> getUnits = from x in db.Bo_Sheng_Unit
|
||||
where (x.DeleteTag == "False" || x.DeleteTag == null)
|
||||
select x;
|
||||
|
||||
@@ -173,7 +174,7 @@ namespace BLL
|
||||
IsOutName = x.IsOut == "1" ? "是" : "否",
|
||||
x.LeaveDate,
|
||||
x.IsBlackList,
|
||||
IsBlackListName =x.IsBlackList == "1" ? "是" : "否",
|
||||
IsBlackListName = x.IsBlackList == "1" ? "是" : "否",
|
||||
x.AgreementId,
|
||||
x.HasInsurance,
|
||||
x.DeviceNumber,
|
||||
@@ -184,6 +185,7 @@ namespace BLL
|
||||
x.UploadTime,
|
||||
};
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region 获取培训记录列表
|
||||
@@ -238,7 +240,7 @@ namespace BLL
|
||||
x.RecordName,
|
||||
x.TrainType,
|
||||
x.PaperMode,
|
||||
PaperModeName = x.PaperMode=="0"? "使用原卷" : "重新出卷",
|
||||
PaperModeName = x.PaperMode == "0" ? "使用原卷" : "重新出卷",
|
||||
x.TrainMode,
|
||||
x.TrainPrincipal,
|
||||
x.TrainStartDate,
|
||||
@@ -291,7 +293,7 @@ namespace BLL
|
||||
/// <param name="PageIndex">页码</param>
|
||||
/// <param name="PageSize">每页数量</param>
|
||||
/// <returns></returns>
|
||||
public static IEnumerable getTrainPersonListData(string projectId,string departName, string name, string identifyID, Grid Grid1)
|
||||
public static IEnumerable getTrainPersonListData(string projectId, string departName, string name, string identifyID, Grid Grid1)
|
||||
{
|
||||
IQueryable<Model.Bo_Sheng_TrainPerson> getDataList = getTrainPersons.Where(x => x.ProjectId == projectId);
|
||||
if (!string.IsNullOrEmpty(departName))
|
||||
@@ -335,7 +337,7 @@ namespace BLL
|
||||
x.SignInType,
|
||||
x.TrainPeriod,
|
||||
x.State,
|
||||
StateName= x.State=="0"? "正常" : "补签",
|
||||
StateName = x.State == "0" ? "正常" : "补签",
|
||||
x.TotalScore,
|
||||
x.PassScore,
|
||||
x.Score,
|
||||
@@ -369,8 +371,8 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.Bo_Sheng_Exam> getExams = from x in db.Bo_Sheng_Exam
|
||||
where (x.DeleteTag == "False" || x.DeleteTag == null)
|
||||
private static IQueryable<Model.Bo_Sheng_Exam> getExams = from x in db.Bo_Sheng_Exam
|
||||
where (x.DeleteTag == "False" || x.DeleteTag == null)
|
||||
select x;
|
||||
|
||||
/// <summary>
|
||||
@@ -379,7 +381,7 @@ namespace BLL
|
||||
/// <param name="PageIndex">页码</param>
|
||||
/// <param name="PageSize">每页数量</param>
|
||||
/// <returns></returns>
|
||||
public static IEnumerable getExamListData(string projectId, string qsnCode,string qsnContent, Grid Grid1)
|
||||
public static IEnumerable getExamListData(string projectId, string qsnCode, string qsnContent, Grid Grid1)
|
||||
{
|
||||
IQueryable<Model.Bo_Sheng_Exam> getDataList = getExams.Where(x => x.ProjectId == projectId);
|
||||
|
||||
@@ -414,7 +416,7 @@ namespace BLL
|
||||
x.QsnFileName,
|
||||
x.QsnAnswer,
|
||||
x.QsnCategory,
|
||||
QsnCategoryName= x.QsnCategory=="3"? "图片题" : (x.QsnCategory == "2"? "多媒体题" : "文字题"),
|
||||
QsnCategoryName = x.QsnCategory == "3" ? "图片题" : (x.QsnCategory == "2" ? "多媒体题" : "文字题"),
|
||||
x.QsnKind,
|
||||
QsnKindName = x.QsnKind == "3" ? "判断" : (x.QsnCategory == "2" ? "多选" : "单选"),
|
||||
x.QsnImportant,
|
||||
@@ -439,8 +441,8 @@ namespace BLL
|
||||
/// <summary>
|
||||
/// 定义变量
|
||||
/// </summary>
|
||||
private static IQueryable<Model.Bo_Sheng_PersonTrainRecord> getPersonTrainRecords = from x in db.Bo_Sheng_PersonTrainRecord
|
||||
where (x.DeleteTag == "False" || x.DeleteTag == null)
|
||||
private static IQueryable<Model.Bo_Sheng_PersonTrainRecord> getPersonTrainRecords = from x in db.Bo_Sheng_PersonTrainRecord
|
||||
where (x.DeleteTag == "False" || x.DeleteTag == null)
|
||||
select x;
|
||||
|
||||
/// <summary>
|
||||
@@ -508,5 +510,49 @@ namespace BLL
|
||||
};
|
||||
}
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 根据主键获取博晟人员信息
|
||||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
public static Model.Bo_Sheng_Person GetBoPersonById(string id)
|
||||
{
|
||||
return Funs.DB.Bo_Sheng_Person.FirstOrDefault(e => e.ID == id);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 修改博晟人员信息
|
||||
/// </summary>
|
||||
/// <param name="person"></param>
|
||||
/// <returns></returns>
|
||||
public static void UpdateBoPerson(Bo_Sheng_Person person)
|
||||
{
|
||||
Model.Bo_Sheng_Person newPerson = Funs.DB.Bo_Sheng_Person.FirstOrDefault(e => e.ID == person.ID);
|
||||
if (newPerson != null)
|
||||
{
|
||||
newPerson.Name = person.Name;
|
||||
newPerson.DepartName = person.DepartName;
|
||||
newPerson.IdentifyID = person.IdentifyID;
|
||||
newPerson.Sex = person.Sex;
|
||||
newPerson.BirthDay = person.BirthDay;
|
||||
newPerson.Station = person.Station;
|
||||
newPerson.Address = person.Address;
|
||||
newPerson.Police = person.Police;
|
||||
newPerson.ValidPeriodStart = person.ValidPeriodStart;
|
||||
newPerson.ValidPeriodEnd = person.ValidPeriodEnd;
|
||||
newPerson.Telephone = person.Telephone;
|
||||
newPerson.JobNumber = person.JobNumber;
|
||||
newPerson.NewAddress = person.NewAddress;
|
||||
newPerson.RegisterDate = person.RegisterDate;
|
||||
newPerson.CategoryLevel = person.CategoryLevel;
|
||||
newPerson.EntranceDate = person.EntranceDate;
|
||||
newPerson.LeaveDate = person.LeaveDate;
|
||||
newPerson.IsOut = person.IsOut;
|
||||
newPerson.IsBlackList = person.IsBlackList;
|
||||
newPerson.UploadTime = person.UploadTime;
|
||||
Funs.DB.SubmitChanges();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user