ILIAS  release_5-0 Revision 5.0.0-1144-gc4397b1f87
ilDataCollectionTreePickInputGUI Class Reference

Class ilDataCollectionDatatype. More...

+ Inheritance diagram for ilDataCollectionTreePickInputGUI:
+ Collaboration diagram for ilDataCollectionTreePickInputGUI:

Public Member Functions

 getHtml ()
 
 setValueByArray ($value)
 
- Public Member Functions inherited from ilCustomInputGUI
 __construct ($a_title="", $a_postvar="")
 Constructor. More...
 
 setHtml ($a_html)
 Set Html. More...
 
 getHtml ()
 Get Html. More...
 
 setValueByArray ($a_values)
 Set value by array. More...
 
 insert (&$a_tpl)
 Insert property html. More...
 
 checkInput ()
 Check input, strip slashes etc. More...
 
- Public Member Functions inherited from ilSubEnabledFormPropertyGUI
 addSubItem ($a_item)
 Add Subitem. More...
 
 getSubItems ()
 Get Subitems. More...
 
 getSubInputItemsRecursive ()
 returns a flat array of possibly existing subitems recursively More...
 
 checkSubItemsInput ()
 Check SubItems. More...
 
 getSubForm ()
 Get sub form html. More...
 
 getItemByPostVar ($a_post_var)
 Get item by post var. More...
 
- Public Member Functions inherited from ilFormPropertyGUI
 __construct ($a_title="", $a_postvar="")
 Constructor. More...
 
executeCommand ()
 Execute command. More...
 
 getType ()
 Get Type. More...
 
 setTitle ($a_title)
 Set Title. More...
 
 getTitle ()
 Get Title. More...
 
 setPostVar ($a_postvar)
 Set Post Variable. More...
 
 getPostVar ()
 Get Post Variable. More...
 
 getFieldId ()
 Get Post Variable. More...
 
 setInfo ($a_info)
 Set Information Text. More...
 
 getInfo ()
 Get Information Text. More...
 
 setAlert ($a_alert)
 Set Alert Text. More...
 
 getAlert ()
 Get Alert Text. More...
 
 setRequired ($a_required)
 Set Required. More...
 
 getRequired ()
 Get Required. More...
 
 setDisabled ($a_disabled)
 Set Disabled. More...
 
 getDisabled ()
 Get Disabled. More...
 
 checkInput ()
 Check input, strip slashes etc. More...
 
 setParentForm ($a_parentform)
 Set Parent Form. More...
 
 getParentForm ()
 Get Parent Form. More...
 
 setParent ($a_val)
 Set Parent GUI object. More...
 
 getParent ()
 Get Parent GUI object. More...
 
 getSubForm ()
 Get sub form html. More...
 
 hideSubForm ()
 Sub form hidden on init? More...
 
 setHiddenTitle ($a_val)
 Set hidden title (for screenreaders) More...
 
 getHiddenTitle ()
 Get hidden title. More...
 
 getItemByPostVar ($a_post_var)
 Get item by post var. More...
 
 serializeData ()
 serialize data More...
 
 unserializeData ($a_data)
 unserialize data More...
 
 writeToSession ()
 Write to session. More...
 
 clearFromSession ()
 Clear session value. More...
 
 readFromSession ()
 Read from session. More...
 
 getHiddenTag ($a_post_var, $a_value)
 Get hidden tag (used for disabled properties) More...
 
 setMulti ($a_multi, $a_sortable=false, $a_addremove=true)
 Set Multi. More...
 
 getMulti ()
 Get Multi. More...
 
 setMultiValues (array $a_values)
 Set multi values. More...
 
 getMultiValues ()
 Get multi values. More...
 
 getContentOutsideFormTag ()
 Get content that has to reside outside of the parent form tag, e.g. More...
 
 removeProhibitedCharacters ($a_text)
 Remove prohibited characters see #19159. More...
 

Protected Attributes

 $title_input
 
 $search_input
 
 $lng
 
- Protected Attributes inherited from ilCustomInputGUI
 $html
 
