mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-06-04 06:04:25 -04:00
Remoed configurationPageType
This commit is contained in:
parent
8ef37f6b0e
commit
a4e838fbf5
@ -51,7 +51,6 @@ namespace Jellyfin.Api.Controllers
|
|||||||
/// Gets the configuration pages.
|
/// Gets the configuration pages.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="enableInMainMenu">Whether to enable in the main menu.</param>
|
/// <param name="enableInMainMenu">Whether to enable in the main menu.</param>
|
||||||
/// <param name="pageType">The <see cref="ConfigurationPageInfo"/>.</param>
|
|
||||||
/// <response code="200">ConfigurationPages returned.</response>
|
/// <response code="200">ConfigurationPages returned.</response>
|
||||||
/// <response code="404">Server still loading.</response>
|
/// <response code="404">Server still loading.</response>
|
||||||
/// <returns>An <see cref="IEnumerable{ConfigurationPageInfo}"/> with infos about the plugins.</returns>
|
/// <returns>An <see cref="IEnumerable{ConfigurationPageInfo}"/> with infos about the plugins.</returns>
|
||||||
@ -59,16 +58,10 @@ namespace Jellyfin.Api.Controllers
|
|||||||
[ProducesResponseType(StatusCodes.Status200OK)]
|
[ProducesResponseType(StatusCodes.Status200OK)]
|
||||||
[ProducesResponseType(StatusCodes.Status404NotFound)]
|
[ProducesResponseType(StatusCodes.Status404NotFound)]
|
||||||
public ActionResult<IEnumerable<ConfigurationPageInfo?>> GetConfigurationPages(
|
public ActionResult<IEnumerable<ConfigurationPageInfo?>> GetConfigurationPages(
|
||||||
[FromQuery] bool? enableInMainMenu,
|
[FromQuery] bool? enableInMainMenu)
|
||||||
[FromQuery] ConfigurationPageType? pageType)
|
|
||||||
{
|
{
|
||||||
var configPages = _pluginManager.Plugins.SelectMany(GetConfigPages).ToList();
|
var configPages = _pluginManager.Plugins.SelectMany(GetConfigPages).ToList();
|
||||||
|
|
||||||
if (pageType.HasValue)
|
|
||||||
{
|
|
||||||
configPages = configPages.Where(p => p!.ConfigurationPageType == pageType).ToList();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (enableInMainMenu.HasValue)
|
if (enableInMainMenu.HasValue)
|
||||||
{
|
{
|
||||||
configPages = configPages.Where(p => p!.EnableInMainMenu == enableInMainMenu.Value).ToList();
|
configPages = configPages.Where(p => p!.EnableInMainMenu == enableInMainMenu.Value).ToList();
|
||||||
|
@ -51,12 +51,6 @@ namespace Jellyfin.Api.Models
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public string? DisplayName { get; set; }
|
public string? DisplayName { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// Gets or sets the type of the configuration page.
|
|
||||||
/// </summary>
|
|
||||||
/// <value>The type of the configuration page.</value>
|
|
||||||
public ConfigurationPageType ConfigurationPageType { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the plugin id.
|
/// Gets or sets the plugin id.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
@ -1,21 +0,0 @@
|
|||||||
using System.IO;
|
|
||||||
using MediaBrowser.Common.Plugins;
|
|
||||||
|
|
||||||
namespace MediaBrowser.Controller.Plugins
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// Enum ConfigurationPageType.
|
|
||||||
/// </summary>
|
|
||||||
public enum ConfigurationPageType
|
|
||||||
{
|
|
||||||
/// <summary>
|
|
||||||
/// The plugin configuration.
|
|
||||||
/// </summary>
|
|
||||||
PluginConfiguration,
|
|
||||||
|
|
||||||
/// <summary>
|
|
||||||
/// The none.
|
|
||||||
/// </summary>
|
|
||||||
None
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user