修改复制 recist1.1 淋巴结病灶状态
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
53149bf8a0
commit
8e730fc342
|
@ -867,30 +867,45 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
TrialId = x.TrialId,
|
||||
}).ToListAsync();
|
||||
|
||||
foreach (var item in recistTableAnswers)
|
||||
{
|
||||
foreach (var item in recistTableAnswers)
|
||||
{
|
||||
var rowinfo = tableRowAnswers.Where(y => y.OriginalId == item.RowId).FirstOrDefault();
|
||||
if (rowinfo != null)
|
||||
{
|
||||
item.QuestionId = rowinfo.QuestionId;
|
||||
|
||||
item.QuestionId = tableRowAnswers.Where(y => y.OriginalId == item.RowId).Select(x => x.QuestionId).FirstOrDefault();
|
||||
item.TableQuestionId = tableQuestionList.Where(x => x.ReadingQuestionId == item.QuestionId && x.QuestionMark == item.QuestionMark).Select(x => x.Id).FirstOrDefault();
|
||||
}
|
||||
var IslymphNode= recistTableAnswers.Where(x=>x.RowId== rowinfo.Id&&x.QuestionMark==QuestionMark.IsLymph).Select(x=>x.Answer).FirstIsNullReturnEmpty().EqEnum(YesOrNoOrNa.Yes);
|
||||
var minorAxis= recistTableAnswers.Where(x => x.RowId == rowinfo.Id && x.QuestionMark == QuestionMark.ShortAxis).Select(x => x.Answer).FirstIsNullReturnEmpty().IsNullOrEmptyReturn0();
|
||||
|
||||
var iSbetween15and20= minorAxis >= 15 && minorAxis < 20;
|
||||
if (item.QuestionMark == QuestionMark.State && IslymphNode && iSbetween15and20 && rowinfo.LesionType == LesionType.TargetLesion)
|
||||
{
|
||||
item.Answer = string.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
item.TableQuestionId = tableQuestionList.Where(x => x.ReadingQuestionId == item.QuestionId && x.QuestionMark == item.QuestionMark).Select(x => x.Id).FirstOrDefault();
|
||||
}
|
||||
|
||||
recistTableAnswers = recistTableAnswers.Where(x => x.TableQuestionId != default(Guid)).ToList();
|
||||
|
||||
List<QuestionMark?> notNeedCopyMarks = new List<QuestionMark?>()
|
||||
{
|
||||
List<QuestionMark?> notNeedCopyMarks = new List<QuestionMark?>()
|
||||
{
|
||||
|
||||
};
|
||||
var tableAnswers = recistTableAnswers.Select(x => new ReadingTableQuestionAnswer
|
||||
{
|
||||
Id = NewId.NextGuid(),
|
||||
Answer = notNeedCopyMarks.Contains(x.QuestionMark) ? string.Empty : x.Answer,
|
||||
QuestionId = x.QuestionId,
|
||||
RowIndex = x.RowIndex,
|
||||
RowId = tableRowAnswers.Where(y => y.OriginalId == x.RowId).Select(x => x.Id).FirstOrDefault(),
|
||||
TableQuestionId = x.TableQuestionId,
|
||||
TrialId = x.TrialId,
|
||||
VisitTaskId = visitTaskId,
|
||||
}).ToList();
|
||||
};
|
||||
|
||||
var tableAnswers = recistTableAnswers.Select(x => new ReadingTableQuestionAnswer
|
||||
{
|
||||
Id = NewId.NextGuid(),
|
||||
Answer = notNeedCopyMarks.Contains(x.QuestionMark) ? string.Empty : x.Answer,
|
||||
QuestionId = x.QuestionId,
|
||||
RowIndex = x.RowIndex,
|
||||
RowId = tableRowAnswers.Where(y => y.OriginalId == x.RowId).Select(x => x.Id).FirstOrDefault(),
|
||||
TableQuestionId = x.TableQuestionId,
|
||||
TrialId = x.TrialId,
|
||||
VisitTaskId = visitTaskId,
|
||||
}).ToList();
|
||||
|
||||
// 添加 典型肝内病灶 默认值
|
||||
tableRowAnswers.ForEach(x =>
|
||||
|
|
Loading…
Reference in New Issue