David Karich Posted July 27, 2015 Posted July 27, 2015 Admin Page Tree Multiple Sorting ClassName: ProcessPageListMultipleSorting Extend the ordinary sort of children of a template in the admin page tree with multiple properties. For each template, you can define your own rule. Write each template (template-name) in a row, followed by a colon and then the additional field names for sorting. Example: All children of the template "blog" to be sorted in descending order according to the date of creation, then descending by modification date, and then by title. Type: blog: -created, -modified, title Installation Copy the files for this module to /site/modules/ProcessPageListMultipleSorting/ In admin: Modules > Check for new modules. Install Module "Admin Page Tree Multible Sorting". Alternative in ProcessWire 2.4+ Login to ProcessWire backend and go to Modules Click tab "New" and enter Module Class Name: "ProcessPageListMultipleSorting" Click "Download and Install" Compatibility I have currently tested the module only under PW 2.6+, but think that it works on older versions too. Maybe someone can give a feedback. Download PW-Repo: http://modules.processwire.com/modules/process-page-list-multiple-sorting/ GitHub: https://github.com/FlipZoomMedia/Processwire-ProcessPageListMultipleSorting I hope someone can use the module. Have fun and best regards, David 9
LostKobrakai Posted July 27, 2015 Posted July 27, 2015 Really nice. I'm still waiting for sort=template to be added to the core as this can be really useful with page-tables, which add pages directly as children. To come to the feedback: The class Process already implements Module, so normally there's no need to implement it again, but … The module shouldn't be a Process module in the first place, as it doesn't provide an interface for admin pages. You can limit the autoload setting to only ProcessPageList, ProcessPageEdit (children tab)
Zeka Posted October 5, 2016 Posted October 5, 2016 Thanks for useful module. Just wanted to notice that it works as expected on PW 3 1
j00st Posted July 19, 2018 Posted July 19, 2018 @David Karich Would it also be possible to use this to include drag-n-drop? I'm working with release 'year' (instead of date) but within the year I'd still like to drag-n-drop ? So using your module something like...but then I'm not sure about the drag-n-drop;books: -year, (drag-n-drop) I figured I'd try it with the 'regular' sort setting -> first by -year and then back to drag-n-drop, but it of course doesn't remember the -year sorting as the last drag-n-drop. If that's possible I guess it also solves my issue. Let me know if it's possible with this – already awesome for other cases!! – module, or if you have an alternative idea! cheers
sww Posted January 10, 2020 Posted January 10, 2020 hey there, set it up like this: basic-page: -created, -modified but when i modify a page nothing changes. the most recent created page stays on top. (modified gets ignored). am i missing something? also: how to reflect the page listing on my frontend? -created AND -modified wouldn't work. cheers
bernhard Posted February 11, 2020 Posted February 11, 2020 Brilliant, thx for this module! ? On 1/10/2020 at 11:00 PM, sww said: set it up like this: basic-page: -created, -modified but when i modify a page nothing changes. the most recent created page stays on top. (modified gets ignored). The sort order must be specified on the PARENT page, then all children get sorted. My setup: news (template "news") - news1 (template "newsitem") - news2 (template "newsitem") ... Then i set the sort to the "range" field (a timestamp of the first second of this day) and also created, so that pages that where created later are listed on top: news: -range, -created 1
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now