- Protected Attributes inherited from ilSubEnabledFormPropertyGUI
 $sub_items = array()
 
- Protected Attributes inherited from ilFormPropertyGUI
 $type
 
 $title
 
 $postvar
 
 $info
 
 $alert
 
 $required = false
 
 $parentgui
 
 $parentform
 
 $hidden_title = ""
 
 $multi = false
 
 $multi_sortable = false
 
 $multi_addremove = true
 
 $multi_values
 

Additional Inherited Members

- Protected Member Functions inherited from ilFormPropertyGUI
 setType ($a_type)
 Set Type. More...
 
 getMultiIconsHTML ()
 Get HTML for multiple value icons. More...
 

Detailed Description

Member Function Documentation

◆ getHtml()

ilDataCollectionTreePickInputGUI::getHtml ( )
Returns
string

Definition at line 65 of file class.ilDataCollectionTreePickInputGUI.php.

References $ilCtrl, $out, $tpl, ilGlyphGUI\get(), ilUtil\getImagePath(), ilFormPropertyGUI\getPostVar(), and ilGlyphGUI\REMOVE.

65  {
66  global $ilCtrl;
67  $tpl = new ilTemplate("tpl.dcl_tree.html", true, true, "Modules/DataCollection");
68  $tpl->setVariable("FIELD_ID", $this->getPostVar());
69  $tpl->setVariable("AJAX_LINK", $ilCtrl->getLinkTargetByClass("ildatacollectionrecordeditgui", "searchObjects"));
70  $tpl->setVariable("LOADER_PATH", ilUtil::getImagePath("loader.svg"));
71  $out = $this->title_input->getToolbarHTML();
72  $out .= "<a href='#' style='display:inline-block;' id='remove_{$this->getPostVar()}'>" . ilGlyphGUI::get(ilGlyphGUI::REMOVE) . "</a>";
73  $out .= $this->search_input->getTableFilterHTML();
74  $out .= $this->hidden_input->getToolbarHTML();
75  $out .= "<a href='#' id='search_button_" . $this->getPostVar() . "'>" . $this->lng->txt('search') . "</a>";
76  $out .= $tpl->get();
77 
78  return $out;
79  }
getPostVar()
Get Post Variable.
static get($a_glyph, $a_text="")
Get glyph html.
global $tpl
Definition: ilias.php:8
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)
special template class to simplify handling of ITX/PEAR
+ Here is the call graph for this function:

◆ setValueByArray()

ilDataCollectionTreePickInputGUI::setValueByArray (   $value)
Parameters
$value

Definition at line 85 of file class.ilDataCollectionTreePickInputGUI.php.

References $path, ilObject\_lookupObjId(), ilObject\_lookupTitle(), and ilFormPropertyGUI\getPostVar().

85  {
86  parent::setValueByArray($value);
87  include_once './Services/Tree/classes/class.ilPathGUI.php';
88  $path = new ilPathGUI();
89  $reference = $value[$this->getPostVar()];
90  if ($reference) {
91  $pathString = $path->getPath(ROOT_FOLDER_ID, $reference);
92  $id = ilObject::_lookupObjId($reference);
93  $this->title_input->setValue($pathString . " > " . ilObject::_lookupTitle($id));
94  $this->hidden_input->setValue($reference);
95  }
96  }
Creates a path for a start and endnode.
getPostVar()
Get Post Variable.
static _lookupTitle($a_id)
lookup object title
static _lookupObjId($a_id)
$path
Definition: index.php:22
+ Here is the call graph for this function:

Field Documentation

◆ $lng

ilDataCollectionTreePickInputGUI::$lng
protected

Definition at line 35 of file class.ilDataCollectionTreePickInputGUI.php.

◆ $search_input

ilDataCollectionTreePickInputGUI::$search_input
protected

Definition at line 31 of file class.ilDataCollectionTreePickInputGUI.php.

◆ $title_input

ilDataCollectionTreePickInputGUI::$title_input
protected

Definition at line 27 of file class.ilDataCollectionTreePickInputGUI.php.


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