Allow sortable headers with generic choosers
th3hamm0r opened this issue · comments
Is your proposal related to a problem?
It is quite easy to setup and customize the chooser modal. For example, you can add columns easily.
Unfortunately, you cannot use the "sort_key" to enable sortable columns, since those sort-headers aren't handled by the modal's JS.
That's probably the reason, why the sort_key
is set to None
here:
wagtail/wagtail/snippets/views/chooser.py
Line 33 in 79bc237
Describe the solution you'd like
It would be nice to have this handled by wagtail's JS. I think this would probably also help wagtailmedia's outdated implementation (which allows sorting) to be ported more easily.
There are similar tickets for the page chooser, which could also benefit from that functionality:
#3544
#8557
Working on this
Anyone can contribute to this. View our contributing guidelines, add a comment to the issue once you’re ready to start.