20211125人员照片更改时 置空同步时间

This commit is contained in:
杨红卫 2021-11-25 15:07:09 +08:00
parent a0b59c0a6f
commit 7e0564dde6
2 changed files with 6 additions and 3 deletions

View File

@ -856,9 +856,10 @@ namespace BLL
getPerson.MainCNProfessionalId = newPerson.MainCNProfessionalId;
getPerson.ViceCNProfessionalId = newPerson.ViceCNProfessionalId;
if (!string.IsNullOrEmpty(person.PhotoUrl))
if (!string.IsNullOrEmpty(person.PhotoUrl) && getPerson.PhotoUrl != person.PhotoUrl)
{
getPerson.PhotoUrl = person.PhotoUrl;
getPerson.ExchangeTime = null;
getPerson.HeadImage = newPerson.HeadImage;
}
if (!string.IsNullOrEmpty(person.AttachUrl1))
@ -989,9 +990,10 @@ namespace BLL
var getPerson = db.SitePerson_Person.FirstOrDefault(x => x.IdentityCard == person.IdentityCard || x.PersonId == person.PersonId);
if (getPerson != null)
{
if (!string.IsNullOrEmpty(person.PhotoUrl))
if (!string.IsNullOrEmpty(person.PhotoUrl) && getPerson.PhotoUrl != person.PhotoUrl)
{
getPerson.PhotoUrl = person.PhotoUrl;
getPerson.ExchangeTime = null;
string rootUrl = ConfigurationManager.AppSettings["localRoot"];
if (!string.IsNullOrEmpty(rootUrl) && !string.IsNullOrEmpty(person.PhotoUrl))
{

View File

@ -466,8 +466,9 @@ namespace BLL
{
newPerson.PhotoUrl = person.PhotoUrl;
newPerson.ExchangeTime = null;
newPerson.HeadImage = person.HeadImage;
}
newPerson.HeadImage = person.HeadImage;
newPerson.IsUsed = person.IsUsed;
newPerson.IsCardUsed = person.IsCardUsed;
newPerson.EduLevel = person.EduLevel;