修改提示语言
parent
f6f6d421dd
commit
f0f99ce647
|
@ -87,7 +87,7 @@ namespace IRaCIS.Application.Services
|
|||
|
||||
if (!await _trialRepository.Where(t => t.Id == visitPlan.TrialId).IgnoreQueryFilters().AnyAsync(t => t.TrialStatusStr == StaticData.TrialOngoing || t.TrialStatusStr == StaticData.TrialInitializing))
|
||||
{
|
||||
throw new BusinessValidationFailedException(" only in Initializing or Ongoing State can operate ");
|
||||
throw new BusinessValidationFailedException("只有当项目状态为:初始化或进行中时,可以操作。 ");
|
||||
}
|
||||
|
||||
var visitPlanList = await _visitStageRepository.Where(t => t.TrialId == visitPlan.TrialId, ignoreQueryFilters: true)
|
||||
|
@ -104,7 +104,7 @@ namespace IRaCIS.Application.Services
|
|||
//比当前 visitNum小的 visitDay的最大值 还小 不允许添加
|
||||
if (visitPlan.VisitDay <= visitPlanList.Where(t => t.VisitNum < visitPlan.VisitNum).Select(t => t.VisitDay).Max())
|
||||
{
|
||||
throw new BusinessValidationFailedException(" For the visit plan, the VisitDay with a larger VisitNum should be larger than the VisitDay with a smaller VisitNum.");
|
||||
throw new BusinessValidationFailedException("访视计划中,访视号大的访视,其访视间隔也应该比访视号小的访视大。");
|
||||
|
||||
}
|
||||
}
|
||||
|
@ -113,7 +113,7 @@ namespace IRaCIS.Application.Services
|
|||
{
|
||||
if (visitPlan.VisitDay >= visitPlanList.Where(t => t.VisitNum > visitPlan.VisitNum).Select(t => t.VisitDay).Min())
|
||||
{
|
||||
throw new BusinessValidationFailedException("For the visit plan, the VisitDay with a larger VisitNum should be larger than the VisitDay with a smaller VisitNum.");
|
||||
throw new BusinessValidationFailedException("访视计划中,访视号大的计划访视,其访视间隔也应该比访视号小的计划访视大。");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -125,12 +125,12 @@ namespace IRaCIS.Application.Services
|
|||
|
||||
if (await _visitStageRepository.AnyAsync(t => t.TrialId == visitPlan.TrialId && (t.VisitName == visitPlan.VisitName || t.VisitNum == visitPlan.VisitNum), true))
|
||||
{
|
||||
throw new BusinessValidationFailedException("A visit with the same VisitName/VisitNum already existed in the current visit plan.");
|
||||
throw new BusinessValidationFailedException("访视计划中已经存在具有项目访视名称或者访视号的计划访视模板。");
|
||||
}
|
||||
|
||||
if (await _visitStageRepository.AnyAsync(t => t.TrialId == visitPlan.TrialId && t.IsBaseLine, true) && visitPlan.IsBaseLine)
|
||||
{
|
||||
throw new BusinessValidationFailedException("A visit already is baseline in the current visit plan.");
|
||||
throw new BusinessValidationFailedException("访视计划中已经存在基线。");
|
||||
}
|
||||
|
||||
//不用前端传递的值
|
||||
|
@ -157,12 +157,12 @@ namespace IRaCIS.Application.Services
|
|||
|
||||
if (await _visitStageRepository.AnyAsync(t => t.TrialId == visitPlan.TrialId && (t.VisitName == visitPlan.VisitName || t.VisitNum == visitPlan.VisitNum) && t.Id != visitPlan.Id, true))
|
||||
{
|
||||
throw new BusinessValidationFailedException("A visit with the same VisitName/VisitNum already existed in the current visit plan.");
|
||||
throw new BusinessValidationFailedException("访视计划中已经存在具有项目访视名称或者访视号的计划访视模板。");
|
||||
}
|
||||
|
||||
if (await _visitStageRepository.AnyAsync(t => t.TrialId == visitPlan.TrialId && t.IsBaseLine && t.Id != visitPlan.Id, true) && visitPlan.IsBaseLine)
|
||||
{
|
||||
throw new BusinessValidationFailedException("A visit already is baseline in the current visit plan.");
|
||||
throw new BusinessValidationFailedException("访视计划中已经存在基线。");
|
||||
}
|
||||
|
||||
#region 废弃前
|
||||
|
@ -195,7 +195,7 @@ namespace IRaCIS.Application.Services
|
|||
{
|
||||
if (await _repository.Where<SubjectVisit>(t => t.TrialId == visitPlan.TrialId).AnyAsync(v => v.IsBaseLine && v.SubmitState >= SubmitStateEnum.ToSubmit))
|
||||
{
|
||||
throw new BusinessValidationFailedException("有CRC已经为基线上传了影像数据,不允许修改基线");
|
||||
throw new BusinessValidationFailedException("有受试者的基线已经上传了影像数据,不允许修改基线访视。");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue