田爽 1 năm trước cách đây
mục cha
commit
50376a4f0c
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      src/Hotline.Api/Controllers/KnowledgeController.cs

+ 1 - 1
src/Hotline.Api/Controllers/KnowledgeController.cs

@@ -461,7 +461,7 @@ namespace Hotline.Api.Controllers
 				.Includes(x=>x.SourceOrganize)
 				.Where(x => x.IsDeleted == false)
 				.WhereIF(!string.IsNullOrEmpty(pagedDto.Title), x => x.Title.Contains(pagedDto.Title!))
-				.WhereIF(pagedDto.Status.HasValue, x => x.Status == pagedDto.Status && x.ExpiredTime != null  && x.ExpiredTime > DateTime.Now)
+				.WhereIF(pagedDto.Status.HasValue, x => x.Status == pagedDto.Status && ((x.ExpiredTime != null  && x.ExpiredTime > DateTime.Now)|| x.ExpiredTime == null))
 				.WhereIF(pagedDto.IsPublic.HasValue, x => x.IsPublic == pagedDto.IsPublic)
 				.WhereIF(!string.IsNullOrEmpty(pagedDto.Summary), x => x.Summary != null && x.Summary.Contains(pagedDto.Summary!))
 				.WhereIF(!string.IsNullOrEmpty(typeSpliceName), x => x.KnowledgeType.SpliceName.EndsWith(typeSpliceName!))