2076 Posts in 857 Topics by 449 members
Page: 1 2
|Go to End|
26 April 2012 at 1:48pm
To interact with the session you'll want to make use of the Session class:
Here is some more of the example fleshed out.
$data = Session:get('productfilter');
$savedfilter = "\"ParentID\" IN (".implode(",",$data["Categories"]).")"; //where $data["Categories"] is an array
The limiting is done by passing the savedfilter to ProductsShowable, which makes sure the products it retrieves only belong to the given categories (Product Groups).
This is far from complete, and you'd need to somehow get the ids of subcategories if you wanted to include products from those.
I will be devoting some time to improving the ability to browse / search products in the future sometime.
Here's a ticket I made: https://github.com/burnbright/silverstripe-shop/issues/36
11 May 2012 at 3:33am
Sorry I've been awol these last few weeks.
I appreciate your help and hopefully the ecommerce module will get the upgrade sooner rather than later.
The project I'm working on has unfortunately been shelved.
Page: 1 2
|Go to Top|