添加中心增加验证
continuous-integration/drone/push Build is passing Details

Uat_IRC_Net8
hang 2025-01-20 11:33:48 +08:00
parent 036565ec81
commit 013b9720b3
1 changed files with 6 additions and 0 deletions

View File

@ -169,6 +169,12 @@ namespace IRaCIS.Core.Application.Services
{
item.EnabledTime = DateTime.Now;
}
if (await _trialSiteRepository.AnyAsync(t => t.TrialSiteCode == item.TrialSiteCode && t.TrialId == item.TrialId))
{
//---Code is not allowed to be repeated
return ResponseOutput.NotOk(_localizer["TrialSite_CodeDuplicate"]);
}
}
await _trialSiteRepository.AddRangeAsync(addArray);