Recent Posts

Thursday, September 8, 2011

How I built a Commerce Site

I 'll give the big lines of how I built http://makeupcosmeticsdiscount1euro.eu/ .

HomePage

The homepage has the following items :
  • For the Title I used the  Google Fonts module
  • The menus are menus in Menu Blocks configured to be shown on a specific language
  • The three products next to the big image is ... a view. Later I want to implement the Nodequeue module for this.
  • The Shopping Cart is a Custom one (with jQuery) . Tnx http://drupal.org/user/858054 who helped me with the shopping cart. 
The Core of the site is the Taxonomy term list that is named "Catalogus".  This list is a list of all main-menu-items. So in my case: Gezicht, Ogen, Lippen, etc. Every item gets an Image (image_ref_group) like this one.


This image is used on the "Product Group Page", what is the "Group-Product-Display" view where is shown the "Image Reference Group" next to the Images, representing the products. 
The "Product Group Page" is a view that combines a Page-View with a Block-View. The Page-View uses a Contextual filters with a path: /taxonomy/term/% . The Block-View is a Grid with also a Contextual filters (taxonomy term ID from URL). 
To know how to do this I looked at the screencast of Bob http://mustardseedmedia.com/podcast/episode39 .


Product Group Page

The thumbs are "Image reference product" images  (field_img_ref_product) . These are added while creating the Product Display.


The Product Display



Product Display Fields

In the Product Display, the title is excluded from display, Language (taal) is chosen, Catalog category is the Term reference , select the products to be displayed and the "Image reference product" so the thumb used to represent the products on the Product Group page. 

Part of the "add Product Display" page

Last part of the "add Product Display" is to choose to what menu the Display belongs. This depends on the language and the product. There are two menu- types. There is a menu for "general-products" and for "dark-skins-products". Every language has it's own menu. I'm not sure if this is the best solution. It was the best when I started to create the site.

Menu Settings on the "add Product Display" page
Here are the fields on the Product type.

Product Type Fields



You find here two prices because there isn't yet a module that can show a "base-price" and a "discount-price", but that will change soon.



Sites to visit:
http://www.drupalcommerce.org/
http://drupal.org/project/commerce

I cannot finish this article without a big Merci for some people.

Most of all Ryan Szrama (http://drupal.org/user/49344) for building Drupal Commerce and his help to build this site. But also Randy Fay (http://drupal.org/user/30906) , Jakob Torp (http://drupal.org/user/386230) , Erwin Derksen (http://drupal.org/user/750928) and lots of others.

0 comments:

Post a Comment