How can I fix the 'Add to Cart' issue for multiple variants on a wholesale site?

Looking for assistance with fixing an issue with our Add to Cart.

We have multiple products, and some have multiple variants. When Product X is added to the cart in Variant 1, it adds no problem. If the customer wants to also add Product X to the cart in Variant 2, this over rides the first add and changes the cart contents to only Product X in Variant 2 and totals the two quantities.

Our customers need to be able to order the same product in all variants offered.

We have two sites, one retail and one wholesale. This is NOT an issue for our retails website, only our wholesale site. I appreciate any assistance anyone can offer!

are you using any app for wholesale website?

We are using the following apps: Charge Me Later, Instabuy (this is a quick order page, that we have no trouble with), Order Limits (MinMaxify) and Locksmith.

We are using the following apps: Charge Me Later, Instabuy (this is a quick order page, that we have no trouble with), Order Limits (MinMaxify) and Locksmith.

there might be issue due apps or code. need to check the code.

Hi @AshleighB , glad to help you with your question. I’m sure, my given answer will help to solve your problem as adding the given code below in the section

Product and variants have one to many relation and you need to modify your cart code you can treat variant as a separate product in cart template like this

{% unless item.product.has_only_default_variant %}

{{ item.variant.title }}

{% endunless %}

Hopefully, that solves your problem. If not, please let me know if you’re seeing any other issues.