Changing the Browse Order, cont. #99
Replies: 4 comments 3 replies
-
@eobrandon99 yes, but it's not a configuration option so involves editing the template a bit. For example, to sort by Title by default: In "_layouts/browse.html", you will find text inside a button element that looks like:
Replace the
Swap the order around like:
Next in "_includes/js/browse-js.html", search for the lines that look like:
Comment out the shuffle and add a sorting function instead, so it looks like:
You could do the same with any other metadata field that you want to make default. |
Beta Was this translation helpful? Give feedback.
-
@eobrandon99 I am converting this Issue into a Discussion so others can find it if they have the same idea. |
Beta Was this translation helpful? Give feedback.
-
Don't have time to properly address this just now, but I used this in https://yeager-collection.grinnell.edu/browse.html to set my default sort to "date". If I had more time I'd be interested in re-working this so that sort order and default in Browse is configurable. I considered adding a |
Beta Was this translation helpful? Give feedback.
-
I have followed the steps listed in this thread to change the items to sorting by date. It is worth noting that this required changing all dates in the CSV data file to use YYYY-MM-DD format; dates using MM/DD/YYY format are sorted numerically: all January dates come first, then October, etc, and September last |
Beta Was this translation helpful? Give feedback.
-
Discussed in https://github.com/orgs/CollectionBuilder/discussions/72
IN REGARD TO THE ABOVE DISCUSSION
Is there a way to have the Browse page sort to any other parameter (e.g. Title) by default?
Beta Was this translation helpful? Give feedback.
All reactions