Compare commits
No commits in common. "cdadad9ec53e9e841a9ed2690339cab822572129" and "658f9c7c404d003b1acef48f27eb02bb0d30cd1c" have entirely different histories.
cdadad9ec5
...
658f9c7c40
|
|
@ -310,6 +310,7 @@ namespace IRaCIS.Core.Application.Service
|
||||||
GlobalVisitTaskId = taskList[0].Id,
|
GlobalVisitTaskId = taskList[0].Id,
|
||||||
JudgeQuestionList = item.AfterQuestionList.Where(x => x.GlobalAnswerType == GlobalAnswerType.Question).Select(x => new JudgeQuestion()
|
JudgeQuestionList = item.AfterQuestionList.Where(x => x.GlobalAnswerType == GlobalAnswerType.Question).Select(x => new JudgeQuestion()
|
||||||
{
|
{
|
||||||
|
|
||||||
Answer = x.Answer,
|
Answer = x.Answer,
|
||||||
Type = x.Type,
|
Type = x.Type,
|
||||||
Unit = x.Unit,
|
Unit = x.Unit,
|
||||||
|
|
@ -346,10 +347,12 @@ namespace IRaCIS.Core.Application.Service
|
||||||
var rTwoJudge = new JudgeReadingQuestion()
|
var rTwoJudge = new JudgeReadingQuestion()
|
||||||
{
|
{
|
||||||
ArmEnum = twoItem.ArmEnum,
|
ArmEnum = twoItem.ArmEnum,
|
||||||
|
|
||||||
VisitTaskId = twoItem.VisitTaskId,
|
VisitTaskId = twoItem.VisitTaskId,
|
||||||
GlobalVisitTaskId = taskList[1].Id,
|
GlobalVisitTaskId = taskList[1].Id,
|
||||||
JudgeQuestionList = twoItem.AfterQuestionList.Where(x => x.GlobalAnswerType == GlobalAnswerType.Question).Select(x => new JudgeQuestion()
|
JudgeQuestionList = twoItem.AfterQuestionList.Where(x => x.GlobalAnswerType == GlobalAnswerType.Question).Select(x => new JudgeQuestion()
|
||||||
{
|
{
|
||||||
|
|
||||||
Answer = x.Answer,
|
Answer = x.Answer,
|
||||||
Type = x.Type,
|
Type = x.Type,
|
||||||
Unit = x.Unit,
|
Unit = x.Unit,
|
||||||
|
|
@ -394,7 +397,6 @@ namespace IRaCIS.Core.Application.Service
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// NA 问题答案不显示
|
|
||||||
switch (visitTask.TrialReadingCriterion.CriterionType)
|
switch (visitTask.TrialReadingCriterion.CriterionType)
|
||||||
{
|
{
|
||||||
case CriterionType.IVUS:
|
case CriterionType.IVUS:
|
||||||
|
|
@ -972,14 +974,23 @@ namespace IRaCIS.Core.Application.Service
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
case JudgeTypeEnum.DifferenceAbsoluteValue:
|
case JudgeTypeEnum.DifferenceAbsoluteValue:
|
||||||
|
|
||||||
var answer1 = taskAnswer1.IsNullOrEmptyReturnNull();
|
var answer1 = taskAnswer1.IsNullOrEmptyReturnNull();
|
||||||
var answer2 = taskAnswer2.IsNullOrEmptyReturnNull();
|
var answer2 = taskAnswer2.IsNullOrEmptyReturnNull();
|
||||||
|
|
||||||
// 已经判断不相等了 所以只可能有一个为Null
|
// 已经判断不相等了 所以只可能有一个为Null
|
||||||
if (answer1 == null || answer2 == null)
|
if (answer1 == null || answer2 == null)
|
||||||
{
|
{
|
||||||
noteEqual = true;
|
noteEqual = true;
|
||||||
}
|
}
|
||||||
var deffaultValue = Math.Abs(taskAnswer1.IsNullOrEmptyReturn0() - taskAnswer2.IsNullOrEmptyReturn0());
|
|
||||||
|
var deffaultValue = taskAnswer1.IsNullOrEmptyReturn0() - taskAnswer2.IsNullOrEmptyReturn0();
|
||||||
|
if (deffaultValue < 0)
|
||||||
|
{
|
||||||
|
deffaultValue = 0 - deffaultValue;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
if (item.JudgeDifferenceType == JudgeDifferenceType.Greater)
|
if (item.JudgeDifferenceType == JudgeDifferenceType.Greater)
|
||||||
{
|
{
|
||||||
if (deffaultValue > item.JudgeDifferenceValue)
|
if (deffaultValue > item.JudgeDifferenceValue)
|
||||||
|
|
@ -994,15 +1005,22 @@ namespace IRaCIS.Core.Application.Service
|
||||||
noteEqual = true;
|
noteEqual = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case JudgeTypeEnum.PercentageDifference:
|
case JudgeTypeEnum.PercentageDifference:
|
||||||
|
|
||||||
|
|
||||||
var answer1P = taskAnswer1.IsNullOrEmptyReturnNull();
|
var answer1P = taskAnswer1.IsNullOrEmptyReturnNull();
|
||||||
var answer2P = taskAnswer2.IsNullOrEmptyReturnNull();
|
var answer2P = taskAnswer2.IsNullOrEmptyReturnNull();
|
||||||
|
|
||||||
// 已经判断不相等了 所以只可能有一个为Null
|
// 已经判断不相等了 所以只可能有一个为Null
|
||||||
if (answer1P == null || answer2P == null)
|
if (answer1P == null || answer2P == null)
|
||||||
{
|
{
|
||||||
noteEqual = true;
|
noteEqual = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
var value1 = taskAnswer1.IsNullOrEmptyReturn0();
|
var value1 = taskAnswer1.IsNullOrEmptyReturn0();
|
||||||
var value2 = taskAnswer2.IsNullOrEmptyReturn0();
|
var value2 = taskAnswer2.IsNullOrEmptyReturn0();
|
||||||
if (value1 == 0 || value2 == 0)
|
if (value1 == 0 || value2 == 0)
|
||||||
|
|
@ -1011,16 +1029,36 @@ namespace IRaCIS.Core.Application.Service
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var absoluteValue = (Math.Abs(value1 - value2)*100)/(value1<value2?value1:value2) ;
|
|
||||||
if (item.JudgeDifferenceType == JudgeDifferenceType.Greater)
|
if (item.JudgeDifferenceType == JudgeDifferenceType.Greater)
|
||||||
{
|
{
|
||||||
noteEqual= absoluteValue > item.JudgeDifferenceValue;
|
if (value1 < value2)
|
||||||
|
{
|
||||||
|
noteEqual = (value2 - value1) * 100 / value1 > item.JudgeDifferenceValue;
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
noteEqual = (value1 - value2) * 100 / value2 > item.JudgeDifferenceValue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (item.JudgeDifferenceType == JudgeDifferenceType.AboveOrEqual)
|
else if (item.JudgeDifferenceType == JudgeDifferenceType.AboveOrEqual)
|
||||||
{
|
{
|
||||||
noteEqual= absoluteValue >= item.JudgeDifferenceValue;
|
if (value1 < value2)
|
||||||
|
{
|
||||||
|
noteEqual = (value2 - value1) * 100 / value1 >= item.JudgeDifferenceValue;
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
noteEqual = (value1 - value2) * 100 / value2 >= item.JudgeDifferenceValue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue