Exemplo n.º 1
0
 /**
  * @todo missing docblock
  */
 public static function find($pid)
 {
     // Check the own page first
     if (CheckPageUtility::hasThemeableSysTemplateRecord($pid)) {
         return $pid;
     }
     // ..then the rootline pages
     $rootLineUtility = new RootlineUtility($pid);
     $pages = $rootLineUtility->get();
     foreach ($pages as $page) {
         if (CheckPageUtility::hasThemeableSysTemplateRecord($page['pid'])) {
             return $page['pid'];
         }
     }
     return NULL;
 }
Exemplo n.º 2
0
 /**
  * Show theme details.
  *
  * @return void
  */
 public function showThemeAction()
 {
     $this->view->assignMultiple(['selectedTheme' => $this->themeRepository->findByPageId($this->id), 'selectableThemes' => $this->themeRepository->findAll(), 'themeIsSelectable' => CheckPageUtility::hasThemeableSysTemplateRecord($this->id), 'pid' => $this->id]);
 }