问题修改
continuous-integration/drone/push Build is passing

This commit is contained in:
he
2024-11-25 16:11:06 +08:00
parent 8ebaface32
commit 27314a139d
6 changed files with 18354 additions and 1 deletions
@@ -124,9 +124,15 @@ namespace IRaCIS.Core.Application.Service
}
else
{
// 先添加
await GetTrialDoctorInfo(new GetTrialDoctorInfoInDto()
{
DoctorId = inDto.DoctorId,
TrialId = inDto.TrialId.Value,
});
// 当前项目没有则复制
if (!(await _trialExperienceRepository.AnyAsync(x => x.TrialId == inDto.TrialId&&x.DoctorId==inDto.DoctorId &&x.ExperienceDataType== ExperienceDataType.Trial))
&&!(await _doctorRepository.AnyAsync(x => x.TrialId == inDto.TrialId && x.DoctorId == inDto.DoctorId))
&&!(await _doctorRepository.AnyAsync(x => x.TrialId == inDto.TrialId && x.IsAddTrialExperienceToTrial==false && x.DoctorId == inDto.DoctorId))
)
{
var trialExperienceList = await _trialExperienceRepository.Where(o => o.DoctorId == inDto.DoctorId)
@@ -151,6 +157,11 @@ namespace IRaCIS.Core.Application.Service
}
await _trialExperienceCriteriaRepository.AddRangeAsync(criteriaList);
await _trialExperienceRepository.AddRangeAsync(trialExperienceList);
await _doctorRepository.BatchUpdateNoTrackingAsync(x => x.DoctorId == inDto.DoctorId && x.TrialId == inDto.TrialId, x => new Doctor()
{
IsAddTrialExperienceToTrial=true
});
await _trialExperienceRepository.SaveChangesAsync();
}