File modules/cms/action/template/TemplateInfoAction.class.php

Last commit: Tue Nov 17 23:51:00 2020 +0100	Jan Dankert	Refactoring: Every Actionmethod has now its own class.
1 <?php 2 namespace cms\action\template; 3 use cms\action\Method; 4 use cms\action\TemplateAction; 5 use cms\model\Page; 6 7 8 class TemplateInfoAction extends TemplateAction implements Method { 9 public function view() { 10 $pages = array(); 11 $pageids = $this->template->getDependentObjectIds(); 12 13 foreach( $pageids as $pageid ) 14 { 15 $page = new Page($pageid); 16 $page->load(); 17 18 $pages[$pageid] = $page->filename; 19 } 20 21 $this->setTemplateVar('pages',$pages); 22 $this->setTemplateVar('id' ,$this->template->getId() ); 23 $this->setTemplateVar('name' ,$this->template->getName() ); 24 } 25 public function post() { 26 } 27 }
Download modules/cms/action/template/TemplateInfoAction.class.php
History Tue, 17 Nov 2020 23:51:00 +0100 Jan Dankert Refactoring: Every Actionmethod has now its own class.