diff --git a/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs b/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs index 417059716..337463039 100644 --- a/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs +++ b/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs @@ -50,8 +50,8 @@ namespace IRaCIS.Core.Infra.EFCore.Common public async Task IncomingEntitys(List entitys) { // 修改 - await InsertAddEntitys(entitys.Where(x => x.State == EntityState.Modified && ((!typeof(ISoftDelete).IsAssignableFrom(x.Entity.GetType()) - || !(bool)x.Entity.GetType().GetProperty("IsDeleted").GetValue(x.Entity))||x.Entity.GetType()== typeof(DicomSeries)) + await InsertAddEntitys(entitys.Where(x => x.State == EntityState.Modified && (!typeof(ISoftDelete).IsAssignableFrom(x.Entity.GetType()) + || !(bool)x.Entity.GetType().GetProperty("IsDeleted").GetValue(x.Entity)) ).ToList(), "Update"); // 新增 @@ -59,7 +59,7 @@ namespace IRaCIS.Core.Infra.EFCore.Common // 删除 await InsertAddEntitys(entitys.Where(x => x.State == EntityState.Deleted - ||((typeof(ISoftDelete).IsAssignableFrom(x.Entity.GetType())&& x.Entity.GetType() != typeof(DicomSeries) && (bool)x.Entity.GetType().GetProperty("IsDeleted").GetValue(x.Entity))) + || ((typeof(ISoftDelete).IsAssignableFrom(x.Entity.GetType()) && (bool)x.Entity.GetType().GetProperty("IsDeleted").GetValue(x.Entity))) ).ToList(), "Deleted"); @@ -137,8 +137,6 @@ namespace IRaCIS.Core.Infra.EFCore.Common await InsertInspection(item, type, x => new DataInspection() { GeneralId = x.Id, - - }); } diff --git a/IRaCIS.Core.Infra.EFCore/Repository/Repository.cs b/IRaCIS.Core.Infra.EFCore/Repository/Repository.cs index 952959202..6503421dd 100644 --- a/IRaCIS.Core.Infra.EFCore/Repository/Repository.cs +++ b/IRaCIS.Core.Infra.EFCore/Repository/Repository.cs @@ -761,7 +761,7 @@ namespace IRaCIS.Core.Infra.EFCore { Key = "AuditState", - Code = trialtype == TrialQCProcess.SingleAudit ? "AuditStateRC" : "AuditStatePE", + Code = trialtype == TrialQCProcess.SingleAudit ? "AuditStatePE" : "AuditStateRC", Type = "Code", });