国际化修改

This commit is contained in:
he
2023-04-25 14:37:10 +08:00
parent 79133ccde8
commit ac2fbc07dd
8 changed files with 101 additions and 28 deletions
@@ -272,7 +272,8 @@ namespace IRaCIS.Application.Services
if (await _readModuleRepository.AnyAsync(x => x.SubjectVisitId == visit.Id&&x.ModuleType== moduleType && x.TrialReadingCriterionId == dto.TrialReadingCriterionId))
{
throw new BusinessValidationFailedException($"当前访视已经添加过阅片期");
//---当前访视已经添加过阅片期
throw new BusinessValidationFailedException(_localizer["ReadModule_AlreadyAdded"]);
}
var readModuleData = new ReadModule()
{
@@ -383,7 +384,8 @@ namespace IRaCIS.Application.Services
}
else
{
return ResponseOutput.NotOk("请先添加全局阅片");
//---请先添加全局阅片
return ResponseOutput.NotOk(_localizer["ReadModule_AddGlobalFirst"]);
}
break;
}
@@ -392,7 +394,8 @@ namespace IRaCIS.Application.Services
}
else
{
return ResponseOutput.NotOk("未找到符合要求的访视");
//---未找到符合要求的访视
return ResponseOutput.NotOk(_localizer["ReadModule_VisitNotFound"]);
}
@@ -416,18 +419,21 @@ namespace IRaCIS.Application.Services
if(await _repository.Where<ReadingClinicalData>(t => t.ReadingId == readModuleId).AnyAsync(t => t.ReadingClinicalDataState == ReadingClinicalDataStatus.HaveSigned))
{
return ResponseOutput.NotOk("临床资料已签名,不允许删除");
//---临床资料已签名,不允许删除
return ResponseOutput.NotOk(_localizer["ReadModule_SignedDataCannotDelete"]);
}
//增加标准
if (readModule.ModuleType==ModuleTypeEnum.Global&&(await _readModuleRepository.AnyAsync(x=>x.ModuleType==ModuleTypeEnum.Oncology&&x.SubjectVisitId== readModule.SubjectVisitId && x.TrialReadingCriterionId==readModule.TrialReadingCriterionId)))
{
throw new BusinessValidationFailedException("当前访视存在肿瘤学阅片,请先删除肿瘤学阅片");
//---当前访视存在肿瘤学阅片,请先删除肿瘤学阅片
throw new BusinessValidationFailedException(_localizer["ReadModule_TumorExists"]);
}
if (await _visitTaskRepository.AnyAsync(x => readModuleId==x.SouceReadModuleId))
{
throw new BusinessValidationFailedException("当前阅片已生成任务,操作失败。");
//---当前阅片已生成任务,操作失败。
throw new BusinessValidationFailedException(_localizer["ReadModule_TaskGenerated"]);
}