In Category Model, getAll method is used for returning all category data. First Active Record in below method $roots have all roots category and $categories have roots category's descendants category. How to add these two Category. Following is getAll Method:
public function getAll()
{
$roots = Category::model()->roots()->findAll();
foreach($roots as $root)
{
$category = Category::model()->findByPk($root->root);
$categories = $category->descendants()->findAll();
}
return $category + $categories; // this does not concatenate, causes error
}