Tuesday, March 11, 2008

Not so obvious about Ofbiz Categories and Catalog

Assumption:You should already be familiar with Ofbiz Category/Catalog data model. If you are not, please refer to the database tables and understand the relationship before proceeding further.

PRODUCT_CATEGORY should contain all the categories that you ever need.
PROD_CATALOG_CATEGORY contains a subset of the categories from the above table. Why the subset you ask? ... because PROD_CATALOG_CATEGORY table contains categories which are directly linked to a given catalog. Under normal circumstances, you would need a handful of categories (which are of type identified by the type in PROD_CATALOG_CATEGORY_TYPE). e.g. Browse Root, Quick Add, Search and Promotions and may be Whats new and Most popular. Most categories in the PRODUCT_CATEGORY table should be direct or indirect child of Browse Root category and should be of type CATALOG_CATEGORY. Only a handful of other categories (e.g. Quick Add, Search, Promotions and any other custom ones that you define) are standalone categories.

  • Quick Add category is used to group all the products which can be added together in one shot
  • All child (immediate or otherwise) categories of Browse Root categories are used for Navigation on ecommerce site (e.g. left nav on the Ofbiz ecommerce demo).
  • Promotion category is used to show promotional products
  • Search categories are used for product searches.

Refer to Ofbiz ecommerce demo and demo data under ecommerce data/demo*.xml that you installed to see the relationship and how its used/displayed

1 comment:

Unknown said...

Good informative post and its useful one for lots of peoples thanks for your wonderful sharing.

Ecommerce developer