public static function treeUpperLeafs($root) { $entries = Category::find(['root = :root: AND parent_id IS NULL', 'order' => 'left_key', 'bind' => ['root' => $root]]); return $entries; }
public function treeUpperLeafs($root) { return Category::treeUpperLeafs($root); }