添加PAV其他问题答案
continuous-integration/drone/push Build is passing Details

Uat_IRC_Net8
he 2025-12-16 17:58:13 +08:00
parent 809d9da387
commit db204ab001
1 changed files with 15 additions and 0 deletions

View File

@ -782,6 +782,21 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
TableQuestionId = otherQuestion.Id, TableQuestionId = otherQuestion.Id,
}); });
} }
// 添加PAV其他问题答案
foreach (var otherQuestion in pAvTableQuestionList.Where(x => !tableAnswers.Any(y => y.TableQuestionId == x.Id && y.RowId == newRowId)))
{
tableAnswers.Add(new ReadingTableQuestionAnswer()
{
Answer = string.Empty,
QuestionId = pAVquestionInfo!.QuestionId,
TrialId = inDto.TrialId,
VisitTaskId = inDto.VisitTaskId,
RowId = newRowId,
RowIndex = item,
TableQuestionId = otherQuestion.Id,
});
}
} }
await _readingTableAnswerRowInfoRepository.BatchDeleteNoTrackingAsync(x => (x.QuestionId == questionInfo.QuestionId || x.QuestionId == pAVquestionInfo.QuestionId) && x.VisitTaskId == inDto.VisitTaskId); await _readingTableAnswerRowInfoRepository.BatchDeleteNoTrackingAsync(x => (x.QuestionId == questionInfo.QuestionId || x.QuestionId == pAVquestionInfo.QuestionId) && x.VisitTaskId == inDto.VisitTaskId);