Skip to content

Enable More Sort By Options #1523

@JPKribs

Description

@JPKribs

Describe the feature you'd like
As of 10.10, the enum for ItemSortBy offers a lot more options for ordering content. The issue is that not all ItemSortBy work with each BaseItemKind (I think). It would be nice to increase the number of ItemSortBy options based on BaseItemKind or whatever limiting factor exists.

An example is sorting Movies based on .similarityScore results in a 500 Error. My guess is this ItemSortBy is only supposed to be used for "Recommended" sections.

Additionally might be good to move from defaulting from .sortName to .default but in testing I don't know what the difference is.

Additional context
In ItemSortBy we have the following options:

    .default
    .airedEpisodeOrder
    .album
    .albumArtist
    .artist
    .dateCreated
    .officialRating
    .datePlayed
    .premiereDate
    .startDate
    .sortName
    .name
    .random
    .runtime
    .communityRating
    .productionYear
    .playCount
    .criticRating
    .isFolder
    .isUnplayed
    .isPlayed
    .seriesSortName
    .videoBitRate
    .airTime
    .studio
    .isFavoriteOrLiked
    .dateLastContentAdded
    .seriesDatePlayed
    .parentIndexNumber
    .indexNumber
    .similarityScore
    .searchScore

Of these, only the following are enabled Swiftfin:

    .premiereDate
    .name
    .sortName
    .dateLastContentAdded
    .random

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestlow-priorityProblem or feature does not require immediate attention

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions