/** * Создание дерева * @return string */ protected function make() { $tpl = new Mtpl($this->theme_location . '/html/tree.html'); $tpl->assign('[RESOURCE]', $this->resource); $tpl->assign('[JSTREE_OPTIONS]', $this->options); if (!empty($this->data)) { $element_tpl = $tpl->getBlock('element'); $tpl->assign('[HTML_TREE]', $this->buildElements($this->data, $element_tpl)); } return $tpl->render(); }