ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilSCORM2004NodeGUI Class Reference

Class ilSCORM2004NodeGUI. More...

+ Inheritance diagram for ilSCORM2004NodeGUI:
+ Collaboration diagram for ilSCORM2004NodeGUI:

Public Member Functions

 __construct ($a_slm_obj, $a_node_id=0)
 constructor More...
 
 setParentGUI ($a_parentgui)
 Set Parent GUI class (ilObjSCORM2004LearningModuleGUI). More...
 
 getParentGUI ()
 Get Parent GUI class (ilObjSCORM2004LearningModuleGUI). More...
 
 getNodeObject ($a_node_id)
 Get node object (chapter/sco/page) More...
 
 putInTree ($a_parent_id, $a_target)
 put this object into content object tree More...
 
 showOrganization ()
 Confirm deletion screen (delete page or structure objects) More...
 
 insertChapter ()
 Insert Chapter. More...
 
 insertSco ()
 Insert Sco. More...
 
 insertAsset ()
 Insert Asset. More...
 
 insertPage ()
 Insert Page. More...
 
 insertTemplateGUI ()
 Insert Page with Layout. More...
 
 insertSpecialPage ()
 Insert special page. More...
 
 collapseAll ()
 Collapse all. More...
 
 ExpandAll ()
 Expand all. More...
 
 saveAllTitles ()
 Save Titles. More...
 
 deleteNodes ()
 Delete nodes in the hierarchy. More...
 
 cancelDelete ()
 cancel delete More...
 
 confirmedDelete ()
 confirmed delete More...
 
 setLocator ()
 Set Locator Items. More...
 
 setContentStyle ()
 Set content style sheet. More...
 
 copyItems ($a_return="showOrganization")
 Copy items to clipboard. More...
 
 cutItems ($a_return="showOrganization")
 Copy items to clipboard, then cut them from the current tree. More...
 
 insertPageClip ()
 Insert pages from clipboard. More...
 
 insertScoClip ()
 Insert scos from clipboard. More...
 
 insertAssetClip ()
 Insert assets from clipboard. More...
 
 insertLMChapterClip ()
 Insert scos from clipboard. More...
 

Data Fields

 $node_object
 
 $slm_object
 

Protected Attributes

 $lng
 
 $ctrl
 
 $tpl
 
 $tabs
 
 $locator
 
 $user
 

Detailed Description

Class ilSCORM2004NodeGUI.

Base GUI class for scorm nodes (Chapter, SCO and Page)

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 14 of file class.ilSCORM2004NodeGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilSCORM2004NodeGUI::__construct (   $a_slm_obj,
  $a_node_id = 0 
)

constructor

Parameters
object$a_content_objnode object

Definition at line 54 of file class.ilSCORM2004NodeGUI.php.

References $DIC, getNodeObject(), and user().

55  {
56  global $DIC;
57 
58  $this->lng = $DIC->language();
59  $this->ctrl = $DIC->ctrl();
60  $this->tpl = $DIC["tpl"];
61  $this->tabs = $DIC->tabs();
62  $this->locator = $DIC["ilLocator"];
63  $this->user = $DIC->user();
64  $this->slm_object = $a_slm_obj;
65  $this->node_object = null;
66 
67  if ($a_node_id > 0) {
68  $this->getNodeObject($a_node_id);
69  }
70  }
global $DIC
Definition: saml.php:7
getNodeObject($a_node_id)
Get node object (chapter/sco/page)
user()
Definition: user.php:4
+ Here is the call graph for this function:

Member Function Documentation

◆ cancelDelete()

ilSCORM2004NodeGUI::cancelDelete ( )

cancel delete

Definition at line 334 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, and $ilCtrl.

335  {
337  $ilCtrl->redirect($this, "showOrganization");
338  }
global $ilCtrl
Definition: ilias.php:18

◆ collapseAll()

ilSCORM2004NodeGUI::collapseAll ( )

Collapse all.

Definition at line 289 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, and getParentGUI().

