From 494d0c53ae98f690186b383350505f597011bf8f Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Fri, 22 Jul 2022 13:53:45 +0800 Subject: [PATCH] x --- .../Service/Allocation/TaskAllocationRuleService.cs | 2 +- IRaCIS.Core.Domain/Allocation/TaskAllocationRule.cs | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Allocation/TaskAllocationRuleService.cs b/IRaCIS.Core.Application/Service/Allocation/TaskAllocationRuleService.cs index 94e9ff337..a29c5c110 100644 --- a/IRaCIS.Core.Application/Service/Allocation/TaskAllocationRuleService.cs +++ b/IRaCIS.Core.Application/Service/Allocation/TaskAllocationRuleService.cs @@ -68,7 +68,7 @@ namespace IRaCIS.Core.Application.Service [HttpDelete("{taskAllocationRuleId:guid}")] public async Task DeleteTaskAllocationRule(Guid taskAllocationRuleId) { - if (await _taskAllocationRuleRepository.Where(t => t.Id == taskAllocationRuleId).AnyAsync(t => t.DoctorVisitTaskList.Any())) + if (await _taskAllocationRuleRepository.Where(t => t.Id == taskAllocationRuleId).AnyAsync(t => t.Enroll.DoctorTrialVisitTaskList.Any())) { return ResponseOutput.NotOk("已分配任务给该医生,不允许删除"); } diff --git a/IRaCIS.Core.Domain/Allocation/TaskAllocationRule.cs b/IRaCIS.Core.Domain/Allocation/TaskAllocationRule.cs index 3788bd910..28f682b59 100644 --- a/IRaCIS.Core.Domain/Allocation/TaskAllocationRule.cs +++ b/IRaCIS.Core.Domain/Allocation/TaskAllocationRule.cs @@ -46,7 +46,6 @@ namespace IRaCIS.Core.Domain.Models public int PlanReadingRatio { get; set; } - public List DoctorVisitTaskList { get; set; } = new List();