/** * 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); }
/** * 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(); }
/** * Sets up some partials. */ public function __construct() { parent::__construct(); $this->partials['list'] = $this->load("partials/list.mustache"); }