/// <summary> /// 管理词条的权限 /// </summary> public static bool Page_Manage(this Authorizer authorizer, WikiPage page) { if (authorizer.IsAdministrator(WikiConfig.Instance().ApplicationId)) { return(true); } return(false); }
/// <summary> /// 构造函数 /// </summary> /// <param name="name">Searcher名称</param> /// <param name="indexPath">索引文件所在路径(支持"~/"及unc路径)</param> /// <param name="asQuickSearch">是否作为快捷搜索</param> /// <param name="displayOrder">显示顺序</param> public WikiSearcher(string name, string indexPath, bool asQuickSearch, int displayOrder) { this.Name = name; this.IndexPath = Tunynet.Utilities.WebUtility.GetPhysicalFilePath(indexPath); this.AsQuickSearch = asQuickSearch; this.DisplayOrder = displayOrder; searchEngine = SearcherFactory.GetSearchEngine(indexPath); publiclyAuditStatus = auditService.GetPubliclyAuditStatus(WikiConfig.Instance().ApplicationId); }
/// <summary> /// 编辑词条版本数 /// </summary> public static string EditionCount(this OwnerDataKeys ownerDataKeys) { return(WikiConfig.Instance().ApplicationKey + "-EditionCount"); }