From 5041ebd58bf6df8e1af6434456098decf62620a1 Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Tue, 16 Jul 2024 16:09:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A1=B9=E7=9B=AEId=20?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E6=9D=A1=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IRaCIS.Core.Application/Service/Visit/DTO/PatientViewModel.cs | 3 +++ IRaCIS.Core.Application/Service/Visit/PatientService.cs | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/IRaCIS.Core.Application/Service/Visit/DTO/PatientViewModel.cs b/IRaCIS.Core.Application/Service/Visit/DTO/PatientViewModel.cs index 0c3c515f8..3c257e873 100644 --- a/IRaCIS.Core.Application/Service/Visit/DTO/PatientViewModel.cs +++ b/IRaCIS.Core.Application/Service/Visit/DTO/PatientViewModel.cs @@ -222,6 +222,9 @@ namespace IRaCIS.Application.Contracts public class PatientTrialQuery : PageInput { + [NotDefault] + public Guid TrialId { get; set; } + public string? PatientIdStr { get; set; } public string? PatientName { get; set; } //public List CalledAEList { get; set; } = new List(); diff --git a/IRaCIS.Core.Application/Service/Visit/PatientService.cs b/IRaCIS.Core.Application/Service/Visit/PatientService.cs index 1f0468c0e..572ffef2b 100644 --- a/IRaCIS.Core.Application/Service/Visit/PatientService.cs +++ b/IRaCIS.Core.Application/Service/Visit/PatientService.cs @@ -106,7 +106,7 @@ namespace IRaCIS.Application.Services #region new ok - var query = _patientRepository + var query = _patientRepository.Where(t=>t.TrialId==inQuery.TrialId) .WhereIf(!string.IsNullOrWhiteSpace(inQuery.PatientIdStr), t => t.PatientIdStr.Contains(inQuery.PatientIdStr)) .WhereIf(!string.IsNullOrWhiteSpace(inQuery.PatientName), t => t.PatientName.Contains(inQuery.PatientName)) .WhereIf(!string.IsNullOrWhiteSpace(inQuery.SubejctCode), t => t.Subject.Code.Contains(inQuery.SubejctCode))