增加项目Id 查询条件

IRC_NewDev
hang 2024-07-16 16:09:22 +08:00
parent 6e7545be65
commit 5041ebd58b
2 changed files with 4 additions and 1 deletions

View File

@ -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<string> CalledAEList { get; set; } = new List<string>();

View File

@ -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))