20231225
This commit is contained in:
parent
1f08356eb1
commit
13aff7f29c
|
@ -672,6 +672,20 @@ namespace BLL
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static void UpdatePhotoUrl(string personId, string photoUrl, System.Data.Linq.Binary headImage )
|
||||||
|
{
|
||||||
|
using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString))
|
||||||
|
{
|
||||||
|
var person = db.SitePerson_Person.FirstOrDefault(x => x.PersonId == personId);
|
||||||
|
if (person != null)
|
||||||
|
{
|
||||||
|
person.PhotoUrl = photoUrl;
|
||||||
|
person.HeadImage = headImage;
|
||||||
|
db.SubmitChanges();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 根据人员Id删除一个人员信息
|
/// 根据人员Id删除一个人员信息
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -281,7 +281,7 @@ namespace WebAPI.Controllers
|
||||||
getPerson.PhotoUrl = path + flieName;
|
getPerson.PhotoUrl = path + flieName;
|
||||||
System.IO.File.WriteAllBytes((fileUrl + flieName), image);
|
System.IO.File.WriteAllBytes((fileUrl + flieName), image);
|
||||||
//AttachFileService.Base64ToImage(person.headImage, path, person.PersonName);
|
//AttachFileService.Base64ToImage(person.headImage, path, person.PersonName);
|
||||||
db.SubmitChanges();
|
PersonService.UpdatePhotoUrl(getPerson.PersonId, getPerson.PhotoUrl,getPerson.HeadImage);
|
||||||
responeData.message = "更新照片!";
|
responeData.message = "更新照片!";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue