I have got a class
class Product extends DataObject {
static $many_many = array('categories'=>'Category');
}
and
class Category extends DataObject {
static $belongs_many_many = array('categories'=>'Category' );
static $has_one = array('Parent' =>'Category');
}
I would like to filter products by sub-categories only, If I put
$searchable_fields = array('Categories.ID' )
in the Product class, i will have a dropdown box list all categories (including the Parent ones), which is messy