Merge branch 'Test_IRC_Net8' of http://192.168.3.68:2000/XCKJ/irc-netcore-api into Test_IRC_Net8
continuous-integration/drone/push Build is running
Details
continuous-integration/drone/push Build is running
Details
commit
757ccc3eb6
|
@ -456,7 +456,7 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
List<ReadingCalculateData> calculateList = new List<ReadingCalculateData>()
|
||||
{
|
||||
// EEM求和
|
||||
new ReadingCalculateData (){QuestionType=QuestionType.EEMSun,GetDecimalNullFun=GetEEM},
|
||||
new ReadingCalculateData (){QuestionType=QuestionType.EEMSum,GetDecimalNullFun=GetEEM},
|
||||
|
||||
// (EEM-Lumen)求和
|
||||
new ReadingCalculateData (){QuestionType=QuestionType.EEMLumenSum,GetDecimalNullFun=GetEEMLumenSum},
|
||||
|
@ -586,7 +586,7 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
public async Task<decimal?> GetEEM(ReadingCalculateDto inDto)
|
||||
{
|
||||
return inDto.QuestionInfo.Where(x => x.LesionType == LesionType.MatchValues).SelectMany(x => x.TableRowInfoList).SelectMany(x => x.TableQuestionList)
|
||||
.Where(x => x.QuestionMark == QuestionMark.ElasticAreaDiffValue).Select(x => x.Answer.IsNullOrEmptyReturn0()).Sum();
|
||||
.Where(x => x.QuestionMark == QuestionMark.ElasticArea).Select(x => x.Answer.IsNullOrEmptyReturn0()).Sum();
|
||||
|
||||
}
|
||||
|
||||
|
@ -597,14 +597,8 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
/// <returns></returns>
|
||||
public async Task<decimal?> GetEEMLumenSum(ReadingCalculateDto inDto)
|
||||
{
|
||||
var eMM= await GetEEM(inDto);
|
||||
var lumenAreaSum = inDto.QuestionInfo.Where(x => x.LesionType == LesionType.MatchValues).SelectMany(x => x.TableRowInfoList).SelectMany(x => x.TableQuestionList)
|
||||
.Where(x => x.QuestionMark == QuestionMark.LumenArea).Select(x => x.Answer.IsNullOrEmptyReturn0()).Sum();
|
||||
if (eMM == 0 || lumenAreaSum == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return eMM / lumenAreaSum;
|
||||
return inDto.QuestionInfo.Where(x => x.LesionType == LesionType.MatchValues).SelectMany(x => x.TableRowInfoList).SelectMany(x => x.TableQuestionList)
|
||||
.Where(x => x.QuestionMark == QuestionMark.ElasticAreaDiffValue).Select(x => x.Answer.IsNullOrEmptyReturn0()).Sum();
|
||||
|
||||
}
|
||||
|
||||
|
@ -630,18 +624,23 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
/// <summary>
|
||||
/// 冠状动脉粥样硬化体积百分比(PAV)
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// (EEM-Lumen)求和/EEM求和✖️100,单位%
|
||||
/// </remarks>
|
||||
/// <param name="inDto"></param>
|
||||
/// <returns></returns>
|
||||
public async Task<decimal?> GetPAV(ReadingCalculateDto inDto)
|
||||
{
|
||||
var result =await GetEEMLumenSum(inDto);
|
||||
if (result == null)
|
||||
var eEMLumenSum = inDto.QuestionInfo.Where(x => x.QuestionType == QuestionType.EEMLumenSum).Select(x => x.Answer).FirstOrDefault().IsNullOrEmptyReturn0();
|
||||
var eEMSum = inDto.QuestionInfo.Where(x => x.QuestionType == QuestionType.EEMSum).Select(x => x.Answer).FirstOrDefault().IsNullOrEmptyReturn0();
|
||||
|
||||
if (eEMSum == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
else
|
||||
{
|
||||
return result.Value * 200;
|
||||
return eEMLumenSum/ eEMSum * 100+100;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -653,6 +652,7 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
public async Task<decimal?> GetNTAV(ReadingCalculateDto inDto)
|
||||
{
|
||||
var result = await GetNTAVEEMLumenSumOrRetraceImageCount(inDto);
|
||||
|
||||
var medianFrame= inDto.QuestionInfo.Where(x => x.QuestionType == QuestionType.MedianFrame).Select(x => x.Answer).FirstOrDefault().IsNullOrEmptyReturn0();
|
||||
if (result == null|| medianFrame==0)
|
||||
{
|
||||
|
|
|
@ -634,15 +634,38 @@ namespace IRaCIS.Core.Application.Service.ReadingCalculate
|
|||
|
||||
}
|
||||
|
||||
///// <summary>
|
||||
///// 计算NTAV的EEM
|
||||
///// </summary>
|
||||
///// <param name="inDto"></param>
|
||||
///// <returns></returns>
|
||||
//public async Task<decimal> GetEEM(ReadingCalculateDto inDto)
|
||||
//{
|
||||
// var tableQuestion = inDto.QuestionInfo.Where(x => x.LesionType == LesionType.TargetLesion).SelectMany(x => x.TableRowInfoList).ToList();
|
||||
//}
|
||||
/// <summary>
|
||||
/// 匹配动脉段最小FCT
|
||||
/// </summary>
|
||||
/// <param name="inDto"></param>
|
||||
/// <returns></returns>
|
||||
public async Task<decimal?> GetAllMinFCT(ReadingCalculateDto inDto)
|
||||
{
|
||||
|
||||
var allMinFCT = inDto.QuestionInfo.Where(x => x.LesionType == LesionType.FCT).SelectMany(x => x.TableRowInfoList).SelectMany(x => x.TableQuestionList)
|
||||
.Where(x => x.QuestionMark == QuestionMark.MinFCT).Select(x => x.Answer.IsNullOrEmptyReturn0()).Min();
|
||||
if (allMinFCT == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return allMinFCT;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 所有FCT最小值中的平均值
|
||||
/// </summary>
|
||||
/// <param name="inDto"></param>
|
||||
/// <returns></returns>
|
||||
public async Task<decimal?> GetAvgMinFCT(ReadingCalculateDto inDto)
|
||||
{
|
||||
var allMinFCT = inDto.QuestionInfo.Where(x => x.LesionType == LesionType.FCT).SelectMany(x => x.TableRowInfoList).SelectMany(x => x.TableQuestionList)
|
||||
.Where(x => x.QuestionMark == QuestionMark.MinFCT).Select(x => x.Answer.IsNullOrEmptyReturn0()).Average();
|
||||
if (allMinFCT == 0)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
return allMinFCT;
|
||||
}
|
||||
|
||||
|
||||
#region 将上一次的访视病灶添加到这一次
|
||||
|
|
|
@ -2458,7 +2458,7 @@ public enum SUVChangeVSBaseline
|
|||
/// <summary>
|
||||
/// EEM求和
|
||||
/// </summary>
|
||||
EEMSun = 1005,
|
||||
EEMSum = 1005,
|
||||
|
||||
/// <summary>
|
||||
/// (EEM-Lumen)求和
|
||||
|
|
Loading…
Reference in New Issue