fix 处理访客上传人脸问题

This commit is contained in:
2025-02-28 17:30:10 +08:00
parent 1b0969d185
commit 537c7c5e85

View File

@@ -128,6 +128,7 @@ public class GainfoFaceService : IGainfoFaceService
.SingleAsync();
gainfo.ThrowIfNull("人员信息不存在");
(gainfo.Type == GainfoUserTypeEnumType.External).ThrowIfTrue("人员类型有误,禁止操作");
var face = await _faceDbContext.Queryable<GainfoFaceEntity>().Where(x => x.UserCode == gainfo.Code).SingleAsync();
var taskType = face == null ? DeviceTaskEnumType.Add : DeviceTaskEnumType.Update;