Merge branch 'Test_IRC_Net8' of https://gitea.frp.extimaging.com/XCKJ/irc-netcore-api into Test_IRC_Net8
continuous-integration/drone/push Build is running Details

IRC_NewDev
he 2024-10-22 13:55:10 +08:00
commit 62d3b69bd5
4 changed files with 93 additions and 5 deletions

View File

@ -2124,6 +2124,57 @@ namespace IRaCIS.Core.Application.Service.Common
//处理裁判标记
list = DealJudgeMark(criterion.ArbitrationRule, list);
#region 系统标准处理整体肿瘤评估合并
//针对1.1 整体肿瘤评估 有的两列要合并一列
if (criterion.CriterionType == CriterionType.RECIST1Point1 || criterion.CriterionType == CriterionType.RECIST1Pointt1_MB || criterion.CriterionType == CriterionType.IRECIST1Point1)
{
foreach (var item in list)
{
var removeList = item.QuestionAnswerList.Where(t => t.QuestionType == QuestionType.ExistDisease || t.QuestionType == QuestionType.Tumor).ToList();
if (item.IsBaseline == true)
{
item.OverallTumorEvaluationResult = removeList.Where(t => t.QuestionType == QuestionType.ExistDisease).FirstOrDefault()?.QuestionValue;
}
else
{
item.OverallTumorEvaluationResult = removeList.Where(t => t.QuestionType != QuestionType.ExistDisease).FirstOrDefault()?.QuestionValue;
}
item.QuestionAnswerList = item.QuestionAnswerList.Where(t => !(t.QuestionType == QuestionType.ExistDisease || t.QuestionType == QuestionType.Tumor)).ToList();
}
}
else if (criterion.CriterionType == CriterionType.Lugano2014 || criterion.CriterionType == CriterionType.Lugano2014WithoutPET)
{
foreach (var item in list)
{
var removeList = item.QuestionAnswerList.Where(t => t.QuestionType == QuestionType.ExistDisease || t.QuestionType == QuestionType.ImgOncology).ToList();
if (item.IsBaseline == true)
{
item.OverallTumorEvaluationResult = removeList.Where(t => t.QuestionType == QuestionType.ExistDisease).FirstOrDefault()?.QuestionValue;
}
else
{
item.OverallTumorEvaluationResult = removeList.Where(t => t.QuestionType != QuestionType.ExistDisease).FirstOrDefault()?.QuestionValue;
}
item.QuestionAnswerList = item.QuestionAnswerList.Where(t => !(t.QuestionType == QuestionType.ExistDisease || t.QuestionType == QuestionType.ImgOncology)).ToList();
}
}
else if (criterion.CriterionType == CriterionType.PCWG3)
{
}
#endregion
exportInfo.List = ExportExcelConverterDate.ConvertToClientTimeInObject(list.Where(t => t.ReadingCategory != ReadingCategory.Global).ToList(), _userInfo.TimeZoneId);
exportInfo.CurrentTime = ExportExcelConverterDate.DateTimeInternationalToString(DateTime.Now, _userInfo.TimeZoneId);
@ -2140,6 +2191,11 @@ namespace IRaCIS.Core.Application.Service.Common
TranslateDicNameList = list.FirstOrDefault()?.QuestionAnswerList.Select(t => t.TranslateDicName).ToList() ?? new List<string>()
};
var (memoryStream, fileName) = await ExcelExportHelper.DataExport_NpoiTestAsync(export_Template, exportInfo, _commonDocumentRepository, _hostEnvironment, _dictionaryService, typeof(CommonEvaluationExport), criterion.CriterionType, dynamicColumnConfig);

View File

