Last active
July 22, 2022 06:51
-
-
Save cuiliang/8475a0b5420a78bfff52c8030450329a to your computer and use it in GitHub Desktop.
动作搜索结果对象
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace Quicker.Public.Entities | |
{ | |
/// <summary> | |
/// 通用条目 | |
/// </summary> | |
public class CommonOperationItem | |
{ | |
/// <summary> | |
/// 标题文字,用于显示 | |
/// </summary> | |
public string Title { get; set; } | |
/// <summary> | |
/// 描述文字,通常显示为tooltip | |
/// </summary> | |
public string Description { get; set; } | |
/// <summary> | |
/// 图标,格式请参考文档说明。 | |
/// </summary> | |
public string Icon { get; set; } | |
/// <summary> | |
/// 角标图标,仅用于搜索框结果项,格式请参考文档说明。 | |
/// </summary> | |
public string SecondaryIcon { get; set; } | |
/// <summary> | |
/// 数据内容 | |
/// </summary> | |
public string Data { get; set; } | |
/// <summary> | |
/// 内部数据类型 | |
/// </summary> | |
public string DataType { get; set; } | |
/// <summary> | |
/// 通常用于保存对Data内容的操作类型。 | |
/// <see cref="CommonOperationTypes">通用操作类型</see> | |
/// </summary> | |
public string Operation { get; set; } | |
/// <summary> | |
/// 要触发的动作id或名称 | |
/// </summary> | |
public string Action { get; set; } | |
/// <summary> | |
/// 是否是分隔线 | |
/// </summary> | |
public bool IsSeparator { get; set; } | |
/// <summary> | |
/// 扩展数据 | |
/// </summary> | |
public IDictionary<string, object> ExtraData { get; set; } | |
/// <summary> | |
/// 子项,也可做子菜单使用 | |
/// </summary> | |
public IList<CommonOperationItem> Children { get; set; } | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
namespace Quicker.Public.Searching | |
{ | |
/// <summary> | |
/// 自定义搜索结果 | |
/// </summary> | |
public class CustomSearchResult | |
{ | |
/// <summary> | |
/// 结果项 | |
/// </summary> | |
public IList<CustomSearchResultItem> Items { get; set; } | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using Quicker.Public.Entities; | |
namespace Quicker.Public.Searching | |
{ | |
/// <summary> | |
/// 自定义搜索结果项 | |
/// </summary> | |
public class CustomSearchResultItem: CommonOperationItem | |
{ | |
/// <summary> | |
/// 匹配度评分 | |
/// </summary> | |
public int Score { get; set; } | |
/// <summary> | |
/// 是否不隐藏搜索框 | |
/// </summary> | |
public bool NoHide { get; set; } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment