删除也计算病灶状态

IRC_NewDev
he 2024-03-04 14:31:44 +08:00
parent 4360f4b2cb
commit 5683ced93d
1 changed files with 19 additions and 3 deletions

View File

@ -1756,9 +1756,9 @@ namespace IRaCIS.Application.Services
{
await VerifyTaskIsSign(inDto.VisitTaskId);
var taskinfo = await _visitTaskRepository.Where(x => x.Id == inDto.VisitTaskId).Include(x => x.TrialReadingCriterion).FirstNotNullAsync();
var deleteRowInfo = await _readingTableAnswerRowInfoRepository.Where(x => x.Id == inDto.RowId).FirstOrDefaultAsync();
var deleteRowInfo = await _readingTableAnswerRowInfoRepository.Where(x => x.Id == inDto.RowId).FirstOrDefaultAsync();
if (deleteRowInfo == null)
{
@ -1903,7 +1903,23 @@ namespace IRaCIS.Application.Services
VisitTaskId = inDto.VisitTaskId,
ComputationTrigger=ComputationTrigger.Lesion,
});
return ResponseOutput.Ok(true);
switch (taskinfo.TrialReadingCriterion.CriterionType)
{
case CriterionType.Lugano2014:
if (deleteRowInfo.RowIndex % 1 != 0)
{
await _luganoCalculateService.CalculateTargetLesionStatus(new CalculateTargetLesionStatusInDto()
{
QuestionId = inDto.QuestionId,
VisitTaskId = inDto.VisitTaskId,
RowNumber = deleteRowInfo.RowIndex
});
}
break;
}
return ResponseOutput.Ok(true);
}