Ejemplo n.º 1
0
 /**
  * Pass in the content partials to the rendering function.
  *
  * @param  array $partials  An array of partials
  * @return string           The rendered template
  */
 public function render(array $partials = array())
 {
     if ($this->has_view) {
         $partials = array_merge($this->content->getPartials(), $partials);
     }
     return parent::render($partials);
 }
Ejemplo n.º 2
0
 /**
  * Set the template path 
  */
 public function setUp()
 {
     $path = __DIR__ . DIRECTORY_SEPARATOR . "views" . DIRECTORY_SEPARATOR;
     $finder = new \Owl\Finder\FileSystem($path);
     \Owl\View::setFinder($finder);
     $this->layout = new LayoutView();
     $this->view = new BaseView();
     parent::setUp();
 }
Ejemplo n.º 3
0
 /**
  * Sets up some partials.
  */
 public function __construct()
 {
     parent::__construct();
     $this->partials['list'] = $this->load("partials/list.mustache");
 }