feat: Sort Order for Series categories#1067
Merged
Conversation
Mirrors the Live and VOD Group resources so users can manually order Series categories. Series Categories already stored sort_order and the XtreamApiController already sorted output by it; this just exposes the field for editing. Closes m3ue#1023
Live and VOD already order by sort_order on the regular (non-custom) playlist branch. The series branch plucked categories in insertion order, so manual reordering had no effect on clients like TiVimate. Aligns behavior across Live, VOD, and Series.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #1023.
Brings Series categories to parity with Live and VOD groups for sort ordering:
Sort Ordercolumn (inline-editable) and form field to the Series → Categories resource, mirroring the existingGroupResource/VodGroupResourcelayout. Drag-to-reorder already worked; this just exposes the value for direct editing.get_series_categorieson regular playlists / aliases now appliessortBy('sort_order'), so clients like TiVimate honor the custom order. Live and VOD already did this; series was the lone exception.The
categories.sort_ordercolumn itself already existed (default9999), so no migration is needed. Existingauto_sortimport behavior is untouched — it only ever applied to Live/VOD groups, and that hasn't changed.Notes
Category sort order(no auto-sort warning), sinceauto_sortdoesn't currently overwrite series categories during import.Test plan
Sort Ordercolumn appears, edits persist, drag-reorder still worksSort Orderfield is on the form and savesplayer_api.php?action=get_series_categorieson a regular playlist with reordered categories: confirm response order matchessort_orderASC