添加doctor code
This commit is contained in:
@@ -178,6 +178,7 @@ namespace IRaCIS.Core.Application.Contracts
|
||||
isVirtual = await _trialRepository.Where(x => x.Id == inDto.TrialId).Select(x => x.TrialType != TrialType.OfficialTrial).FirstNotNullAsync();
|
||||
}
|
||||
|
||||
|
||||
Doctor doctor = new Doctor()
|
||||
{
|
||||
EMail = inDto.EmailOrPhone,
|
||||
@@ -190,6 +191,9 @@ namespace IRaCIS.Core.Application.Contracts
|
||||
ReviewStatus = ReviewerInformationConfirmStatus.ConfirmRefuse
|
||||
};
|
||||
|
||||
doctor.Code = await _doctorRepository.Select(t => t.Code).DefaultIfEmpty().MaxAsync() + 1;
|
||||
doctor.ReviewerCode= AppSettings.GetCodeStr(doctor.Code, nameof(Doctor));
|
||||
|
||||
var info = await _doctorRepository.AddAsync(doctor, true);
|
||||
|
||||
return new UseEmialGetDoctorInfoOutDto()
|
||||
@@ -260,7 +264,8 @@ namespace IRaCIS.Core.Application.Contracts
|
||||
|
||||
ReviewStatus = ReviewerInformationConfirmStatus.ConfirmRefuse
|
||||
};
|
||||
|
||||
doctor.Code = await _doctorRepository.Select(t => t.Code).DefaultIfEmpty().MaxAsync() + 1;
|
||||
doctor.ReviewerCode = AppSettings.GetCodeStr(doctor.Code, nameof(Doctor));
|
||||
var info = await _doctorRepository.AddAsync(doctor, true);
|
||||
|
||||
//await _userRoleRepository.BatchUpdateNoTrackingAsync(x => x.EMail == inDto.EmailOrPhone, x => new User()
|
||||
|
||||
Reference in New Issue
Block a user