2017-09-12 16:22:16 +02:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Runtime.Serialization;
|
|
|
|
|
|
using Examine;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web.Models.ContentEditing
|
|
|
|
|
|
{
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Represents a search result by entity type
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[DataContract(Name = "searchResult", Namespace = "")]
|
|
|
|
|
|
public class TreeSearchResult
|
|
|
|
|
|
{
|
|
|
|
|
|
[DataMember(Name = "appAlias")]
|
|
|
|
|
|
public string AppAlias { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
[DataMember(Name = "treeAlias")]
|
|
|
|
|
|
public string TreeAlias { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
2017-09-23 10:08:18 +02:00
|
|
|
|
/// This is optional but if specified should be the name of an angular service to format the search result.
|
|
|
|
|
|
/// </summary>
|
2017-09-12 16:22:16 +02:00
|
|
|
|
[DataMember(Name = "jsSvc")]
|
|
|
|
|
|
public string JsFormatterService { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// This is optional but if specified should be the name of a method on the jsSvc angular service to use, if not
|
|
|
|
|
|
/// specfied than it will expect the method to be called `format(searchResult, appAlias, treeAlias)`
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
[DataMember(Name = "jsMethod")]
|
|
|
|
|
|
public string JsFormatterMethod { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
[DataMember(Name = "results")]
|
|
|
|
|
|
public IEnumerable<SearchResultItem> Results { get; set; }
|
|
|
|
|
|
}
|
2017-09-23 10:08:18 +02:00
|
|
|
|
}
|