Ejemplo n.º 1
0
 public function getChildPages($parent)
 {
     $pages = array();
     if ($parent->getCollectionPath() == '/account') {
         // Add My Account to the List
         $pages[] = Page::getByPath('/account/welcome');
     }
     $pages = array_merge($pages, parent::getChildPages($parent));
     return $pages;
 }
Ejemplo n.º 2
0
 public function getChildPages($parent)
 {
     $pages = parent::getChildPages($parent);
     if ($parent->getCollectionPath() == '/dashboard/welcome') {
         // Add My Account to the List
         $pages[] = Page::getByPath('/account');
         $site = \Core::make("site")->getSite();
         $config = $site->getConfigRepository();
         if (is_object($site) && $config->get('user.profiles_enabled')) {
             $pages[] = Page::getByPath('/members/profile');
         }
     }
     return $pages;
 }
 public function __construct(Page $currentPage = null)
 {
     $dashboard = \Page::getByPath('/dashboard');
     parent::__construct($dashboard, $currentPage);
 }