statamic / cms

The core Laravel CMS Composer package
https://statamic.com
Other
4.11k stars 538 forks source link

Asset folder sort does not work across pages #11085

Closed daun closed 4 days ago

daun commented 2 weeks ago

Bug description

The asset browser folder sorting only seems to work when there's a single page of folders. As soon as the folders stretch across two pages or more, the sort only gets applied on the last page, after the query. The first X pages before that are not affected by the sort direction. I'd expect the sort to work across all pages, just like it does in collections and taxonomies.

How to reproduce

Create 15 folders. Set pagination limit to 10. Toggle sort direction asc/desc. It should only have an effect on page 2.

Logs

No response

Environment

Environment
Application Name: ****
Laravel Version: 11.30.0
PHP Version: 8.3.3
Composer Version: 2.5.1
Environment: local
Debug Mode: OFF
URL: ****.test
Maintenance Mode: OFF
Timezone: Europe/Vienna
Locale: en

Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED

Drivers
Broadcasting: log
Cache: file
Database: sqlite
Logs: stack / single
Mail: log
Queue: sync
Session: file

Statamic
Addons: 8
Sites: 1
Stache Watcher: Disabled
Static Caching: half
Version: 5.36.0 PRO

Statamic Addons
daun/statamic-widget-collection-count: 1.2.1
doefom/currency-fieldtype: 1.4.1
jacksleight/statamic-bard-mutator: 3.0.3
jacksleight/statamic-bard-texstyle: 3.3.2
jacksleight/statamic-bonus-routes: 0.3.2
statamic-rad-pack/mailchimp: 5.2.2
statamic/eloquent-driver: 4.16.1
stillat/relationships: 2.2.1

Statamic Eloquent Driver
Asset Containers: file
Assets: file
Blueprints: file
Collection Trees: file
Collections: file
Entries: file
Forms: file
Global Sets: file
Global Variables: file
Navigation Trees: file
Navigations: file
Revisions: file
Sites: file
Taxonomies: file
Terms: file
Tokens: file

Installation

Fresh statamic/statamic site via CLI

Additional details

No response