diff --git a/IRaCIS.Core.Application/Service/Document/DTO/SystemDocumentViewModel.cs b/IRaCIS.Core.Application/Service/Document/DTO/SystemDocumentViewModel.cs index dfc936450..0810dc8b5 100644 --- a/IRaCIS.Core.Application/Service/Document/DTO/SystemDocumentViewModel.cs +++ b/IRaCIS.Core.Application/Service/Document/DTO/SystemDocumentViewModel.cs @@ -109,6 +109,8 @@ namespace IRaCIS.Core.Application.Contracts public string Name { get; set; } = string.Empty; + public bool? IsSign { get; set; } + } public class UserConfirmCommand diff --git a/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs b/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs index 098f932fa..0527b640d 100644 --- a/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs +++ b/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs @@ -188,7 +188,9 @@ namespace IRaCIS.Core.Application.Services var unionQuery = systemDocumentQueryable.Union(trialDocQueryable) .WhereIf(!string.IsNullOrEmpty(querySystemDocument.Name), t => t.Name.Contains(querySystemDocument.Name)) - .WhereIf(querySystemDocument.FileTypeId != null, t => t.FileTypeId == querySystemDocument.FileTypeId); + .WhereIf(querySystemDocument.FileTypeId != null, t => t.FileTypeId == querySystemDocument.FileTypeId) + .WhereIf(querySystemDocument.IsSign == true, t => t.ConfirmUserId != null) + .WhereIf(querySystemDocument.IsSign == false, t => t.ConfirmUserId == null); return await unionQuery.ToPagedListAsync(querySystemDocument.PageIndex, querySystemDocument.PageSize, querySystemDocument.SortField, querySystemDocument.Asc); }