Select individual variant options not just the Name on Product page
When defining Product Variants we are linking combinations of Variant Options back to an SKU. When UCommerce displays the variant selection(s) on the Product Page it shows the "Name" as defined below.
I would like to display the selections Size, Colour and Style and only allow valid combinations to be selected. From this I can derive the SKU
It's certainly possible to do a variant picker like that, but it's a bit more involved than what the standard store does out of the box.
With this approach you'll basically have to continually narrow down the selection option to ensure that you get valid combos of variant properties.
I'd do a JavaScript approach which has all the valid variants available and on the client look up the valid options based on what the customer selects, e.g.
Sku + Size + Color variation
1SRed
2SBlue
3MYellow
4LGreen
5LBlue
When a customer selects "L" for size only "Green" and "Pink" is a valid option for color, so I'd gray out the other colors variants based on what's available given the first selection.
Same is true for the reverse case where the color is selected first. If "Blue" is selected on S and L are valid.
It's basically down to getting the valid variant combos sent to the client and a lot of JS gymnastics on the client to enable/disable.
Once that's done posting the selected SKU is straightforward.
Select individual variant options not just the Name on Product page
When defining Product Variants we are linking combinations of Variant Options back to an SKU.
When UCommerce displays the variant selection(s) on the Product Page it shows the "Name" as defined below.
I would like to display the selections Size, Colour and Style and only allow valid combinations to be selected. From this I can derive the SKU
It's certainly possible to do a variant picker like that, but it's a bit more involved than what the standard store does out of the box.
With this approach you'll basically have to continually narrow down the selection option to ensure that you get valid combos of variant properties.
I'd do a JavaScript approach which has all the valid variants available and on the client look up the valid options based on what the customer selects, e.g.
Sku + Size + Color variation
1SRed
2SBlue
3MYellow
4LGreen
5LBlue
When a customer selects "L" for size only "Green" and "Pink" is a valid option for color, so I'd gray out the other colors variants based on what's available given the first selection.
Same is true for the reverse case where the color is selected first. If "Blue" is selected on S and L are valid.
It's basically down to getting the valid variant combos sent to the client and a lot of JS gymnastics on the client to enable/disable.
Once that's done posting the selected SKU is straightforward.
is working on a reply...