From 34f6292fa74ea903cb592d7f7b4fcd5c9db34fd3 Mon Sep 17 00:00:00 2001 From: he <109787524@qq.com> Date: Fri, 4 Jul 2025 15:11:32 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A8=BD=E6=9F=A5=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs b/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs index ab6159a09..d6ebff072 100644 --- a/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs +++ b/IRaCIS.Core.Infra.EFCore/Common/AuditingData.cs @@ -3192,16 +3192,16 @@ namespace IRaCIS.Core.Infra.EFCore.Common var tableQuestionAnswer = entitys.Where(x => x.Entity.GetType() == typeof(ReadingTableQuestionAnswer)).Select(x => x.Entity as ReadingTableQuestionAnswer) .Where(x => x.RowId == entity.RowId && x.TableQuestionId == entity.TableQuestionId).FirstOrDefault(); var answer=string.Empty; - var questionName=string.Empty; + if (tableQuestionAnswer != null) { answer = tableQuestionAnswer.Answer; - - } - questionName = await _dbContext.ReadingTableQuestionTrial.Where(x => x.Id == entity.TableQuestionId).Select(x => _userInfo.IsEn_Us? x.QuestionEnName:x.QuestionName).FirstOrDefaultAsync(); + var rowMark= await _dbContext.ReadingTableAnswerRowInfo.Where(x => x.Id == entity.RowId).Select(x => x.RowMark).FirstOrDefaultAsync(); + var tableQuestionName = await _dbContext.ReadingTableQuestionTrial.Where(x => x.Id == entity.TableQuestionId).Select(x => _userInfo.IsEn_Us? x.QuestionEnName:x.QuestionName).FirstOrDefaultAsync(); + var questionName = await _dbContext.ReadingQuestionTrial.Where(x => x.Id == entity.QuestionId).Select(x => _userInfo.IsEn_Us ? x.QuestionEnName : x.QuestionName).FirstOrDefaultAsync(); var liverSegmentation = await _dbContext.ReadingTableQuestionAnswer.Where(x => x.RowId == entity.RowId && x.ReadingTableQuestionTrial.QuestionMark == QuestionMark.liverSegmentation).Select(x => x.Answer).FirstOrDefaultAsync(); await InsertInspection(entity, type, x => new InspectionConvertDTO() @@ -3212,11 +3212,12 @@ namespace IRaCIS.Core.Infra.EFCore.Common }, new { - QuestionName = questionName, + RowMark = rowMark, + TableQuestionName = tableQuestionName, Answer = answer, LiverSegmentation = liverSegmentation, - }); + },_userInfo.AuditIdentification); }