@ -1061,6 +1061,8 @@ namespace IRaCIS.Core.Application.Contracts
public class CommonQuesionInfo
{
public QuestionType? QuestionType { get; set; }
public string QuestionName { get; set; }
public string QuestionValue { get; set; }

View File

@ -6,6 +6,7 @@ using IRaCIS.Core.Application.Contracts.DTO;
using IRaCIS.Core.Application.MassTransit.Command;
using IRaCIS.Core.Application.ViewModel;
using IRaCIS.Core.Domain.Share;
using System.Linq;
namespace IRaCIS.Core.Application.Service
{
@ -19,7 +20,7 @@ namespace IRaCIS.Core.Application.Service
var isEn_Us = false;
CreateMap<Trial, ReadingPeriodJudgeExportInfo>();
CreateMap<Trial, ReadingPeriodJudgeExportInfo>();
CreateMap<Trial, VisitJudgeExportInfo>();
CreateMap<Trial, ExcelExportInfo>();
CreateMap<SubjectVisit, CRCVisitExportDTO>()
@ -199,7 +200,7 @@ namespace IRaCIS.Core.Application.Service
Guid trialReadingCriterionId = Guid.Empty;
ArbitrationRule? arbitrationRule = null;
CriterionType? criterionType = null;
ReadingExportType? readingExportType=null;
ReadingExportType? readingExportType = null;
CreateMap<VisitTask, OverallTumorEvaluationExport>()
// .ForMember(o => o.TrialReadingCriterionName, t => t.MapFrom(u => u.TrialReadingCriterion.CriterionName))
@ -226,7 +227,7 @@ namespace IRaCIS.Core.Application.Service
.ForMember(o => o.SubjectCode, t => t.MapFrom(u => u.Subject.Code))
.ForMember(o => o.UserName, t => t.MapFrom(u => u.DoctorUser.UserName));
CreateMap<VisitTask, CommonEvaluationExport>()
.ForMember(o => o.IsBaseline, t => t.MapFrom(u => u.SourceSubjectVisit.IsBaseLine))
@ -241,10 +242,14 @@ namespace IRaCIS.Core.Application.Service
.ForMember(o => o.SubjectCode, t => t.MapFrom(u => u.Subject.Code))
.ForMember(o => o.UserName, t => t.MapFrom(u => u.DoctorUser.UserName))
.ForMember(o => o.QuestionAnswerList, t => t.MapFrom(u => u.ReadingTaskQuestionAnswerList
.Where(c => readingExportType == ReadingExportType.ReadingDetailResult ? c.ReadingQuestionTrial.IsJudgeQuestion : c.ReadingQuestionTrial.IsJudgeQuestion)
.Where(c => readingExportType == ReadingExportType.ReadingResult ?
c.ReadingQuestionTrial.ExportResultStr.Contains( ((int)ExportResult.TableOfAssessmentResults).ToString()) :
(readingExportType == ReadingExportType.ReadingDetailResult ? c.ReadingQuestionTrial.ExportResultStr.Contains(((int)ExportResult.DetailedTableOfAssessmentResults).ToString()) :
c.ReadingQuestionTrial.ExportResultStr.Contains(((int)ExportResult.DetailedTableOfAdjudicationResults).ToString())))
.OrderBy(k => k.ReadingQuestionTrial.ShowOrder)
.Select(c => new CommonQuesionInfo()
{
QuestionType = c.ReadingQuestionTrial.QuestionType,
QuestionName = isEn_Us ? c.ReadingQuestionTrial.QuestionEnName : c.ReadingQuestionTrial.QuestionName,
QuestionValue = c.Answer,
TranslateDicName = c.ReadingQuestionTrial.DictionaryCode

View File

@ -378,7 +378,7 @@ namespace IRaCIS.Core.Domain.Share
/// 无
/// </summary>
None = 0,
}
/// <summary>
@ -391,6 +391,31 @@ namespace IRaCIS.Core.Domain.Share
/// </summary>
None = 0,
/// <summary>
/// <summary>
/// 阅片结果表
/// </summary>
TableOfAssessmentResults = 1,
/// <summary>
/// 阅片结果明细表
/// </summary>
DetailedTableOfAssessmentResults = 2,
/// <summary>
/// 裁判阅片明细表
/// </summary>
DetailedTableOfAdjudicationResults = 3,
/// <summary>
/// 自身一致性分析结果表
/// </summary>
DetailedTableOfIntraReaderAnalysisResults = 4,
/// <summary>
/// 组间一致性分析结果表
/// </summary>
DetailedTableOfInterReaderAnalysisResults = 5,
}