Select version
v7.7 v7.6 v7.5 v7.3 v7.1 v7.0 v6.8 v6.7 v6.6 v6 v5 v4 v3 v2

Product Definitions

The uCommerce Catalog Foundation holds all the catalog information in your installation and as such serves as the most important foundation in uCommerce. This post will give you an idea of one of the most basic building blocks of the Catalog Foundation: Product Definitions… but first some basics.

Products, Product Families, and Variants. Oh My!

Before we get into the nitty gritty of things we need to get the terminology right so we agree on what’s what.

Products are pretty straight forward they represent a single product in the system with no variants associated.

Product Families are pretty much the same as a product but differ in that they’ve got variants associated with them, hence the product family.

Variants represents a single product much like a stand alone product, but they cannot stand by themselves. Variants are always associated with a product family.

uCommerce supports both products and product families and the good news is you don’t have to go with one over the other. You simply decide on a per product basis whether or not to support variants. So you might have some products be stand alone products and others be product families. Whatever works for your scenario.

Product Definitions

Product Definitions 2Before you can start using catalogs you need to perform some setup to determine the data you’ll be working with, i.e. the taxonomy of your site, the various types of products you’ll support in the site, and finally your pricing scheme.

Product definitions are the most fundamental building blocks of the uCommerce Catalog Foundation. If you’re familiar with Umbraco think of them as Document Types for products. Basically a product definition determines what data you’re working with in uCommerce, both via the UIs and the APIs.

Each product definition in uCommerce represents a different type of product available through your store. Say you’re selling Software and Shirts as in the screenshot below. Software requires a completely different set of data to sell from a Shirt. Notice that Software has different properties from the Shirt.

With product definitions you can tailor uCommerce to your client’s needs.

image

Adding a New Product Definition

uCommerce supports as many product definitions as you need. Simply right click the Product Definitions node and click create to add a new definition. Each of the product definitions must be named uniquely so you can find it later on.

Adding New Properties to Product Definitions

You can add new properties by right clicking the product definition and clicking Create. Just as you would do when creating a new content node in Umbraco. As you can see the product definition needs a name which will be your key for reference the product definition from code as well the identifier for the product type.

The product family check box indicates whether the product definition allows variants or not. A product family is basically a product with a bunch variants associated with it while a non-product family (product) represent just a single product.

image

Once created you’ll have the opportunity to change the meta data of the property to suit your needs.

image

Multilingual Properties

If you need to maintain the data of the property in multiple languages you can tick off the multilingual check box. This will give you a field per language configured in the CMS.

image

If you specify a property to be multilingual the property will show up under the multilingual tabs when you go and edit products.

image

Display on Website

A true/false value which is set on the property when accessed via the API.

image

Variant Properties

Determines whether the property should be a variant property that you maintain under a product family. If one or more exist the product will turn into a product family automatically and enable you to create multiple variants associated with the product family.

image

Setting the property as a variant property will add the Variants tabs to the editor to any product based on the product definition and will enable you to create variations of a product as part of a product family.

image

Render in Editor

Sometimes you need data that you don’t want the user to edit. Ticking this check box will tell uCommerce not to render this property as part of the editor UI essentially giving you meta data that you can use and maintain from the API without having to worry about the user tampering with it.

image

Data Types

Each of the properties created in the previous paragraphs are based on data types, which you select when you create new ones. uCommerce comes with a number of built-in data types such as ShortText, LongText, Number, Boolean, Enum, and Image.

image

Data types include string, number, bool, and enum which is a special type which enables you to predefine a list of values allowed for the user to select, e.g. colors, sizes, basically data with a finite number of options to choose from.

Validation Expressions

image

Data types can have validation expressions associated with them to validate user input when editing in the product editor. A validation expression is a standard regular expression evaluated whenever a user clicks the save button.

image

In Conclusion

The Product Definition is the secret sauce which makes the uCommerce Catalog Foundation extremely powerful enabling you to model the reality you face be it as a developer creating an e-commerce solution for a client or for yourself.

An important aspect about a product definition is that you can change your mind whenever you please. If you start out without variants nothing is holding you back from moving your properties around even after you start creating products based on that product definition. uCommerce will simply reflect the changes you need without you having to create you products from scratch.

uCommerce Aps - Studsgade 29B - 8000 Aarhus C - Denmark
Phone +45 61 799 997 - Email info@ucommerce.dk uCommerce logo