代码修改

Uat_IRC_Net8
he 2025-07-10 09:19:56 +08:00
parent 474b9ca80e
commit dd35e37e65
1 changed files with 22 additions and 12 deletions

View File

@ -3228,20 +3228,30 @@ namespace IRaCIS.Core.Infra.EFCore.Common
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<ReadingTaskQuestionMark>(entity, type, x => new InspectionConvertDTO()
var generalId=new Guid();
if (entity.TableQuestionId == null && entity.QuestionId == null)
{
VisitTaskId = entity.VisitTaskId,
GeneralId = IdentifierHelper.CreateGuid(entity.VisitTaskId.ToString(), entity.QuestionId.ToString(), entity.TableQuestionId.ToString()),
ObjectRelationParentId = entity.VisitTaskId,
generalId = entity.Id;
}
else
{
generalId = IdentifierHelper.CreateGuid(entity.VisitTaskId.ToString(), entity.QuestionId.ToString(), entity.TableQuestionId.ToString());
}
}, new
{
QuestionName = questionName,
RowMark = rowMark,
TableQuestionName = tableQuestionName,
Answer = answer,
LiverSegmentation = liverSegmentation,
}, _userInfo.AuditIdentification);
await InsertInspection<ReadingTaskQuestionMark>(entity, type, x => new InspectionConvertDTO()
{
VisitTaskId = entity.VisitTaskId,
GeneralId = generalId,
ObjectRelationParentId = entity.VisitTaskId,
}, new
{
QuestionName = questionName,
RowMark = rowMark,
TableQuestionName = tableQuestionName,
Answer = answer,
LiverSegmentation = liverSegmentation,
}, _userInfo.AuditIdentification);
}