26 protected \ILIAS\Portfolio\InternalGUIService
$gui;
39 $this->
ctrl = $DIC->ctrl();
40 $this->
lng = $DIC->language();
41 $this->
user = $DIC->user();
42 $ilCtrl = $DIC->ctrl();
43 $lng = $DIC->language();
44 $this->gui = $DIC->portfolio()->internal()->gui();
53 $this->page_gui = $this->parent_obj->getPageGUIClassName();
54 $this->is_template = ($this->portfolio->getType() ===
"prtt");
65 $this->
setRowTemplate(
"tpl.portfolio_page_row.html",
"Modules/Portfolio");
71 "savePortfolioPagesOrdering",
72 $lng->
txt(
"user_save_ordering_and_titles")
87 if (!$this->is_template) {
88 $this->blogs = array();
93 foreach ($tree->getSubTree($root) as $node) {
94 if ($node[
"type"] ==
"blog") {
95 $this->blogs[$node[
"obj_id"]] = $node[
"wsp_id"];
102 protected function fillRow(array $a_set): void
104 $f = $this->gui->ui()->factory();
108 switch ($a_set[
"type"]) {
110 $this->tpl->setCurrentBlock(
"title_field");
111 $this->tpl->setVariable(
"ID", $a_set[
"id"]);
113 $this->tpl->parseCurrentBlock();
115 $ilCtrl->setParameterByClass(
123 $action_items[] =
$f->button()->shy(
125 $ilCtrl->getLinkTargetByClass($this->page_gui,
"edit")
129 $this->tpl->setVariable(
"TYPE",
$lng->
txt(
"page"));
133 if (!$this->is_template) {
134 $this->tpl->setCurrentBlock(
"title_static");
136 $this->tpl->parseCurrentBlock();
138 $obj_id = (
int) $a_set[
"title"];
139 if (isset($this->blogs[$obj_id])) {
140 $node_id = $this->blogs[$obj_id];
144 $ilCtrl->setParameterByClass(
149 $link = $ilCtrl->getLinkTargetByClass(array($this->page_gui,
"ilobjbloggui"),
"render");
155 $action_items[] =
$f->button()->shy(
160 $this->tpl->setVariable(
"TYPE",
$lng->
txt(
"obj_blog"));
165 if ($this->is_template) {
166 $this->tpl->setCurrentBlock(
"title_field");
167 $this->tpl->setVariable(
"ID", $a_set[
"id"]);
169 $this->tpl->parseCurrentBlock();
171 $this->tpl->setCurrentBlock(
"title_static");
173 $this->tpl->parseCurrentBlock();
174 $this->tpl->setVariable(
"TYPE",
$lng->
txt(
"obj_blog"));
179 $ilCtrl->setParameter($this->parent_obj,
"prtf_page", $a_set[
"id"]);
190 $action_items[] =
$f->button()->shy(
192 $ilCtrl->getLinkTarget($this->parent_obj,
"copyPageForm")
201 $action_items[] =
$f->button()->shy(
203 $ilCtrl->getLinkTarget($this->parent_obj,
"confirmPortfolioPageDeletion")
207 $ilCtrl->setParameter($this->parent_obj,
"prtf_page",
"");
210 if (count($action_items) > 0) {
211 $first = array_shift($action_items);
212 $ks[] =
$f->button()->standard(
225 if (count($action_items) > 0) {
226 $ks[] =
$f->dropdown()->standard($action_items);
228 $this->tpl->setVariable(
230 $this->gui->ui()->renderer()->render([$ks])
235 $this->tpl->setVariable(
"ID", $a_set[
"id"]);
236 $this->tpl->setVariable(
"VAL_ORDER_NR", $a_set[
"order_nr"]);
static getAllPortfolioPages(int $a_portfolio_id)
Get pages of portfolio.
getNodeData(int $a_node_id, ?int $a_tree_pk=null)
get all information of a node.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
setFormAction(string $a_form_action, bool $a_multipart=false)
addCommandButton(string $a_cmd, string $a_text, string $a_onclick='', string $a_id="", string $a_class="")
static getGotoLink(int $a_node_id, int $a_obj_id, string $a_additional="")
loadLanguageModule(string $a_module)
Load language module.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static _lookupTitle(int $obj_id)
ilObjPortfolioBase $portfolio
setRowTemplate(string $a_template, string $a_template_dir="")
Set row template.
ILIAS Portfolio InternalGUIService $gui
Portfolio view gui base class.
setTitle(string $a_title, string $a_icon="", string $a_icon_alt="")
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
setLimit(int $a_limit=0, int $a_default_limit=0)
addColumn(string $a_text, string $a_sort_field="", string $a_width="", bool $a_is_checkbox_action_column=false, string $a_class="", string $a_tooltip="", bool $a_tooltip_with_html=false)
disable(string $a_module_name)
__construct(?object $a_parent_obj, string $a_parent_cmd="", string $a_template_context="")
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...