47 $this->tree =& $a_tree;
49 $this->temp_var =
"LOCATOR";
52 $this->show_user =
false;
57 $this->temp_var = $a_temp_var;
62 $this->obj_id = $a_obj_id;
67 $this->cont_obj =& $a_cont_obj;
77 $this->tpl->addBlockFile($this->temp_var,
"locator",
"tpl.locator.html",
"Services/Locator");
79 if (($this->obj_id != 0) && $this->tree->isInTree($this->obj_id))
81 $path = $this->tree->getPathFull($this->obj_id);
85 $path = $this->tree->getPathFull($this->tree->getRootId());
86 if ($this->obj_id != 0)
88 $path[] = array(
"type" =>
"pg",
"child" => $this->obj_id,
97 if ($key < count(
$path)-$modifier)
99 $this->tpl->touchBlock(
"locator_separator");
102 $this->tpl->setCurrentBlock(
"locator_item");
104 if (
$row[
"child"] == 1)
106 $title = $this->cont_obj->getTitle();
108 $cmdClass = $a_gui_class;
116 $cmdClass =
"ilStructureObjectGUI";
118 if ($this->ctrl->getCmdClass() !=
"ilstructureobjectgui")
120 $transit = array($a_gui_class);
125 $cmdClass =
"ilLMPageObjectGUI";
127 if ($this->ctrl->getCmdClass() !=
"illmpageobjectgui")
129 $transit = array($a_gui_class);
134 $this->tpl->setVariable(
"ITEM",
$title);
135 $obj_str = (
$row[
"child"] == 1)
137 :
"&obj_id=".
$row[
"child"];
139 $this->ctrl->setParameterByClass($cmdClass,
"obj_id",
$row[
"child"]);
140 $link = $this->ctrl->getLinkTargetByClass($cmdClass,
$cmd, $transit);
141 $this->ctrl->setParameterByClass($cmdClass,
"obj_id",
$_GET[
"obj_id"]);
142 $this->tpl->setVariable(
"LINK_ITEM", $link);
143 $this->tpl->parseCurrentBlock();
146 $this->tpl->setCurrentBlock(
"locator");
147 $this->tpl->parseCurrentBlock();