\Catalogue_Controller
Controller used to render pages in the catalogue (either categories or pages)
Synopsis
class Catalogue_Controller
extends Commerce_Controller
{
- // members
- private static array $allowed_actions = ;
- // Inherited members from Commerce_Controller
- protected $dataRecord;
- // methods
- public static ProductCategory get_current_category()
- public static Product get_current_product()
- public PaginatedList PaginatedProducts()
- public PaginatedList PaginatedAllProducts()
- public string Link()
- public string MetaTags()
- public void __construct()
- public void index()
- public void image()
- public Image ProductImage()
- public void AddItemForm()
- // Inherited methods from Commerce_Controller
- public void data()
- public void getDataRecord()
- public void setDataRecord()
- public void Link()
- public void init()
- public void getPostageAreas()
- public void results()
Hierarchy
Extends
Tasks
Line | Task |
---|---|
105+ | Move <title> tag in separate getter for easier customization and more obvious usage |
Members
private
- $allowed_actions
protected
- $dataRecord
Methods
public
- __construct() — The ContentController will take the URLSegment parameter from the URL and use that to look up a SiteTree record.
- AddItemForm()
- Link() — Return the link to this controller, but force the expanded link to be returned so that form methods and similar will function properly.
- MetaTags() — Return the title, description, keywords and language metatags.
- PaginatedAllProducts() — Get a paginated list of products
- PaginatedProducts() — Get a paginated list of products contained in this category
- ProductImage() — The productimage action is used to determine the default image that will appear related to a product
- get_current_category() — Find the current category via its URL
- get_current_product() — Find the current category via its URL
- image() — Action used to display an image for a product
- index()
Inherited from Commerce_Controller
public
- Link()
- data() — Returns the associated database record
- getDataRecord()
- getPostageAreas() — Function to find relevent postage rates, based on supplied country and zip/postal code data.
- init() — Init actions that happen globally to all commerce interfaces.
- results() — Process and render search results. This has been hacked a bit to load products into the list (if they exists). Will need to come up with a more elegant solution to dealing with complex searches of objects though.
- setDataRecord()