20210720
This commit is contained in:
@@ -44,6 +44,12 @@ namespace BLL
|
||||
|
||||
db.SitePerson_Checking.InsertOnSubmit(newPersonInfo);
|
||||
db.SubmitChanges();
|
||||
|
||||
if (!string.IsNullOrEmpty(personInfo.ProjectId) && !string.IsNullOrEmpty(personInfo.IdentityCard) && personInfo.IntoOutTime.HasValue)
|
||||
{
|
||||
int inOut = personInfo.IntoOut == "1" ? 1 : 0;
|
||||
APIDoorServerService.SaveDoorInOutRecord(personInfo.ProjectId, personInfo.IdentityCard, inOut, personInfo.IntoOutTime.Value, "手动");
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -53,18 +59,21 @@ namespace BLL
|
||||
public static void UpdatePersonInfo(Model.SitePerson_Checking personInfo)
|
||||
{
|
||||
Model.SGGLDB db = Funs.DB;
|
||||
Model.SitePerson_Checking newPersonInfo = db.SitePerson_Checking.First(e => e.CheckingId == personInfo.CheckingId);
|
||||
newPersonInfo.CardNo = personInfo.CardNo;
|
||||
newPersonInfo.PersonId = personInfo.PersonId;
|
||||
newPersonInfo.ProjectId = personInfo.ProjectId;
|
||||
newPersonInfo.WorkAreaId = personInfo.WorkAreaId;
|
||||
newPersonInfo.WorkAreaName = personInfo.WorkAreaName;
|
||||
newPersonInfo.IdentityCard = personInfo.IdentityCard;
|
||||
newPersonInfo.IntoOutTime = personInfo.IntoOutTime;
|
||||
newPersonInfo.IntoOut = personInfo.IntoOut;
|
||||
newPersonInfo.Address = personInfo.Address;
|
||||
Model.SitePerson_Checking newPersonInfo = db.SitePerson_Checking.FirstOrDefault(e => e.CheckingId == personInfo.CheckingId);
|
||||
if (newPersonInfo != null)
|
||||
{
|
||||
newPersonInfo.CardNo = personInfo.CardNo;
|
||||
newPersonInfo.PersonId = personInfo.PersonId;
|
||||
newPersonInfo.ProjectId = personInfo.ProjectId;
|
||||
newPersonInfo.WorkAreaId = personInfo.WorkAreaId;
|
||||
newPersonInfo.WorkAreaName = personInfo.WorkAreaName;
|
||||
newPersonInfo.IdentityCard = personInfo.IdentityCard;
|
||||
newPersonInfo.IntoOutTime = personInfo.IntoOutTime;
|
||||
newPersonInfo.IntoOut = personInfo.IntoOut;
|
||||
newPersonInfo.Address = personInfo.Address;
|
||||
|
||||
db.SubmitChanges();
|
||||
db.SubmitChanges();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user