diff --git a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingImageTaskViewModel.cs b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingImageTaskViewModel.cs index c3863a781..4530544ce 100644 --- a/IRaCIS.Core.Application/Service/Reading/Dto/ReadingImageTaskViewModel.cs +++ b/IRaCIS.Core.Application/Service/Reading/Dto/ReadingImageTaskViewModel.cs @@ -1406,10 +1406,12 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto public bool IsFirstChangeTask { get; set; } = false; - /// - /// 是否是转变的任务(转为IRECIST) - /// - public bool IsConvertedTask { get; set; } = false; + public ReadingTaskState ReadingTaskState { get; set; } + + /// + /// 是否是转变的任务(转为IRECIST) + /// + public bool IsConvertedTask { get; set; } = false; } diff --git a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs index 866c54787..151e25924 100644 --- a/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ReadingImageTask/ReadingImageTaskService.cs @@ -2364,7 +2364,7 @@ namespace IRaCIS.Application.Services var blindSubjectCode = await _visitTaskRepository.Where(x => x.Id == task.VisitTaskId).Select(x => x.BlindSubjectCode).FirstNotNullAsync(); task.SubjectCode = blindSubjectCode.IsNullOrEmpty() ? task.SubjectCode : blindSubjectCode; task.ExistsManual = (await GetManualList(new GetManualListInDto() { TrialId = visitTaskInfo.TrialId })).Count() > 0; - + task.ReadingTaskState = visitTaskInfo.ReadingTaskState; return task; } diff --git a/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs b/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs index 24b4d42cf..6647a84aa 100644 --- a/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs +++ b/IRaCIS.Core.Application/Service/ReadingCalculate/IRECIST1Point1CalculateService.cs @@ -2342,7 +2342,7 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate IRECISTNewLesionAssessmentDto data = new IRECISTNewLesionAssessmentDto() { //上一次任务的新病灶评估为iUPD - LastTaskNewLesioniUPD = lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewLesionEvaluation && x.Answer.EqEnum(NewLesionAssessment.iCPD)), + LastTaskNewLesioniUPD = lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewLesionEvaluation && x.Answer.EqEnum(NewLesionAssessment.iUPD)), }; // if(新靶病灶为ND&&新非靶病灶为ND&&其它既往新病灶为ND&&不存在触发iRECIST后新病灶) @@ -2507,74 +2507,74 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate return result.GetEnumInt(); } - #endregion + #endregion - #region iRECSIT整体肿瘤评估 + #region iRECSIT整体肿瘤评估 - /// - /// - /// - /// - /// if(上一访视评估为iUPD或iCPD&&靶病灶评估、非靶病灶评估或新病灶评估任一项为iCPD) - /// { - /// 疗效为 iCPD - /// } - /// else if (上一访视评估为iUPD或iCPD&&靶病灶评估、非靶病灶评估或新病灶评估任一项从前一访视非iUPD结果评估为当前访视iUPD) - /// { - /// 疗效为 iCPD - /// } - /// else if (靶病灶评估为iUPD || 非靶病灶评估为iUPD || 新病灶评估为iUPD) - /// { - /// 疗效为 iUPD - /// } - /// else if ((靶病灶评估为iCR || 非靶病灶评估为iCR) && 新病灶评估为ND) - /// { - /// 疗效为 iCR - /// } - /// else if (靶病灶评估为iPR && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) - /// { - /// 疗效为 iPR - /// } - /// else if (靶病灶评估为iPR && 非靶病灶评估为iNN或NE && 新病灶评估为否或疑似或NE) - /// { - /// 疗效为 iPR - /// } - /// else if (靶病灶评估为iPR && 非靶病灶评估为iCR或ND && 新病灶评估为疑似或NE) - /// { - /// 疗效为 iPR - /// } - /// else if (靶病灶评估为ND && 非靶病灶评估为iCR && 新病灶评估为疑似或NE) - /// { - /// 疗效为 iPR - /// } - /// else if (靶病灶评估为iSD && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) - /// { - /// 疗效为 iSD - /// } - /// else if (靶病灶评估为ND && 非靶病灶评估为iNN && 新病灶评估为ND或疑似或NE) - /// { - /// 疗效为 iNN - /// } - /// else if (靶病灶评估为ND && 非靶病灶评估为ND && 新病灶评估为ND或疑似) - /// { - /// 疗效为 ND - /// } - /// else if (靶病灶评估为NE && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) - /// { - /// 疗效为 NE - /// } - /// else if (靶病灶评估为ND && 非靶病灶评估为NE && 新病灶评估为否或疑似或NE) - /// { - /// 疗效为 NE - /// } - /// else if (靶病灶评估为ND && 非靶病灶评估为ND && 新病灶评估为NE) - /// { - /// 疗效为 NE - /// } - /// - /// - /// - public async Task GetIRECSITTargetLesionEvaluate(ReadingCalculateDto inDto) + /// + /// + /// + /// + /// if(上一访视评估为iUPD或iCPD&&靶病灶评估、非靶病灶评估或新病灶评估任一项为iCPD) + /// { + /// 疗效为 iCPD + /// } + /// else if (上一访视评估为iUPD或iCPD&&靶病灶评估、非靶病灶评估或新病灶评估任一项从前一访视非iUPD结果评估为当前访视iUPD) + /// { + /// 疗效为 iCPD + /// } + /// else if (靶病灶评估为iUPD || 非靶病灶评估为iUPD || 新病灶评估为iUPD) + /// { + /// 疗效为 iUPD + /// } + /// else if ((靶病灶评估为iCR || 非靶病灶评估为iCR) && 新病灶评估为ND) + /// { + /// 疗效为 iCR + /// } + /// else if (靶病灶评估为iPR && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) + /// { + /// 疗效为 iPR + /// } + /// else if (靶病灶评估为iPR && 非靶病灶评估为iNN或NE && 新病灶评估为否或疑似或NE) + /// { + /// 疗效为 iPR + /// } + /// else if (靶病灶评估为iPR && 非靶病灶评估为iCR或ND && 新病灶评估为疑似或NE) + /// { + /// 疗效为 iPR + /// } + /// else if (靶病灶评估为ND && 非靶病灶评估为iCR && 新病灶评估为疑似或NE) + /// { + /// 疗效为 iPR + /// } + /// else if (靶病灶评估为iSD && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) + /// { + /// 疗效为 iSD + /// } + /// else if (靶病灶评估为ND && 非靶病灶评估为iNN && 新病灶评估为ND或疑似或NE) + /// { + /// 疗效为 iNN + /// } + /// else if (靶病灶评估为ND && 非靶病灶评估为ND && 新病灶评估为ND或疑似) + /// { + /// 疗效为 ND + /// } + /// else if (靶病灶评估为NE && 非靶病灶评估为iCR,iNN,NE或ND && 新病灶评估为ND或疑似或NE) + /// { + /// 疗效为 NE + /// } + /// else if (靶病灶评估为ND && 非靶病灶评估为NE && 新病灶评估为否或疑似或NE) + /// { + /// 疗效为 NE + /// } + /// else if (靶病灶评估为ND && 非靶病灶评估为ND && 新病灶评估为NE) + /// { + /// 疗效为 NE + /// } + /// + /// + /// + public async Task GetIRECSITTargetLesionEvaluate(ReadingCalculateDto inDto) { var lastVisitTaskId = await GetLastVisitTaskId(inDto); @@ -2597,13 +2597,23 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate } // else if (上一访视评估为iUPD或iCPD&&靶病灶评估、非靶病灶评估或新病灶评估任一项从前一访视非iUPD结果评估为当前访视iUPD) if (data.LastTaskLesioniUPDOriCPD - && (lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.TargetLesion && !x.Answer.EqEnum(TargetAssessment.iUPD)) - || lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NoTargetLesion && !x.Answer.EqEnum(NoTargetAssessment.iUPD)) - || lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewTargetLesion && !x.Answer.EqEnum(NewTargetLesionAssessment.iUPD))) - && (inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.TargetLesion && x.Answer.EqEnum(TargetAssessment.iUPD)) - || inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NoTargetLesion && x.Answer.EqEnum(NoTargetAssessment.iUPD)) - || inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewTargetLesion && x.Answer.EqEnum(NewLesionAssessment.iUPD))) + && ( + ( + lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.TargetLesion && !x.Answer.EqEnum(TargetAssessment.iUPD)) + && inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.TargetLesion && x.Answer.EqEnum(TargetAssessment.iUPD)) + ) + || + ( + lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NoTargetLesion && !x.Answer.EqEnum(NoTargetAssessment.iUPD)) + && inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NoTargetLesion && x.Answer.EqEnum(NoTargetAssessment.iUPD)) + ) + || + ( + lastTaskCalculateDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewLesionEvaluation && !x.Answer.EqEnum(NewLesionAssessment.iUPD))) + && inDto.QuestionInfo.Any(x => x.QuestionType == QuestionType.NewLesionEvaluation && x.Answer.EqEnum(NewLesionAssessment.iUPD)) + ) ) + { // 疗效为 iCPD result = OverallAssessment.iCPD; diff --git a/IRaCIS.Core.Domain.Share/Allocation/AllocationRelation.cs b/IRaCIS.Core.Domain.Share/Allocation/AllocationRelation.cs index fd4446878..d5c6dec54 100644 --- a/IRaCIS.Core.Domain.Share/Allocation/AllocationRelation.cs +++ b/IRaCIS.Core.Domain.Share/Allocation/AllocationRelation.cs @@ -296,13 +296,20 @@ namespace IRaCIS.Core.Domain.Share //阅片状态 public enum ReadingTaskState { + /// + /// 待阅 + /// WaitReading = 0, + /// + /// 阅片中 + /// Reading = 1, - HaveSigned = 2, - - + /// + /// 已签名 + /// + HaveSigned = 2, } ///