Product variants are a set of products that are available with multiple characteristics or "variants." This construct is commonly used for products, such as a toolbox, that can be purchased in a variety of colors and sizes with each of these color/size combinations resolving to a unique SKU or product ID.
Within Optimizely Configured Commerce, the configuration of these parts is divided into two sections: variant types and variant products.
Variant types
The variant type represents the group products as a whole. Products with the same traits are assigned to a variant type, such as "Toolbox."
Variant traits
A variant type consists of different features or variant traits, such as Size and Color.
Variant trait values describe the specific options within a trait. For Color, the variant trait values might be Yellow, Blue, and Red.
If you want to add new variant trait values in bulk using a spreadsheet, make sure the columns are as follows: Value, Description, Sort Order, Unselected Value, Display Trait Style, Style Trait.Style Class and Style Trait.Name, where Style Trait.Style Class is the variant type and Style Trait.Name is the variant trait.
Create variant types
- Go to Admin Console > Catalog > Variant Types.
- Click +Variant Type.
- Enter the Name and optional description for the variant type on the Details tab.
- Deactivate the Active toggle if you do not want the variant type to be active.
- Click Save or Save & Add New to continue adding variant types.
Create variant traits
- Go to Admin Console > Catalog > Variant Types.
- Click the Edit icon beside the variant type for which you want to add traits.
- Click the Traits tab.
- Click +Variant Trait to add a variant trait to the variant type.
- Enter the Name and Sort Order. If desired, enter a Description, a default Unselected Value, and a Display Trait Style.
- Click Save or Save & Add New to continue adding variant traits.
Create variant trait values
- Go to Admin Console > Catalog > Variant Types.
- Click the Edit icon beside the variant type for which you want to add traits.
- Click the Traits tab.
- Click the Edit icon beside the variant trait for which you want to add values.
- Click the Values tab.
- Click +Variant Trait Value to add values for your variant trait.
- Enter a Value and Sort Order. If desired, enter a description, toggle the Default Value, and select a Swatch Style of Color or Image.
- Click Save or Save & Add New to continue adding variant trait values.
Variant products
Parent products
The parent product is a generic or "dummy" product which does not resolve to a SKU or part ID in the ERP database. Because this parent is a placeholder, you do not need to add pricing or track inventory. The parent product does, however, need images and other content as it is the product that displays on the product list pages and the product detail page before any styles are chosen. Using the Toolbox example, the parent product is labeled "Hero Toolbox" and has an image displaying all three toolbox options.
Custom availability messages do not appear on the parent product when viewing the product listing page (PLP) and product display page (PDP).
Child products
Child products, which represent a single SKU or part ID in the ERP database, are then assigned to the parent product. The child products embody each unique combination of the Size and Color variant trait values. Optimizely recommends that each parent product have a maximum of 100 styled child products.
Browse and purchase variant products
Variant products are displayed within the category to which the parent product has been assigned.
The product detail page displays the product like the standard product detail page but with dropdown lists, buttons, or grids that allow customers to select the variant traits for products.
After selecting variant trait values from the dropdown lists, the page updates and displays any content populated for the child product for that combination of options.
The dropdown lists are also sensitive to whether or not a product has been defined for a specific combination of variant trait values. For example, if a product has not been defined for green/medium, the medium option will not be available within the dropdown list when the color green is selected. The opposite also holds true. Clicking a link to a product variant from the following places directs customers to the product detail page of the product with the options for the child product selected.
Search for and view product variant detail pages
When searching for an exact match of a variant child product number, even if the search terms are also present or directly match another product's data fields, the product detail page loads with the child product variants selected. Direct matches on variant part numbers may occur in the following fields:
- Product Number
- Product Title
- Model Number
- SKU
- UPC
- UNSPSC
- Manufacturer Item
If a user selects more than one child product within a parent, only the parent product detail page loads.
When a user clicks the link to a child product from autocomplete, the parent product detail page loads with the variants for the child product selected. When the user enters a product number using the Quick Order form, the search results includes child products.
A link to a product variant from the following places directs customers to the product detail page with the options for the child product selected:
- Cart
- Order confirmation
- Order history
- Sales quote request confirmation
- List detail page
- Quote details (sales rep)
- Job quote details
- "Share with friend" email
- Recently viewed widget
- Related products widget
- Recently purchased widget
Work with variant product parent-child relationships
The section below describes how to associate child products to a parent product and assign their variant trait values. Child products should have pricing, content, and images before setting them as variant products.
Create a parent product
The parent product is a placeholder to which the child products are associated. The parent product does not represent a part stored within your ERP system and should be set up as such:
- Go to Admin Console > Catalog > Products.
- Click Add Product to create a new product record.
- Enter data in the Product Number and Product Title fields in the Details tab. Ensure the ERP Managed and Track Inventory toggles are set to Off.
- Click Create Revision in the Content tab to add a description of the parent product. Click Source to add more formatting or customization, if needed.
- Add one or more sets of Small/Medium/Large images for the product set in the Images tab.
- Click Save.
- Assign the product to a category within the Category tab.
- Click Save.
Add a variant class to a parent product
- Go to Admin Console > Catalog > Product.
- Locate the parent product from the record list and click Edit.
- Select the Variants tab and select a variant type using the Variant Type dropdown list.
- Click Save in the secondary header.
Assign child products to a parent product
- Go to the Variants tab of the parent product, and click Assign Child Variants.
- Select the products that will be child products of the parent.
- Click Assign.
- Click Done.
- Click Save to save the child product association, and click the X to exit the assignment screen.
- Click Save in the secondary header.
Rebuilding the Product Search Index is required before the variant products will be available on the website.
Assign default child variant
Configured Commerce first looks for the default child product, but if it cannot locate a defined value at the product level, it then uses the variant trait to define the default child variant. You may also use Optimizely Product Information Management (PIM) or another PIM system that lets you set the default variant. Follow these steps to set the default child variant in Configured Commerce:
- Go to the Variants tab of the parent product.
- Select from the Default Child Product dropdown. You will see a list of currently assigned child products. If you select a value that is not from the list of assigned products, a warning displays.
- Click Save.
Enable nested documents
Extensive use of variant products and restriction groups can lead to incorrect facet counts on the PLP in some scenarios. The 'Enable Nested Documents' setting allows you to get improved results in these rare cases. This setting is toggled to 'No' by default.
- Go to Admin Console > Administration > Settings > Search.
- Toggle Enable Nested Documents to Yes.
- Click Save.
You must rebuild the product index after changing this setting.
Please sign in to leave a comment.