I have my swatches working on configurable products, they are working well to add product in the cart, but I have an odd behaviour, only the photos of the first products are returned by the Ajax request.
Let's say I have 4 variations : Black, Blue, Red, Green
With the photos :
- Configurable : Photo10, Photo11
- Black : Photo20, Photo21, Photo22
- Blue : Photo30, Photo31, Photo32
- Red : Photo40, Photo41, Photo42
- Green : Photo50, Photo51, Photo52
When I load the page, the gallery contains : Photo10, Photo11, Photo20, Photo21, Photo22 as expected.
But then, no matter which swatch I click, I always get the Black photos in return and my Gallery updates to Photo20, Photo21, Photo22.
I had a look at the ajax request using the Firefox debug tool and all requests seem to be fine sending different attributes value, but the response is always the same, giving me the photo list of the first variation.
Is there a setting somewhere that dictates this behaviour or is that plain outright bug?
Add information 2016-10-11 : If I change my attribute "Color" to be dropdown, then it all works perfectly. I also have a linked issue : I added a price block somewhere else in the page. With the swatch, only the one in the addtocart form updates, with the dropdown, both update properly.
Further update 2016-10-11 : When observing the requests, it appears that when it is a dropdown, there is no request except for the images themselves, when it is a swatch, then it has a first POST request for the image list, then for the images themselves. Why can't it use the local data like the dropdown does?
P.S. If it can help, my dev server is on Nginx and runs "behind" another Nginx server that redistribute the requests based on their subdomain.