Is there an existing issue for this?
Current Behavior
Prerequisites
When "Product Attribute to Use for Swatches in Product Listing" is explicitly set to "-- Please Select --" (empty selection), swatches display on the product detail page but don't function when clicked. The hidden select value doesn't update, causing "Please specify the product's option(s)" error on add to cart.
Expected Behavior
The explicit selection of "-- Please Select --" should behave the same as having no listing attribute configured. Product detail swatches should function independently.
Steps To Reproduce
- Enable Configurable Swatches
- Set "Product Attributes to Show as Swatches in Product Detail" to an attribute (e.g., Size)
- Explicitly set "Product Attribute to Use for Swatches in Product Listing" to "-- Please Select --"
- View configurable product page
- Click a swatch option
- Click "Add to Cart"
- Error: "Please specify the product's option(s)"
Environment
- OpenMage: latest
- php: 8.4
Anything else?
Workaround
Select any attribute (even unused) in the listing field instead of "-- Please Select --".
Technical Notes
The issue is specific to the empty string value when "-- Please Select --" is chosen, versus null/undefined when the field is left unconfigured. Related to getSwatchAttributeId() handling in Helper/Productlist.php.
Is there an existing issue for this?
Current Behavior
Prerequisites
When "Product Attribute to Use for Swatches in Product Listing" is explicitly set to "-- Please Select --" (empty selection), swatches display on the product detail page but don't function when clicked. The hidden select value doesn't update, causing "Please specify the product's option(s)" error on add to cart.
Expected Behavior
The explicit selection of "-- Please Select --" should behave the same as having no listing attribute configured. Product detail swatches should function independently.
Steps To Reproduce
Environment
Anything else?
Workaround
Select any attribute (even unused) in the listing field instead of "-- Please Select --".
Technical Notes
The issue is specific to the empty string value when "-- Please Select --" is chosen, versus null/undefined when the field is left unconfigured. Related to
getSwatchAttributeId()handling inHelper/Productlist.php.