Example #1
0
 public function add(PageType $pageType)
 {
     $this->pageTypes[$pageType->getId()] = $pageType;
     if (!($routeNames = $pageType->getRouteNames())) {
         return $this;
     }
     foreach ($routeNames as $routeName) {
         $this->pageTypesByRouteName[$routeName] = $pageType;
     }
     return $this;
 }
Example #2
0
 protected function getLangKey(PageType $pageType)
 {
     return $this->langKey . '.' . str_replace('.', '/', $pageType->getId());
 }