1、优化考勤记录导入,优化出入记录写实名制推送记录表。2、优化考试答题,交卷接口方法。3、优化写入培训记录。
This commit is contained in:
@@ -1046,13 +1046,12 @@ namespace BLL
|
||||
/// <param name="idCard"></param>
|
||||
/// <param name="isIn"></param>
|
||||
/// <param name="changeTime"></param>
|
||||
public static void getPersonInOut(string projectId, string idCard, int isIn, DateTime changeTime)
|
||||
public static void getPersonInOut(Model.SitePerson_Person getPerson, int isIn, DateTime changeTime)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(idCard))
|
||||
if (!string.IsNullOrEmpty(getPerson.IdentityCard))
|
||||
{
|
||||
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
|
||||
{
|
||||
var getPerson = db.SitePerson_Person.FirstOrDefault(x => x.ProjectId == projectId && x.IdentityCard == idCard);
|
||||
{
|
||||
if (getPerson != null)
|
||||
{
|
||||
string postType = null;
|
||||
@@ -1061,13 +1060,13 @@ namespace BLL
|
||||
{
|
||||
postType = getWokPost.PostType;
|
||||
}
|
||||
var getPersonInOut = db.SitePerson_PersonInOut.FirstOrDefault(x => x.PersonId == getPerson.PersonId && x.ProjectId == projectId && x.ChangeTime == changeTime);
|
||||
var getPersonInOut = db.SitePerson_PersonInOut.FirstOrDefault(x => x.PersonId == getPerson.PersonId && x.ProjectId == getPerson.ProjectId && x.ChangeTime == changeTime);
|
||||
if (getPersonInOut == null)
|
||||
{
|
||||
Model.SitePerson_PersonInOut newInOut = new Model.SitePerson_PersonInOut
|
||||
{
|
||||
PersonInOutId = SQLHelper.GetNewID(),
|
||||
ProjectId = projectId,
|
||||
ProjectId = getPerson.ProjectId,
|
||||
UnitId = getPerson.UnitId,
|
||||
PersonId = getPerson.PersonId,
|
||||
IsIn = isIn == 1 ? true : false,
|
||||
@@ -1079,7 +1078,7 @@ namespace BLL
|
||||
db.SitePerson_PersonInOut.InsertOnSubmit(newInOut);
|
||||
db.SubmitChanges();
|
||||
|
||||
string proCode = ProjectService.GetJTProjectCodeByProjectId(projectId);
|
||||
string proCode = ProjectService.GetJTProjectCodeByProjectId(getPerson.ProjectId);
|
||||
Model.SitePerson_PersonInOutNow newNow = new Model.SitePerson_PersonInOutNow
|
||||
{
|
||||
PersonInOutId = newInOut.PersonInOutId,
|
||||
|
||||
Reference in New Issue
Block a user