修复入组bug

This commit is contained in:
2022-07-26 13:04:54 +08:00
parent 6e4788e27b
commit 839d72f05a
7 changed files with 13 additions and 7 deletions
@@ -72,7 +72,7 @@ namespace IRaCIS.Core.Application.Service
[HttpDelete("{taskAllocationRuleId:guid}")]
public async Task<IResponseOutput> DeleteTaskAllocationRule(Guid taskAllocationRuleId)
{
if (await _taskAllocationRuleRepository.Where(t => t.Id == taskAllocationRuleId).AnyAsync(t => t.Enroll.DoctorTrialVisitTaskList.Any()))
if (await _taskAllocationRuleRepository.Where(t => t.Id == taskAllocationRuleId).AnyAsync(t => t.DoctorUser.VisitTaskList.Any()))
{
return ResponseOutput.NotOk("已分配任务给该医生,不允许删除");
}