Updates search published content search extensions to correspond with new examine api changes, updates examine api changes

This commit is contained in:
Shannon
2018-12-17 12:17:03 +11:00
parent 4a23a6d3d0
commit 4976782247
19 changed files with 79 additions and 170 deletions

View File

@@ -490,9 +490,7 @@ namespace Umbraco.Web.Search
while (page * pageSize < total)
{
//paging with examine, see https://shazwazza.com/post/paging-with-examine/
var results = searcher.Search(
searcher.CreateCriteria().Field("nodeType", id).Compile(),
maxResults: pageSize * (page + 1));
var results = searcher.CreateQuery().Field("nodeType", id).Execute(maxResults: pageSize * (page + 1));
total = results.TotalItemCount;
var paged = results.Skip(page * pageSize);