Forums Feature Requests Thread

[Enhancement] Files, photos, gallery, ansi: Photos cannot be reordered within an album (sort_order exists but is never user-settable)

Patrick Bass · Jun 6 · 15 · 1 Locked
[High Priority] [Feature Enhancement] [Deployed to Production]
🚀 OP Jun 6, 2026 6:00pm

Area: Files, photos, gallery, ansi (audit p5) · Surface: Photo album (/photos/album/{id}) · Dimension: improve-existing · Severity: major

Album curation — choosing the lead image and the narrative order — is core to every photo product (SmugMug, Flickr, Google Photos albums, Mighty galleries all support drag-to-reorder). The data model already reserves a sort_order column, but the product never lets the owner set it, so a misordered upload batch can never be fixed. The forums elsewhere in this same codebase already ship drag-reorder (routes.php:1773-1777), so the UI pattern exists in-house and isn't a new invention.

Evidence

Every uploaded item is created with sort_order=999 (PhotoGalleryController.php:367) and items always render ORDER BY sort_order ASC, id ASC (pickerItems line 1253; share-forum picker line 1458; PhotoAlbumItem::byAlbum). There is no route or controller method to change sort_order (grep for reorder in PhotoGalleryController.php / routes.php returns only forum/automod/category reorder endpoints, none for photos). So album order is permanently upload order.

Suggested fix. Add POST /photos/album/{id}/reorder accepting an ordered item-id list (owner-only), persist into photo_album_items.sort_order, and add SortableJS-style drag handles to the album grid mirroring the existing forum-category reorder implementation.

Filed by the automated tenant-app audit and adversarially evidence-verified. Status: verified. Open — not yet actioned.


Patrick Bass
@mobieus

🚀 Jun 7, 2026 12:51pm

Shipped and deployed to production. Commit 63b2de429a.

Photo reordering: HTML5 drag+drop in album view; POST /photos/album/{id}/reorder batch-updates sort_order. Owner-only.

Closed as: deployed.


Patrick Bass
@mobieus

Log in or register to reply to this thread.