2020-01-02 12:02:48 +00:00
|
|
|
using System.Collections.Generic;
|
2020-01-21 09:07:10 +00:00
|
|
|
using System.Linq;
|
2020-01-02 12:02:48 +00:00
|
|
|
using Umbraco.Examine;
|
|
|
|
|
|
2020-01-21 09:07:10 +00:00
|
|
|
namespace Umbraco.Web.Search
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
2021-02-16 20:56:44 +13:00
|
|
|
public class UmbracoTreeSearcherFields : IUmbracoTreeSearcherFields2
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
2020-01-02 23:00:53 +00:00
|
|
|
private IReadOnlyList<string> _backOfficeFields = new List<string> {"id", "__NodeId", "__Key"};
|
|
|
|
|
public IEnumerable<string> GetBackOfficeFields()
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
|
|
|
|
return _backOfficeFields;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2020-01-02 23:00:53 +00:00
|
|
|
private IReadOnlyList<string> _backOfficeMembersFields = new List<string> {"email", "loginName"};
|
|
|
|
|
public IEnumerable<string> GetBackOfficeMembersFields()
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
|
|
|
|
return _backOfficeMembersFields;
|
|
|
|
|
}
|
2020-01-02 23:00:53 +00:00
|
|
|
private IReadOnlyList<string> _backOfficeMediaFields = new List<string> {UmbracoExamineIndex.UmbracoFileFieldName };
|
|
|
|
|
public IEnumerable<string> GetBackOfficeMediaFields()
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
|
|
|
|
return _backOfficeMediaFields;
|
|
|
|
|
}
|
2020-01-02 23:00:53 +00:00
|
|
|
public IEnumerable<string> GetBackOfficeDocumentFields()
|
2020-01-02 12:02:48 +00:00
|
|
|
{
|
2020-01-21 09:07:10 +00:00
|
|
|
return Enumerable.Empty<string>();
|
2020-01-02 12:02:48 +00:00
|
|
|
}
|
2021-02-16 20:56:44 +13:00
|
|
|
|
|
|
|
|
private readonly ISet<string> _backOfficeFieldsToLoad = new HashSet<string> { "id", "__NodeId", "__Key" };
|
|
|
|
|
public ISet<string> GetBackOfficeFieldsToLoad()
|
|
|
|
|
{
|
|
|
|
|
return _backOfficeFieldsToLoad;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private readonly ISet<string> _backOfficeMembersFieldsToLoad = new HashSet<string> { "id", "__NodeId", "__Key", "email", "loginName" };
|
|
|
|
|
public ISet<string> GetBackOfficeMembersFieldsToLoad()
|
|
|
|
|
{
|
|
|
|
|
return _backOfficeMembersFieldsToLoad;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
private readonly ISet<string> _backOfficeMediaFieldsToLoad = new HashSet<string> { "id", "__NodeId", "__Key", UmbracoExamineIndex.UmbracoFileFieldName };
|
|
|
|
|
public ISet<string> GetBackOfficeMediaFieldsToLoad()
|
|
|
|
|
{
|
|
|
|
|
return _backOfficeMediaFieldsToLoad;
|
|
|
|
|
}
|
|
|
|
|
private readonly ISet<string> _backOfficeDocumentFieldsToLoad = new HashSet<string> { "id", "__NodeId", "__Key" };
|
|
|
|
|
|
|
|
|
|
public ISet<string> GetBackOfficeDocumentFieldsToLoad()
|
|
|
|
|
{
|
|
|
|
|
return _backOfficeDocumentFieldsToLoad;
|
|
|
|
|
}
|
2020-01-02 12:02:48 +00:00
|
|
|
}
|
|
|
|
|
}
|