IRC_NewDev
he 2024-03-28 10:45:43 +08:00
parent 668e1019f0
commit c718ec8446
2 changed files with 10 additions and 5 deletions

View File

@ -14,10 +14,12 @@ namespace IRaCIS.Core.Application.Service.Reading.Dto
public Guid? SubjectId { get; set; }
/// <summary>
/// 项目中心Code
/// </summary>
public string? TrialSiteCode { get; set; }
public CompleteClinicalDataEnum? CompleteClinicalData { get; set; }
/// <summary>
/// 项目中心Code
/// </summary>
public string? TrialSiteCode { get; set; }
/// <summary>
/// 受试者Code

View File

@ -157,7 +157,10 @@ namespace IRaCIS.Application.Services
.WhereIf(dto.TrialSiteCode != null && dto.TrialSiteCode != string.Empty, x => x.TrialSiteCode.Contains(dto.TrialSiteCode))
.WhereIf(dto.SubjectCode != null && dto.SubjectCode != string.Empty, x => x.SubjectCode.Contains(dto.SubjectCode))
.WhereIf(dto.ModuleType != null, x => x.ModuleType == dto.ModuleType)
.WhereIf(dto.ReadingStatus != null, x => x.ReadingStatus == dto.ReadingStatus)
.WhereIf(dto.CompleteClinicalData==CompleteClinicalDataEnum.NA,x=>x.NeedSignClinicalDataCount==0)
.WhereIf(dto.CompleteClinicalData == CompleteClinicalDataEnum.NotComplete, x => x.NeedSignClinicalDataCount != x.SignClinicalDataCount)
.WhereIf(dto.CompleteClinicalData == CompleteClinicalDataEnum.Complete, x => x.NeedSignClinicalDataCount != 0 && x.NeedSignClinicalDataCount == x.SignClinicalDataCount)
.WhereIf(dto.ReadingStatus != null, x => x.ReadingStatus == dto.ReadingStatus)
.WhereIf(dto.Name != null, x => x.Name.Contains(dto.Name!)).OrderBy(x => x.SiteCode);
var subjectIds = await subjectQuery.OrderBy(dto.SortField).Select(x => x.SubjectId).Distinct().Skip((dto.PageIndex - 1) * dto.PageSize).Take(dto.PageSize).ToListAsync();