修改中心调研提示

IRC_NewDev
hang 2023-10-31 09:45:35 +08:00
parent 6a56132de9
commit 624bec0c88
1 changed files with 2 additions and 3 deletions

View File

@ -702,13 +702,12 @@ namespace IRaCIS.Core.Application.Contracts
var currentUserList = siteUserList.Where(t => t.TrialSiteSurveyId == trialSiteSurveyId).ToList();
if (!currentUserList.Any(t => t.UserTypeEnum == UserTypeEnum.ClinicalResearchCoordinator) ||
!currentUserList.Any(t => t.UserTypeEnum == UserTypeEnum.CRA))
if (!currentUserList.Any(t => t.UserTypeEnum == UserTypeEnum.ClinicalResearchCoordinator) )
{
throw new BusinessValidationFailedException(_localizer["TrialSiteSurvey_MissingAccount"]);
}
if (currentUserList.GroupBy(t => new { t.UserTypeId, t.Email })
if (currentUserList.Where(t=>t.IsGenerateAccount && t.UserTypeId!=null).GroupBy(t => new { t.UserTypeId, t.Email })
.Any(g => g.Count() > 1))
{
throw new BusinessValidationFailedException(_localizer["TrialSiteSurvey_DuplicateEmail"]);