I am having three tables category, subcategory and subsubcategory. Now category table contain fields as id,name subcategory table contain fields as id, category_id and name and subsubcategory table contain fields as id, subcategory_id and name
now subsubcategory view/index showing columns as name,subcategory_name but i want to display category_name also in my subsubcategory index page
I have used containable behaviour to associate two tables as category and subsubcategory
Here is my code:--
subsubcategoriescontroller:
$contain =array(
'Subcategory'=> array(
'Category' =>array(
'fields' => array('id', 'name')
)
));
$this->Subsubcategory->find('all',array('contain' => $contain));
appmodel:
public $actsAs = array("Containable"); still my subsubcategory page not showing expected results. what will i do?