修改
This commit is contained in:
+25
-2
@@ -612,7 +612,22 @@ namespace IRaCIS.Application.Services
|
||||
result = result.Where(x => x.VisitTaskId == inDto.VisitTaskId).ToList();
|
||||
}
|
||||
|
||||
foreach (var item in result)
|
||||
|
||||
var visitaskIds = result.Select(x => x.VisitTaskId).ToList();
|
||||
|
||||
var otherStudys = await _readingTableAnswerRowInfoRepository.Where(x => visitaskIds.Contains(x.VisitTaskId))
|
||||
.Where(x=>x.CTSeriesId!=null&&x.PTSeriesId!=null)
|
||||
.Select(x => new
|
||||
{
|
||||
x.OtherStudyId,
|
||||
x.CTSeriesId,
|
||||
x.PTSeriesId,
|
||||
x.VisitTaskId,
|
||||
x.UpdateTime
|
||||
}).ToListAsync();
|
||||
|
||||
|
||||
foreach (var item in result)
|
||||
{
|
||||
var clinicalDataList = await _readingClinicalDataService.GetClinicalDataList(new GetReadingOrTaskClinicalDataListInDto()
|
||||
{
|
||||
@@ -623,7 +638,15 @@ namespace IRaCIS.Application.Services
|
||||
});
|
||||
|
||||
item.IsExistsClinicalData = clinicalDataList.Count > 0;
|
||||
}
|
||||
var otherStudy = otherStudys.Where(x => x.VisitTaskId == item.VisitTaskId).OrderByDescending(x => x.UpdateTime).FirstOrDefault();
|
||||
if (otherStudy != null)
|
||||
{
|
||||
item.PTSeriesId = otherStudy.PTSeriesId;
|
||||
item.CTSeriesId = otherStudy.CTSeriesId;
|
||||
item.OtherStudyId = otherStudy.OtherStudyId;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user