Adding the Same Variant to Multiple Products

Solved
Highlighted
Excursionist
11 1 6

Hi all,

I have a client who has 4 variants (colors) of one main product. The client would like 4 products, one for each variant color, each product contains all 4 variants.

The problem is that when I create or duplicate the first product, new variants are created in Inventory instead of using the existing variant and quantities.

What am I doing wrong?

0 Likes
Highlighted
Shopify Partner
369 39 78

Hi @brendonwbrown 

Trying to wrap my head around what you're describing...

So, we are talking about ONE product that comes in FOUR colors. The client wants the product variants all to have their own separate product page, but also have all four variants listed on each of the four separate product pages?

May I ask what are they intending to accomplish?

0 Likes
Highlighted
Excursionist
11 1 6

Thank you, @BobsMojo for your reply.

Close. The Client has ONE product that comes in FOUR colors.

The Client has 60 or so products in a variety of collection pages. The Client would like to see all 4 variants on the appropriate collection page, but only for this product, not for every product which has variants. 

I do not think the objective is as much to have 4 separate product pages as it is to show all variants of that product. Clicking on the variant should open the product page with the clicked variant activated.

Does this make sense?

0 Likes
Highlighted
New Member
2 0 0

@brendonwbrown did you ever find a solution for this? I'm working on a store that has hundreds of products that need to have the same variants and the ability to edit them at the same time. Any advice you have would be greatly appreciated. Thanks!

0 Likes
Highlighted
Excursionist
11 1 6

@stevesunderland Your requirements seem to be different than mine - you seem to need the ability to add the same unique variant to multiple parent products, while being able to quickly edit that variant - that sounds like a back-end need and I would not hold my breath for that. 

A workaround might be to get comfortable with exporting the parents to a .csv, change each line to keep parent handles but add variant Title, Options, and details, then  re-import. This will assign the variant to each of the parents with that handle. I HIGHLY recommend exporting all products first as a backup, then reading Shopify's import documentation. It's quite difficult to come back from a bad import - Shopify has no database versioning or restore tools to offer.

After a successful import, keep the .csv file. When you need to make a bulk update, make your modifications there and re-import.

 

Highlighted
Excursionist
11 1 6

This is an accepted solution.

For anyone struggling with this, I did manage to achieve what I was going for, with some caveats. 

A preface to Shopify:
Variants are an incredibly powerful way to reduce friction and increase conversions by creating buy-in by displaying all options and allowing a customer interaction with them. This said, Variants are significantly less powerful when a shop owner cannot put these individual items on display on a collection page, or when a customer's first impression is of a single item's configuration that they do not like. I realize that this can be addressed to some level with swatches, but a first impression does cement the appeal of a product in a customer's mind, and for a small collection page, it's good to have the ability to fill it with all available products. Also, I am still regularly frustrated by some of the features lacking from Variant workflow. Apps still have issues applying promotional rules to variants (and as we are forced to use apps as Shopify has essentially neutered discounts, this is an issue). The inability to hide a variant temporarily without deleting it, is also an obstacle in my experience.

The Solution:
I have experience in HTML, CSS, JS and templating languages, so I was able to source and learn enough Liquid to put together a solution. I was working off of Turbo theme from Outofthesandbox. You may want to reach out to a developer to perform this update, or feel free to ask me questions and I will answer depending on my availability.

1. I duplicated the collections template liquid file with a new name. Every collection I wanted to show all variants has to be switched to this new template.

2. In the collections template I modified the product loop code with the conditional: if product has more than 1 variant and also has the tag "variant-view" then it should run a different set of code than the normal product image and title code.

3. The new set of code is a loop through variants skipping "size" options (ususally there's no visual change). Product Title is generated based on Title and Option combinations, variant image is loaded, parent image when hovered, links go to the specific variant link (parent product URL with variant parameter).

Props to Dylan Hunt, who has been sharing his code and updates for some time.

0 Likes