[Feature request] Print file sorting options
-
Is there any chance at all a new way of sorting could be added to the Panel Due Print file section?
Currently, they are being sorted alphabetically.
I would love to see an option to change it so that the order is by file creation date, so you can just quickly see which was the latest uploaded file and hit printCould this be added? Pretty please?
-
This came up in October 2020 and I think it was planned. Or at least to be able to see the last uploaded file. Not sure how far that got. @wilriker ?
-
The problem with sorting by anything but alphabetical order is that PanelDue would have to fetch file details for every single file because the default file list does not contain anything but the filename (and I even think there is no guarantee that the list is even sorted alphabetically although it most of the time is coincidentally). That would lead to an enormous overhead and might lead to literally minutes until the file list would become available.
So unless RRF provides means of getting file lists in a specific sort order unfortunately there is no sensible way of sorting otherwise.
-
It would be possible for PanelDue to use M20 S3 instead of M20 S2 in order to get the time stamp as well as the filename, however it would greatly increase the time taken to fetch the file list, which might be a problem when there are a lot of files.
PanelDue currently sorts the files into alphabetical order.
-
I would say date order is preferable to alphabetical, it is for me at least.
-
Maybe in a future release something optional in the setup? But I can imagine that the day you have it in the panelDue options, people would flood the forum by complaining how slow it is (including me 10 years younger or so)...
-
-
So in my use case, the LastUploadedGCode would suffice. My printer is not near any computer and that's why I have the amazing PanelDue 7i on it.
I can imagine just like @LB wrote, that if it's just changed - people will complain. It should definitely be a toggle.
I could imagine that it would still need changes in RRF though, right?
Then again... imagine a world where you have an option in RRF, where you specify how the file list should be provided to the PanelDue - sorted either alphabetically or by upload date, with newest at the top... and the Duet handles the sorting... such a wonderful world indeed ;D
Another option is to add another button to PanelDue that would show a different file list, one sorted by date - and add a big fat warning in release notes (for example, or on the button) saying that this would be slow to populate.
Or even better yet! The second option now as a workaround, while the proper way later down the line.
Now THAT would be something
-
@Phaedrux said in [Feature request] Print file sorting options:
@dc42 @wilriker How bout just an object for LastPrintedGcode and LastUploadedGcode which could be displayed at the top of the file list? Or maybe even keep track of the last 3 of each?
-> Could imagine this one in the print-screen... beside "Repeat last print" an "Print last uploaded file" or so? Altough it would not be really an answer to the OP-post...
Lotยดs of possibilities...
-
@LB actually... that would also work! Just a single button that reads - print last uploaded file. It doesn't give you the option of seeing more files, but this would cover the most common use case.
-
@pkos said in [Feature request] Print file sorting options:
@LB actually... that would also work! Just a single button that reads - print last uploaded file. It doesn't give you the option of seeing more files, but this would cover the most common use case.
It was the idea of @phaedrux not mine, also I can understand the two of you and would also agree that it could be helpful for my avarage usecase...
-> But I guess that would also need some sort in the background because how would it know what is the latest uploaded file...?
Question that comes up my mind - could the latest uploaded file:
A) be written in some "cloaked" area
B) tagged (?)
to have the panelDue read that info "lightning"-fast?(Already a "fan-boy" of the sort-setting in the options-tab but still have fun playing with your idea...)