aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Model
diff options
context:
space:
mode:
authorCody Robibero <cody@robibe.ro>2023-11-09 14:00:13 -0700
committerGitHub <noreply@github.com>2023-11-09 14:00:13 -0700
commitc7a94d48ae019f41d5f06340bca7efe0788ad5ad (patch)
treeaa7ade175cb8163e32f5a159efe7613bd2b1254d /MediaBrowser.Model
parent21878577beefc9b71f21c64e26162daaa083ded2 (diff)
Convert ItemSortBy to enum (#9765)
* Convert ItemSortBy to enum * Rename Unknown to Default
Diffstat (limited to 'MediaBrowser.Model')
-rw-r--r--MediaBrowser.Model/LiveTv/LiveTvChannelQuery.cs4
-rw-r--r--MediaBrowser.Model/Querying/ItemSortBy.cs163
2 files changed, 2 insertions, 165 deletions
diff --git a/MediaBrowser.Model/LiveTv/LiveTvChannelQuery.cs b/MediaBrowser.Model/LiveTv/LiveTvChannelQuery.cs
index 673d97a9e..d872572b7 100644
--- a/MediaBrowser.Model/LiveTv/LiveTvChannelQuery.cs
+++ b/MediaBrowser.Model/LiveTv/LiveTvChannelQuery.cs
@@ -14,7 +14,7 @@ namespace MediaBrowser.Model.LiveTv
public LiveTvChannelQuery()
{
EnableUserData = true;
- SortBy = Array.Empty<string>();
+ SortBy = Array.Empty<ItemSortBy>();
}
/// <summary>
@@ -99,7 +99,7 @@ namespace MediaBrowser.Model.LiveTv
public bool? IsSeries { get; set; }
- public string[] SortBy { get; set; }
+ public ItemSortBy[] SortBy { get; set; }
/// <summary>
/// Gets or sets the sort order to return results with.
diff --git a/MediaBrowser.Model/Querying/ItemSortBy.cs b/MediaBrowser.Model/Querying/ItemSortBy.cs
deleted file mode 100644
index 1a7c9a63b..000000000
--- a/MediaBrowser.Model/Querying/ItemSortBy.cs
+++ /dev/null
@@ -1,163 +0,0 @@
-namespace MediaBrowser.Model.Querying
-{
- /// <summary>
- /// These represent sort orders that are known by the core.
- /// </summary>
- public static class ItemSortBy
- {
- /// <summary>
- /// The aired episode order.
- /// </summary>
- public const string AiredEpisodeOrder = "AiredEpisodeOrder";
-
- /// <summary>
- /// The album.
- /// </summary>
- public const string Album = "Album";
-
- /// <summary>
- /// The album artist.
- /// </summary>
- public const string AlbumArtist = "AlbumArtist";
-
- /// <summary>
- /// The artist.
- /// </summary>
- public const string Artist = "Artist";
-
- /// <summary>
- /// The date created.
- /// </summary>
- public const string DateCreated = "DateCreated";
-
- /// <summary>
- /// The official rating.
- /// </summary>
- public const string OfficialRating = "OfficialRating";
-
- /// <summary>
- /// The date played.
- /// </summary>
- public const string DatePlayed = "DatePlayed";
-
- /// <summary>
- /// The premiere date.
- /// </summary>
- public const string PremiereDate = "PremiereDate";
-
- /// <summary>
- /// The start date.
- /// </summary>
- public const string StartDate = "StartDate";
-
- /// <summary>
- /// The sort name.
- /// </summary>
- public const string SortName = "SortName";
-
- /// <summary>
- /// The name.
- /// </summary>
- public const string Name = "Name";
-
- /// <summary>
- /// The random.
- /// </summary>
- public const string Random = "Random";
-
- /// <summary>
- /// The runtime.
- /// </summary>
- public const string Runtime = "Runtime";
-
- /// <summary>
- /// The community rating.
- /// </summary>
- public const string CommunityRating = "CommunityRating";
-
- /// <summary>
- /// The production year.
- /// </summary>
- public const string ProductionYear = "ProductionYear";
-
- /// <summary>
- /// The play count.
- /// </summary>
- public const string PlayCount = "PlayCount";
-
- /// <summary>
- /// The critic rating.
- /// </summary>
- public const string CriticRating = "CriticRating";
-
- /// <summary>
- /// The IsFolder boolean.
- /// </summary>
- public const string IsFolder = "IsFolder";
-
- /// <summary>
- /// The IsUnplayed boolean.
- /// </summary>
- public const string IsUnplayed = "IsUnplayed";
-
- /// <summary>
- /// The IsPlayed boolean.
- /// </summary>
- public const string IsPlayed = "IsPlayed";
-
- /// <summary>
- /// The series sort.
- /// </summary>
- public const string SeriesSortName = "SeriesSortName";
-
- /// <summary>
- /// The video bitrate.
- /// </summary>
- public const string VideoBitRate = "VideoBitRate";
-
- /// <summary>
- /// The air time.
- /// </summary>
- public const string AirTime = "AirTime";
-
- /// <summary>
- /// The studio.
- /// </summary>
- public const string Studio = "Studio";
-
- /// <summary>
- /// The IsFavouriteOrLiked boolean.
- /// </summary>
- public const string IsFavoriteOrLiked = "IsFavoriteOrLiked";
-
- /// <summary>
- /// The last content added date.
- /// </summary>
- public const string DateLastContentAdded = "DateLastContentAdded";
-
- /// <summary>
- /// The series last played date.
- /// </summary>
- public const string SeriesDatePlayed = "SeriesDatePlayed";
-
- /// <summary>
- /// The parent index number.
- /// </summary>
- public const string ParentIndexNumber = "ParentIndexNumber";
-
- /// <summary>
- /// The index number.
- /// </summary>
- public const string IndexNumber = "IndexNumber";
-
- /// <summary>
- /// The similarity score.
- /// </summary>
- public const string SimilarityScore = "SimilarityScore";
-
- /// <summary>
- /// The search score.
- /// </summary>
- public const string SearchScore = "SearchScore";
- }
-}