Closed BigActual closed 5 years ago
I'm having a difficult time determining exactly how the products were sorted before looking at the old code for the Product Archive. Is it some combination of what kind of Instrument/Mouthpiece they are combined with their Brand?
By default WooCommerce sorts by Post Title it seems, and with all the Filtering/Sorting tools at the disposal to the user, I wonder if having a special default ordering like this (Especially if it is not consistent store-wide) may just prove more confusing for the end-user?
OK, so this one is important to the client. He would like the products to start by displaying used first. Let me look up the order and I'll add another note below for the sort order within each subsection (used, new, all).
https://wordpress.org/plugins/woocommerce-product-sort-and-display/ is a solution specifically designed to deal with this. @d4mation will install and configure this to see if it alleviates the issues Paul has been experiencing.
Unfortunately, this plugin does something different than what we're aiming for.
Feedback from the client. Product order of horns on the archive is critical. Smallest to largest is the accepted order. This should apply in all, used, and new:
Saxophones:
Clarinets:
Flutes:
Oboes
Bassoons
English Horns
This should likely be closed, right? The latest bit starts to deal with everything else, which is covered in #9 .
Well, #9 is a different issue. Unless all he wants is for the filters to be in that order? If that's the case, then #9 with the FacetWP implementation did solve this.
This has been implemented on http://pmwoodwind.wpengine.com/products/instruments/?_show=used
It is Post Meta that will automatically update to the "Highest Indexed" value based on the list above whenever a Product is saved/updated.
For clarity's sake, it checks for whether a Product has a Product Category matching these exact names (However, capitalization does not matter) and puts them in order from top to bottom. If it has multiple for whatever reason, it will use the one furthest down the list:
Sopranino Saxophones
Soprano Saxophones
Alto Saxophones
C Melody saxophones
Tenor Saxophones
Baritone saxophones
Bass Saxophones
Electronic Saxophones
Bb Clarinets
A Clarinets
Eb Clarinets
Alto Clarinets
Bass Clarinets
Contra Alto Clarinets
Contra Bass Clarinets
Piccolos
Flutes
Alto Flutes
Bass Flutes
Oboes
Bassoons
English Horns
If needed, this ordering/list can be adjusted. It only requires the import script to be re-ran.
For reference, this is now the default sort order for Mouthpieces:
Brass Mouthpieces
Sopranino Mouthpieces
Soprano Mouthpieces
Hard Rubber Soprano Mouthpieces
Metal Soprano Mouthpieces
Alto Mouthpieces
Metal Alto Mouthpieces
Rubber Alto Mouthpieces
Tenor Mouthpieces
Metal Tenor Mouthpieces
Hard Rubber Tenor Mouthpieces
Baritone Mouthpieces
Metal Baritone Mouthpiece
Hard Rubber Baritone Mouthpieces
Clarinet Mouthpieces
Bass Clarinet Mouthpieces
While the Instrument-type order is the same, the Category names are very different so it needed its own defined order.
This will depend on getting all the Filtering stuff in #9 and #1 finished up.