290  {
292 
293  $this->getParentGUI()->collapseAll(false);
294  $ilCtrl->redirect($this, "showOrganization");
295  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ confirmedDelete()

ilSCORM2004NodeGUI::confirmedDelete ( )

confirmed delete

Definition at line 343 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, and getParentGUI().

344  {
346 
347  $this->getParentGUI()->confirmedDelete(false);
348  $ilCtrl->redirect($this, "showOrganization");
349  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ copyItems()

ilSCORM2004NodeGUI::copyItems (   $a_return = "showOrganization")

Copy items to clipboard.

Definition at line 504 of file class.ilSCORM2004NodeGUI.php.

References $_POST, $ctrl, $ilCtrl, $lng, array, ilSCORM2004Node\clipboardCopy(), ilUtil\sendFailure(), ilUtil\sendInfo(), ilEditClipboard\setAction(), ilUtil\stripSlashesArray(), and ilSCORM2004Node\uniqueTypesCheck().

505  {
507  $lng = $this->lng;
508 
509  $items = ilUtil::stripSlashesArray($_POST["id"]);
510  $todel = array(); // delete IDs < 0 (needed for non-js editing)
511  foreach ($items as $k => $item) {
512  if ($item < 0) {
513  $todel[] = $k;
514  }
515  }
516  foreach ($todel as $k) {
517  unset($items[$k]);
518  }
519  if (!ilSCORM2004Node::uniqueTypesCheck($items)) {
520  ilUtil::sendFailure($lng->txt("sahs_choose_pages_chap_scos_ass_only"), true);
521  $ilCtrl->redirect($this, $a_return);
522  }
523  ilSCORM2004Node::clipboardCopy($this->slm_object->getId(), $items);
524 
525  // @todo: move this to a service since it can be used here, too
526  include_once("./Modules/LearningModule/classes/class.ilEditClipboard.php");
528  ilUtil::sendInfo($lng->txt("cont_selected_items_have_been_copied"), true);
529 
530  $ilCtrl->redirect($this, $a_return);
531  }
static clipboardCopy($a_slm_obj_id, $a_ids)
Copy a set of chapters/pages/scos into the clipboard.
global $ilCtrl
Definition: ilias.php:18
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static uniqueTypesCheck($a_items)
Check for unique types (all pages or all chapters or all scos)
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
static stripSlashesArray($a_arr, $a_strip_html=true, $a_allow="")
Strip slashes from array.
static setAction($a_action)
$_POST["username"]
+ Here is the call graph for this function:

◆ cutItems()

ilSCORM2004NodeGUI::cutItems (   $a_return = "showOrganization")

Copy items to clipboard, then cut them from the current tree.

Definition at line 536 of file class.ilSCORM2004NodeGUI.php.

References $_POST, $ctrl, $ilCtrl, $lng, array, ilSCORM2004Node\clipboardCut(), ilUtil\sendFailure(), ilUtil\sendInfo(), ilEditClipboard\setAction(), ilUtil\stripSlashesArray(), and ilSCORM2004Node\uniqueTypesCheck().

537  {
539  $lng = $this->lng;
540 
541  $items = ilUtil::stripSlashesArray($_POST["id"]);
542  $todel = array(); // delete IDs < 0 (needed for non-js editing)
543  foreach ($items as $k => $item) {
544  if ($item < 0) {
545  $todel[] = $k;
546  }
547  }
548  foreach ($todel as $k) {
549  unset($items[$k]);
550  }
551 
552  if (!ilSCORM2004Node::uniqueTypesCheck($items)) {
553  ilUtil::sendFailure($lng->txt("sahs_choose_pages_chap_scos_ass_only"), true);
554  $ilCtrl->redirect($this, $a_return);
555  }
556 
557  ilSCORM2004Node::clipboardCut($this->slm_object->getId(), $items);
558 
559  include_once("./Modules/LearningModule/classes/class.ilEditClipboard.php");
561 
562  ilUtil::sendInfo($lng->txt("cont_selected_items_have_been_cut"), true);
563 
564  $ilCtrl->redirect($this, $a_return);
565  }
static clipboardCut($a_slm_obj_id, $a_ids)
Cut and copy a set of chapters/pages into the clipboard.
global $ilCtrl
Definition: ilias.php:18
static sendInfo($a_info="", $a_keep=false)
Send Info Message to Screen.
static uniqueTypesCheck($a_items)
Check for unique types (all pages or all chapters or all scos)
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
static stripSlashesArray($a_arr, $a_strip_html=true, $a_allow="")
Strip slashes from array.
static setAction($a_action)
$_POST["username"]
+ Here is the call graph for this function:

◆ deleteNodes()

ilSCORM2004NodeGUI::deleteNodes ( )

Delete nodes in the hierarchy.

Definition at line 323 of file class.ilSCORM2004NodeGUI.php.

References $_GET, $ctrl, $ilCtrl, and getParentGUI().

324  {
326 
327  $ilCtrl->setParameter($this, "backcmd", $_GET["backcmd"]);
328  $this->getParentGUI()->deleteNodes($ilCtrl->getFormAction($this));
329  }
$_GET["client_id"]
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ ExpandAll()

ilSCORM2004NodeGUI::ExpandAll ( )

Expand all.

Definition at line 300 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, and getParentGUI().

301  {
303 
304  $this->getParentGUI()->expandAll(false);
305  $ilCtrl->redirect($this, "showOrganization");
306  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ getNodeObject()

ilSCORM2004NodeGUI::getNodeObject (   $a_node_id)

Get node object (chapter/sco/page)

Definition at line 95 of file class.ilSCORM2004NodeGUI.php.

References ilSCORM2004NodeFactory\getInstance().

Referenced by __construct().

96  {
97  include_once("./Modules/Scorm2004/classes/class.ilSCORM2004NodeFactory.php");
98  $this->node_object = ilSCORM2004NodeFactory::getInstance(
99  $this->slm_object,
100  $a_node_id,
101  false
102  );
103  }
static getInstance($a_slm_object, $a_id=0, $a_halt=true)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getParentGUI()

ilSCORM2004NodeGUI::getParentGUI ( )

Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).

Returns
object Parent GUI class

Definition at line 87 of file class.ilSCORM2004NodeGUI.php.

Referenced by collapseAll(), confirmedDelete(), deleteNodes(), ilSCORM2004PageNodeGUI\executeCommand(), ExpandAll(), insertAsset(), insertChapter(), insertLMChapterClip(), insertPage(), insertSco(), insertSpecialPage(), insertTemplateGUI(), saveAllTitles(), setLocator(), and showOrganization().

88  {
89  return $this->parentgui;
90  }
+ Here is the caller graph for this function:

◆ insertAsset()

ilSCORM2004NodeGUI::insertAsset ( )

Insert Asset.

Definition at line 247 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $res, and getParentGUI().

248  {
250 
251  $res = $this->getParentGUI()->insertAsset(false);
252  $ilCtrl->setParameter($this, "highlight", $res["items"]);
253  $ilCtrl->redirect($this, "showOrganization", "node_" . $res["node_id"]);
254  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
foreach($_POST as $key=> $value) $res
+ Here is the call graph for this function:

◆ insertAssetClip()

ilSCORM2004NodeGUI::insertAssetClip ( )

Insert assets from clipboard.

Definition at line 604 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $ilUser, $user, ilHierarchyFormGUI\getPostNodeId(), and ilSCORM2004Node\insertAssetClip().

605  {
608 
609  ilSCORM2004Node::insertAssetClip($this->slm_object);
610 
611  $ilCtrl->redirect(
612  $this,
613  "showOrganization",
615  );
616  }
static getPostNodeId()
Get node ID of _POST input.
global $ilCtrl
Definition: ilias.php:18
$ilUser
Definition: imgupload.php:18
static insertAssetClip($a_slm_obj, $a_type="ass")
Insert assets from clipboard.
+ Here is the call graph for this function:

◆ insertChapter()

ilSCORM2004NodeGUI::insertChapter ( )

Insert Chapter.

Definition at line 223 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $res, and getParentGUI().

224  {
226 
227  $res = $this->getParentGUI()->insertChapter(false);
228  $ilCtrl->setParameter($this, "highlight", $res["items"]);
229  $ilCtrl->redirect($this, "showOrganization", "node_" . $res["node_id"]);
230  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
foreach($_POST as $key=> $value) $res
+ Here is the call graph for this function:

◆ insertLMChapterClip()

ilSCORM2004NodeGUI::insertLMChapterClip ( )

Insert scos from clipboard.

Definition at line 621 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $ilUser, $user, getParentGUI(), and setLocator().

622  {
625 
626  $this->setLocator();
627  $this->setTabs();
628  $this->getParentGUI()->insertLMChapterClip();
629  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
setLocator()
Set Locator Items.
global $ilCtrl
Definition: ilias.php:18
$ilUser
Definition: imgupload.php:18
+ Here is the call graph for this function:

◆ insertPage()

ilSCORM2004NodeGUI::insertPage ( )

Insert Page.

Definition at line 259 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $res, and getParentGUI().

260  {
262 
263  $res = $this->getParentGUI()->insertPage(false);
264  $ilCtrl->setParameter($this, "highlight", $res["items"]);
265  $ilCtrl->redirect($this, "showOrganization", "node_" . $res["node_id"]);
266  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
foreach($_POST as $key=> $value) $res
+ Here is the call graph for this function:

◆ insertPageClip()

ilSCORM2004NodeGUI::insertPageClip ( )

Insert pages from clipboard.

Definition at line 570 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $ilUser, $user, ilHierarchyFormGUI\getPostNodeId(), and ilSCORM2004Node\insertPageClip().

571  {
574 
575  ilSCORM2004Node::insertPageClip($this->slm_object);
576 
577  $ilCtrl->redirect(
578  $this,
579  "showOrganization",
581  );
582  }
static getPostNodeId()
Get node ID of _POST input.
static insertPageClip($a_slm_obj)
Insert pages from clipboard.
global $ilCtrl
Definition: ilias.php:18
$ilUser
Definition: imgupload.php:18
+ Here is the call graph for this function:

◆ insertSco()

ilSCORM2004NodeGUI::insertSco ( )

Insert Sco.

Definition at line 235 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $res, and getParentGUI().

236  {
238 
239  $res = $this->getParentGUI()->insertSco(false);
240  $ilCtrl->setParameter($this, "highlight", $res["items"]);
241  $ilCtrl->redirect($this, "showOrganization", "node_" . $res["node_id"]);
242  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
foreach($_POST as $key=> $value) $res
+ Here is the call graph for this function:

◆ insertScoClip()

ilSCORM2004NodeGUI::insertScoClip ( )

Insert scos from clipboard.

Definition at line 587 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $ilUser, $user, ilHierarchyFormGUI\getPostNodeId(), and ilSCORM2004Node\insertScoClip().

588  {
591 
592  ilSCORM2004Node::insertScoClip($this->slm_object);
593 
594  $ilCtrl->redirect(
595  $this,
596  "showOrganization",
598  );
599  }
static getPostNodeId()
Get node ID of _POST input.
static insertScoClip($a_slm_obj)
Insert scos from clipboard.
global $ilCtrl
Definition: ilias.php:18
$ilUser
Definition: imgupload.php:18
+ Here is the call graph for this function:

◆ insertSpecialPage()

ilSCORM2004NodeGUI::insertSpecialPage ( )

Insert special page.

Definition at line 280 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, and getParentGUI().

281  {
283  $this->getParentGUI()->insertSpecialPage(true);
284  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ insertTemplateGUI()

ilSCORM2004NodeGUI::insertTemplateGUI ( )

Insert Page with Layout.

Definition at line 271 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, and getParentGUI().

272  {
274  $this->getParentGUI()->insertTemplateGUI(true);
275  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ putInTree()

ilSCORM2004NodeGUI::putInTree (   $a_parent_id,
  $a_target 
)

put this object into content object tree

Todo:
: move to application class

Definition at line 110 of file class.ilSCORM2004NodeGUI.php.

References $target, and ilTree\setTableNames().

111  {
112  $tree = new ilTree($this->slm_object->getId());
113  $tree->setTableNames('sahs_sc13_tree', 'sahs_sc13_tree_node');
114  $tree->setTreeTablePK("slm_id");
115 
116  /*$parent_id = (!empty($_GET["obj_id"]))
117  ? $_GET["obj_id"]
118  : $tree->getRootId();*/
119 
120  /* if (!empty($_GET["target"]))
121  {
122  $target = $_GET["target"];
123  }
124  else
125  {
126  // determine last child of current type
127  $childs =& $tree->getChildsByType($parent_id, $this->obj->getType());
128  if (count($childs) == 0)
129  {
130  $target = IL_FIRST_NODE;
131  }
132  else
133  {
134  $target = $childs[count($childs) - 1]["obj_id"];
135  }
136  }*/
137  if (!$tree->isInTree($this->node_obj->getId())) {
138  $tree->insertNode($this->node_obj->getId(), $parent_id, $target);
139  }
140  }
setTableNames($a_table_tree, $a_table_obj_data, $a_table_obj_reference="")
set table names The primary key of the table containing your object_data must be &#39;obj_id&#39; You may use...
Tree class data representation in hierachical trees using the Nested Set Model with Gaps by Joe Celco...
+ Here is the call graph for this function:

◆ saveAllTitles()

ilSCORM2004NodeGUI::saveAllTitles ( )

Save Titles.

Definition at line 311 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, getParentGUI(), and ilUtil\sendSuccess().

312  {
314 
315  $this->getParentGUI()->saveAllTitles(false);
316  ilUtil::sendSuccess($this->lng->txt("msg_obj_modified"), true);
317  $ilCtrl->redirect($this, "showOrganization");
318  }
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
+ Here is the call graph for this function:

◆ setContentStyle()

ilSCORM2004NodeGUI::setContentStyle ( )

Set content style sheet.

Definition at line 476 of file class.ilSCORM2004NodeGUI.php.

References $tpl, ilObjStyleSheet\getContentStylePath(), ilObjStyleSheet\getPlaceHolderStylePath(), and ilObjStyleSheet\getSyntaxStylePath().

Referenced by ilSCORM2004PageNodeGUI\executeCommand().

477  {
478  $tpl = $this->tpl;
479 
480  // content styles
481  include_once("./Services/Style/Content/classes/class.ilObjStyleSheet.php");
482  $tpl->setCurrentBlock("ContentStyle");
483  $tpl->setVariable(
484  "LOCATION_CONTENT_STYLESHEET",
485  ilObjStyleSheet::getContentStylePath($this->slm_object->getStyleSheetId())
486  );
487  $tpl->setVariable(
488  "LOCATION_ADDITIONAL_STYLESHEET",
490  );
491  $tpl->parseCurrentBlock();
492 
493  $tpl->setCurrentBlock("SyntaxStyle");
494  $tpl->setVariable(
495  "LOCATION_SYNTAX_STYLESHEET",
497  );
498  $tpl->parseCurrentBlock();
499  }
static getPlaceHolderStylePath()
get placeholder style path (for Page Layouts)
static getSyntaxStylePath()
get syntax style path
static getContentStylePath($a_style_id, $add_random=true)
get content style path
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setLocator()

ilSCORM2004NodeGUI::setLocator ( )

Set Locator Items.

Definition at line 354 of file class.ilSCORM2004NodeGUI.php.

References $_GET, $ctrl, $i, $ilCtrl, $locator, $path, $tpl, ilUtil\getImagePath(), getParentGUI(), and ilTree\setTableNames().

Referenced by ilSCORM2004PageNodeGUI\executeCommand(), ilSCORM2004ScoGUI\executeCommand(), ilSCORM2004ChapterGUI\executeCommand(), ilSCORM2004ScoGUI\import(), insertLMChapterClip(), ilSCORM2004ScoGUI\sahs_questions(), ilSCORM2004ScoGUI\sco_resources(), ilSCORM2004ScoGUI\showExportList(), showOrganization(), ilSCORM2004ScoGUI\showProperties(), and ilSCORM2004ChapterGUI\showProperties().

355  {
356  $ilLocator = $this->locator;
357  $tpl = $this->tpl;
359 
360  $ilLocator->addRepositoryItems($_GET["ref_id"]);
361  $this->getParentGUI()->addLocatorItems();
362 
363  if ($_GET["obj_id"] > 0) {
364  $tree = new ilTree($this->slm_object->getId());
365  $tree->setTableNames('sahs_sc13_tree', 'sahs_sc13_tree_node');
366  $tree->setTreeTablePK("slm_id");
367  $path = $tree->getPathFull($_GET["obj_id"]);
368  for ($i = 1; $i < count($path); $i++) {
369  //var_dump($path[$i]);
370  switch ($path[$i]["type"]) {
371  case "chap":
372  $ilCtrl->setParameterByClass(
373  "ilscorm2004chaptergui",
374  "obj_id",
375  $path[$i]["child"]
376  );
377  $ilLocator->addItem(
378  $path[$i]["title"],
379  $ilCtrl->getLinkTargetByClass(
380  "ilscorm2004chaptergui",
381  "showOrganization"
382  ),
383  "",
384  0,
385  $path[$i]["type"],
386  ilUtil::getImagePath("icon_chap.svg")
387  );
388  break;
389 
390  case "seqc":
391  $ilCtrl->setParameterByClass(
392  "ilscorm2004seqchaptergui",
393  "obj_id",
394  $path[$i]["child"]
395  );
396  $ilLocator->addItem(
397  $path[$i]["title"],
398  $ilCtrl->getLinkTargetByClass(
399  "ilscorm2004seqchaptergui",
400  "showOrganization"
401  ),
402  "",
403  0,
404  $path[$i]["type"],
405  ilUtil::getImagePath("icon_chap.svg")
406  );
407  break;
408 
409  case "sco":
410  $ilCtrl->setParameterByClass(
411  "ilscorm2004scogui",
412  "obj_id",
413  $path[$i]["child"]
414  );
415  $ilLocator->addItem(
416  $path[$i]["title"],
417  $ilCtrl->getLinkTargetByClass(
418  "ilscorm2004scogui",
419  "showOrganization"
420  ),
421  "",
422  0,
423  $path[$i]["type"],
424  ilUtil::getImagePath("icon_sco.svg")
425  );
426  break;
427 
428  case "ass":
429  $ilCtrl->setParameterByClass(
430  "ilscorm2004assetgui",
431  "obj_id",
432  $path[$i]["child"]
433  );
434  $ilLocator->addItem(
435  $path[$i]["title"],
436  $ilCtrl->getLinkTargetByClass(
437  "ilscorm2004assetgui",
438  "showOrganization"
439  ),
440  "",
441  0,
442  $path[$i]["type"],
443  ilUtil::getImagePath("icon_sca.svg")
444  );
445  break;
446 
447  case "page":
448  $ilCtrl->setParameterByClass(
449  "ilscorm2004pagegui",
450  "obj_id",
451  $path[$i]["child"]
452  );
453  $ilLocator->addItem(
454  $path[$i]["title"],
455  $ilCtrl->getLinkTargetByClass(
456  "ilscorm2004pagegui",
457  "edit"
458  ),
459  "",
460  0,
461  $path[$i]["type"],
462  ilUtil::getImagePath("icon_pg.svg")
463  );
464  break;
465  }
466  }
467  }
468  $ilCtrl->setParameter($this, "obj_id", $_GET["obj_id"]);
469 
470  $tpl->setLocator();
471  }
$_GET["client_id"]
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
global $ilCtrl
Definition: ilias.php:18
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
setTableNames($a_table_tree, $a_table_obj_data, $a_table_obj_reference="")
set table names The primary key of the table containing your object_data must be &#39;obj_id&#39; You may use...
Tree class data representation in hierachical trees using the Nested Set Model with Gaps by Joe Celco...
$i
Definition: disco.tpl.php:19
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setParentGUI()

ilSCORM2004NodeGUI::setParentGUI (   $a_parentgui)

Set Parent GUI class (ilObjSCORM2004LearningModuleGUI).

Parameters
object$a_parentguiParent GUI class

Definition at line 77 of file class.ilSCORM2004NodeGUI.php.

78  {
79  $this->parentgui = $a_parentgui;
80  }

◆ showOrganization()

ilSCORM2004NodeGUI::showOrganization ( )

Confirm deletion screen (delete page or structure objects)

Todo:
: check if we need this

cancel deletion of page/structure objects

Todo:
: check if we need this

page and structure object deletion

Todo:
: check if we need this

check the content object tree

Todo:
: check if we need this

Show subhiearchy of pages and subchapters

Definition at line 200 of file class.ilSCORM2004NodeGUI.php.

References $ctrl, $ilCtrl, $lng, $tabs, $tpl, ilUtil\getImagePath(), getParentGUI(), and setLocator().

Referenced by ilSCORM2004ScoGUI\executeCommand(), and ilSCORM2004ChapterGUI\executeCommand().

201  {
202  $lng = $this->lng;
204  $tpl = $this->tpl;
205  $ilTabs = $this->tabs;
206 
207  $this->setTabs();
208  $ilTabs->setTabActive("sahs_organization");
209  $this->setLocator();
210  $this->getParentGUI()->showOrganization(
211  $this->node_object->getId(),
212  $ilCtrl->getFormAction($this),
213  $this->node_object->getTitle(),
214  ilUtil::getImagePath("icon_" . $this->node_object->getType() . ".svg"),
215  $this,
216  "showOrganization"
217  );
218  }
getParentGUI()
Get Parent GUI class (ilObjSCORM2004LearningModuleGUI).
setLocator()
Set Locator Items.
global $ilCtrl
Definition: ilias.php:18
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $ctrl

◆ $lng

◆ $locator

ilSCORM2004NodeGUI::$locator
protected

Definition at line 39 of file class.ilSCORM2004NodeGUI.php.

Referenced by setLocator().

◆ $node_object

ilSCORM2004NodeGUI::$node_object

Definition at line 46 of file class.ilSCORM2004NodeGUI.php.

Referenced by ilSCORM2004PageNodeGUI\executeCommand().

◆ $slm_object

ilSCORM2004NodeGUI::$slm_object

Definition at line 47 of file class.ilSCORM2004NodeGUI.php.

◆ $tabs

◆ $tpl

◆ $user

ilSCORM2004NodeGUI::$user
protected

The documentation for this class was generated from the following file: