Changing the Browse Order #72
Replies: 1 comment 1 reply
-
Hi Marcie, Right now, it's impossible to determine the default sort order via the config-browse.csv file. You would need to do a slight customization to make the default browse sort by the original order. In the "browse-js.html" file, located in the _includes/js/ directory, you would need to delete line 137, which reads "shuffle(items);" To add a default description on the sort drop down, you would then need to edit the "browse.html" file in the _layouts/ directory by replacing the current lines 22-26 with the following:
Thank you for pointing this out, as this is a need for the framework in general. As for adding another option to the sort fields, you'll need to edit the config-browse.csv so that the last cell in a row has a value that describes what your sorting by. So for instance, if you replace your current browse with the below: field,display_name,btn,hidden,sort_name You will have options to sort by "Random", "Title", "Date", "Location", and "Identifier" Seems like you already had Date and Identifier in there. More on sorting can be found in our docs, but I know you likely saw those already. You don't have many values in your identifier field--that might be leading you to think nothing is happening? Let me know if there are other questions and good luck! The site looks good! |
Beta Was this translation helpful? Give feedback.
-
Hello!
I'm having trouble understanding the implementation of the config-browse.csv file. I would like to modify the sort order on the browse page of my collection so the default order shows the cards in the order that I have them entered in my .csv file. The current default is a random sort. Also, how would I add additional sort-fields to the drop-down? The current list of sort fields in the dropdown (random,title,date) doesn't seem to correspond to the existing config-browse.csv file entries.
Any advice is much appreciated!
Thanks, Marcie
Beta Was this translation helpful? Give feedback.
All reactions