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

BlockGUI class calendar selection. More...

+ Inheritance diagram for ilCalendarSelectionBlockGUI:
+ Collaboration diagram for ilCalendarSelectionBlockGUI:

Public Member Functions

 __construct ($a_seed, $a_ref_id=0)
 Constructor. More...
 
 executeCommand ()
 execute command More...
 
 getCalendars ()
 Get calendars. More...
 
 fillDataSection ()
 Fill data section. More...
 
 getHTML ()
 Get block HTML code. More...
 
- Public Member Functions inherited from ilBlockGUI
 __construct ()
 Constructor. More...
 
 addHeaderLink ($a_href, $a_text, $status=true)
 
 getHeaderLinks ()
 
 setData ($a_data)
 Set Data. More...
 
 getData ()
 Get Data. More...
 
 setBigMode ($a_bigmode)
 Set Big Mode. More...
 
 getBigMode ()
 Get Big Mode. More...
 
 setBlockId ($a_block_id=0)
 Set Block Id. More...
 
 getBlockId ()
 Get Block Id. More...
 
 setAvailableDetailLevels ($a_max, $a_min=0)
 Set Available Detail Levels. More...
 
 setCurrentDetailLevel ($a_currentdetaillevel)
 Set Current Detail Level. More...
 
 setGuiObject (&$a_gui_object)
 Set GuiObject. More...
 
 getGuiObject ()
 Get GuiObject. More...
 
 getCurrentDetailLevel ()
 Get Current Detail Level. More...
 
 setTitle ($a_title)
 Set Title. More...
 
 getTitle ()
 Get Title. More...
 
 setImage ($a_image)
 Set Image. More...
 
 getImage ()
 Get Image. More...
 
 setOffset ($a_offset)
 Set Offset. More...
 
 getOffset ()
 Get Offset. More...
 
 correctOffset ()
 
 setLimit ($a_limit)
 Set Limit. More...
 
 getLimit ()
 Get Limit. More...
 
 setEnableEdit ($a_enableedit)
 Set EnableEdit. More...
 
 getEnableEdit ()
 Get EnableEdit. More...
 
 setRepositoryMode ($a_repositorymode)
 Set RepositoryMode. More...
 
 getRepositoryMode ()
 Get RepositoryMode. More...
 
 setFooterInfo ($a_footerinfo, $a_hide_and_icon=false)
 Set Footer Info. More...
 
 getFooterInfo ($a_hide_and_icon=false)
 Get Footer Info. More...
 
 setSubtitle ($a_subtitle)
 Set Subtitle. More...
 
 getSubtitle ()
 Get Subtitle. More...
 
 setRefId ($a_refid)
 Set Ref Id (only used if isRepositoryObject() is true). More...
 
 getRefId ()
 Get Ref Id (only used if isRepositoryObject() is true). More...
 
 setAdminCommands ($a_admincommands)
 Set Administration Commmands. More...
 
 getAdminCommands ()
 Get Administration Commmands. More...
 
 setColSpan ($a_colspan)
 Set Columns Span. More...
 
 getColSpan ()
 Get Columns Span. More...
 
 setEnableDetailRow ($a_enabledetailrow)
 Set EnableDetailRow. More...
 
 getEnableDetailRow ()
 Get EnableDetailRow. More...
 
 setEnableNumInfo ($a_enablenuminfo)
 Set Enable Item Number Info. More...
 
 getEnableNumInfo ()
 Get Enable Item Number Info. More...
 
 setProperties ($a_properties)
 This function is supposed to be used for block type specific properties, that should be inherited through ilColumnGUI->setBlockProperties. More...
 
 getProperty ($a_property)
 
 setProperty ($a_property, $a_value)
 
 setRowTemplate ($a_rowtemplatename, $a_rowtemplatedir="")
 Set Row Template Name. More...
 
 getNavParameter ()
 
 getDetailParameter ()
 
 getConfigParameter ()
 
 getMoveParameter ()
 
 getRowTemplateName ()
 Get Row Template Name. More...
 
 getRowTemplateDir ()
 Get Row Template Directory. More...
 
 addBlockCommand ( $a_href, $a_text, $a_target="", $a_img="", $a_right_aligned=false, $a_checked=false, $a_html="")
 Add Block Command. More...
 
 getBlockCommands ()
 Get Block commands. More...
 
 addHeaderCommand ($a_href, $a_text, $a_as_close=false)
 Add Header Block Command. More...
 
 getHeaderCommands ()
 Get Header Block commands. More...
 
 addFooterLink ( $a_text, $a_href="", $a_onclick="", $a_block_id="", $a_top=false, $a_omit_separator=false, $a_checked=false)
 Add a footer text/link. More...
 
 getFooterLinks ()
 Get footer links. More...
 
 clearFooterLinks ()
 Clear footer links. More...
 
 handleDetailLevel ()
 Handle read/write current detail level. More...
 
 getHTML ()
 Handle config status. More...
 
 fillHeaderCommands ()
 Fill header commands block. More...
 
 fillHeaderTitleBlock ()
 Fill header title block (title and. More...
 
 setDataSection ($a_content)
 Call this from overwritten fillDataSection(), if standard row based data is not used. More...
 
 fillDataSection ()
 Standard implementation for row based data. More...
 
 fillRow ($a_set)
 
 fillFooter ()
 
 fillPreviousNext ()
 Fill previous/next row. More...
 
 setPreviousNextLinks ()
 Get previous/next linkbar. More...
 
 fillFooterLinks ($a_top=false, $a_numinfo="")
 Fill footer links. More...
 
 fillDetailRow ()
 Fill Detail Setting Row. More...
 

Static Public Member Functions

static isRepositoryObject ()
 Is this a repository object. More...
 
static getBlockType ()
 Get block type. More...
 
static getScreenMode ()
 Get Screen Mode for current command. More...
 
- Static Public Member Functions inherited from ilBlockGUI
static getBlockType ()
 
static isRepositoryObject ()
 
static getScreenMode ()
 Get Screen Mode for current command. More...
 

Data Fields

const CAL_GRP_CURRENT_CONT_CONS = "curr_cont_cons"
 
const CAL_GRP_CURRENT_CONT = "curr_cont"
 
const CAL_GRP_PERSONAL = "personal"
 
const CAL_GRP_OTHERS = "others"
 

Static Public Attributes

static $block_type = "cal_sel"
 

Protected Member Functions

 buildPath ($a_ref_id)
 Build path for ref id. More...
 
 renderItem ($a_set, $a_tpl)
 Render item. More...
 
- Protected Member Functions inherited from ilBlockGUI
 fillRowColor ($a_placeholder="CSS_ROW")
 
 preloadData (array $data)
 Can be overwritten in subclasses. More...
 

Protected Attributes

 $calendar_groups = array()
 
 $calendars = array()
 
 $ref_id = 0
 
 $obj_id = 0
 
- Protected Attributes inherited from ilBlockGUI
 $data = array()
 
 $colspan = 1
 
 $enablenuminfo = true
 
 $detail_min = 0
 
 $detail_max = 0
 
 $bigmode = false
 
 $footer_links = array()
 
 $block_id = 0
 
 $header_commands = array()
 
 $allow_moving = true
 
 $move = array("left" => false, "right" => false, "up" => false, "down" => false)
 
 $enabledetailrow = true
 
 $header_links = array()
 
 $footerinfo = false
 
 $footerinfo_icon = false
 
 $block_commands = array()
 
 $max_count = false
 
 $close_command = false
 
 $image = false
 
 $property = false
 
 $nav_value = ""
 
 $css_row = ""
 
 $dropdown
 
 $tpl
 
 $main_tpl
 
 $user
 
 $ctrl
 
 $access
 
 $lng
 
 $obj_def
 

Detailed Description

BlockGUI class calendar selection.

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

Definition at line 15 of file class.ilCalendarSelectionBlockGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilCalendarSelectionBlockGUI::__construct (   $a_seed,
  $a_ref_id = 0 
)

Constructor.

Definition at line 41 of file class.ilCalendarSelectionBlockGUI.php.

References $ilCtrl, ilBlockGUI\$lng, ilCalendarUserSettings\_getInstance(), ilObject\_lookupObjId(), ilBlockGUI\addBlockCommand(), array, ilCalendarUserSettings\CAL_SELECTION_ITEMS, ilCalendarUserSettings\CAL_SELECTION_MEMBERSHIP, IL_CAL_DATE, ilBlockGUI\setLimit(), and ilBlockGUI\setTitle().

42  {
43  global $ilCtrl, $lng;
44 
45  $this->lng = $lng;
46  parent::__construct();
47  $lng->loadLanguageModule('pd');
48  $lng->loadLanguageModule('dateplaner');
49  $this->ref_id = $a_ref_id;
50  $this->obj_id = ilObject::_lookupObjId($this->ref_id);
51 
52  $this->setLimit(5);
53  $this->allow_moving = false;
54  $this->seed = $a_seed;
55 
56  $this->setTitle($lng->txt('cal_table_categories'));
57 
58  include_once('./Services/Calendar/classes/class.ilCalendarUserSettings.php');
59  $sel_type = ilCalendarUserSettings::_getInstance()->getCalendarSelectionType();
60  $ilCtrl->setParameterByClass("ilcalendarcategorygui", 'calendar_mode', ilCalendarUserSettings::CAL_SELECTION_ITEMS);
61  $ilCtrl->setParameterByClass("ilcalendarcategorygui", 'seed', $this->seed->get(IL_CAL_DATE));
62  $this->addBlockCommand(
63  $ilCtrl->getLinkTargetByClass("ilcalendarcategorygui", 'switchCalendarMode'),
64  $lng->txt('pd_my_offers'),
65  "",
66  "",
67  false,
69  );
70  $ilCtrl->setParameterByClass("ilcalendarcategorygui", 'calendar_mode', ilCalendarUserSettings::CAL_SELECTION_MEMBERSHIP);
71  $ilCtrl->setParameterByClass("ilcalendarcategorygui", 'seed', $this->seed->get(IL_CAL_DATE));
72  $this->addBlockCommand(
73  $ilCtrl->getLinkTargetByClass("ilcalendarcategorygui", 'switchCalendarMode'),
74  $lng->txt('pd_my_memberships'),
75  "",
76  "",
77  false,
79  );
80 
81  $ilCtrl->setParameterByClass("ilcalendarcategorygui", 'calendar_mode', "");
82  $this->addBlockCommand(
83  $ilCtrl->getLinkTargetByClass("ilcalendarcategorygui", 'add'),
84  $lng->txt('cal_add_calendar')
85  );
86 
87  $this->calendar_groups = array(
88  self::CAL_GRP_CURRENT_CONT_CONS => $lng->txt("cal_grp_" . self::CAL_GRP_CURRENT_CONT_CONS),
89  self::CAL_GRP_CURRENT_CONT => $lng->txt("cal_grp_" . self::CAL_GRP_CURRENT_CONT),
90  self::CAL_GRP_PERSONAL => $lng->txt("cal_grp_" . self::CAL_GRP_PERSONAL),
91  self::CAL_GRP_OTHERS => $lng->txt("cal_grp_" . self::CAL_GRP_OTHERS)
92  );
93  }
global $ilCtrl
Definition: ilias.php:18
setTitle($a_title)
Set Title.
static _getInstance()
get instance for logged in user
static _lookupObjId($a_id)
Create styles array
The data for the language used.
addBlockCommand( $a_href, $a_text, $a_target="", $a_img="", $a_right_aligned=false, $a_checked=false, $a_html="")
Add Block Command.
setLimit($a_limit)
Set Limit.
const IL_CAL_DATE
+ Here is the call graph for this function:

Member Function Documentation

◆ buildPath()

ilCalendarSelectionBlockGUI::buildPath (   $a_ref_id)
protected

Build path for ref id.

Parameters
int$a_ref_idref id

Definition at line 225 of file class.ilCalendarSelectionBlockGUI.php.

References $counter, ilBlockGUI\$data, and $path.

Referenced by getCalendars().

226  {
227  global $tree;
228 
229  $path_arr = $tree->getPathFull($a_ref_id, ROOT_FOLDER_ID);
230  $counter = 0;
231  unset($path_arr[count($path_arr) - 1]);
232 
233  foreach ($path_arr as $data) {
234  if ($counter++) {
235  $path .= " -> ";
236  }
237  $path .= $data['title'];
238  }
239  if (strlen($path) > 30) {
240  return '...' . substr($path, -30);
241  }
242  return $path;
243  }
$counter
+ Here is the caller graph for this function:

◆ executeCommand()

ilCalendarSelectionBlockGUI::executeCommand ( )

execute command

Definition at line 128 of file class.ilCalendarSelectionBlockGUI.php.

References $ilCtrl.

129  {
130  global $ilCtrl;
131 
132  $next_class = $ilCtrl->getNextClass();
133  $cmd = $ilCtrl->getCmd("getHTML");
134 
135  switch ($next_class) {
136  default:
137  return $this->$cmd();
138  }
139  }
global $ilCtrl
Definition: ilias.php:18

◆ fillDataSection()

ilCalendarSelectionBlockGUI::fillDataSection ( )

Fill data section.

Definition at line 249 of file class.ilCalendarSelectionBlockGUI.php.

References $ilCtrl, ilBlockGUI\$lng, ilBlockGUI\$tpl, $txt, $type, ilObject\_lookupType(), ilUtil\getImagePath(), renderItem(), and ilBlockGUI\setDataSection().

250  {
251  global $lng, $ilCtrl;
252 
253  $tpl = new ilTemplate("tpl.cal_selection_block_content.html", true, true, "Services/Calendar");
254 
255  foreach ($this->calendar_groups as $type => $txt) {
256  foreach ($this->calendars[$type] as $c) {
257  $this->renderItem($c, $tpl);
258  }
259  if (count($this->calendars[$type]) > 0) {
260  if ($type == self::CAL_GRP_CURRENT_CONT) {
261  $txt = $lng->txt("cal_grp_curr_" . ilObject::_lookupType($this->obj_id));
262  }
263  if ($type == self::CAL_GRP_CURRENT_CONT_CONS) {
264  $txt = $lng->txt("cal_grp_curr_crs_cons");
265  }
266  $tpl->setCurrentBlock("item_grp");
267  $tpl->setVariable("GRP_HEAD", $txt);
268  $tpl->parseCurrentBlock();
269  }
270  }
271 
272  $tpl->setVariable("TXT_SHOW", $lng->txt("refresh"));
273  $tpl->setVariable("CMD_SHOW", "saveSelection");
274  $tpl->setVariable("TXT_ACTION", $lng->txt("select"));
275  $tpl->setVariable("SRC_ACTION", ilUtil::getImagePath("arrow_downright.svg"));
276  $tpl->setVariable("FORM_ACTION", $ilCtrl->getFormActionByClass("ilcalendarcategorygui"));
277  $tpl->setVariable("TXT_SELECT_ALL", $lng->txt("select_all"));
278 
279  $this->setDataSection($tpl->get());
280  }
$type
setDataSection($a_content)
Call this from overwritten fillDataSection(), if standard row based data is not used.
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
$txt
Definition: error.php:11
static _lookupType($a_id, $a_reference=false)
lookup object type
+ Here is the call graph for this function:

◆ getBlockType()

static ilCalendarSelectionBlockGUI::getBlockType ( )
static

Get block type.

Returns
string Block type.

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

111  {
112  return self::$block_type;
113  }

◆ getCalendars()

ilCalendarSelectionBlockGUI::getCalendars ( )

Get calendars.

Definition at line 144 of file class.ilCalendarSelectionBlockGUI.php.

References $ilUser, $ref_id, ilObject\_getAllReferences(), ilCalendarCategories\_getInstance(), ilCalendarVisibility\_getInstanceByUserId(), ilObject\_lookupType(), array, buildPath(), ilCalendarCategory\lookupCategorySortIndex(), ilUtil\sortArray(), ilCalendarCategory\TYPE_BOOK, ilCalendarCategory\TYPE_CH, ilCalendarCategory\TYPE_OBJ, ilCalendarCategory\TYPE_USR, and user().

Referenced by getHTML().

145  {
146  global $ilUser,$tree;
147 
148  include_once('./Services/Calendar/classes/class.ilCalendarCategories.php');
149  include_once('./Services/Calendar/classes/class.ilCalendarVisibility.php');
150 
151  $hidden_obj = ilCalendarVisibility::_getInstanceByUserId($ilUser->getId(), $this->ref_id);
152  $hidden = $hidden_obj->getHidden();
153  $visible = $hidden_obj->getVisible();
154 
155  $cats = ilCalendarCategories::_getInstance($ilUser->getId());
156  $all = $cats->getCategoriesInfo();
157  $tmp_title_counter = array();
158  $categories = array();
159  foreach ($all as $category) {
160  //if ($category["obj_id"] == 255)
161  //{var_dump($category); exit;}
162  $tmp_arr['obj_id'] = $category['obj_id'];
163  $tmp_arr['id'] = $category['cat_id'];
164  $tmp_arr['hidden'] = (bool) in_array($category['cat_id'], $hidden);
165  $tmp_arr['visible'] = (bool) in_array($category['cat_id'], $visible);
166  $tmp_arr['title'] = $category['title'];
167  $tmp_arr['type'] = $category['type'];
168  $tmp_arr['source_ref_id'] = $category['source_ref_id'];
169 
170  // Append object type to make type sortable
171  $tmp_arr['type_sortable'] = ilCalendarCategory::lookupCategorySortIndex($category['type']);
172  if ($category['type'] == ilCalendarCategory::TYPE_OBJ) {
173  $tmp_arr['type_sortable'] .= ('_' . ilObject::_lookupType($category['obj_id']));
174  }
175 
176  $tmp_arr['color'] = $category['color'];
177  $tmp_arr['editable'] = $category['editable'];
178 
179  $categories[] = $tmp_arr;
180 
181  // count title for appending the parent container if there is more than one entry.
182  $tmp_title_counter[$category['type'] . '_' . $category['title']]++;
183  }
184 
185  $path_categories = array();
186  foreach ($categories as $cat) {
187  if ($cat['type'] == ilCalendarCategory::TYPE_OBJ) {
188  if ($tmp_title_counter[$cat['type'] . '_' . $cat['title']] > 1) {
189  foreach (ilObject::_getAllReferences($cat['obj_id']) as $ref_id) {
190  $cat['path'] = $this->buildPath($ref_id);
191  break;
192  }
193  }
194  }
195  $path_categories[] = $cat;
196  }
197  $path_categories = ilUtil::sortArray($path_categories, 'title', "asc");
198 
199 
200  $this->calendars[self::CAL_GRP_CURRENT_CONT_CONS] = array();
201  $this->calendars[self::CAL_GRP_CURRENT_CONT] = array();
202  $this->calendars[self::CAL_GRP_PERSONAL] = array();
203  $this->calendars[self::CAL_GRP_OTHERS] = array();
204 
205  foreach ($path_categories as $cal) {
206  if ($cal["type"] == ilCalendarCategory::TYPE_CH && $this->obj_id > 0) {
207  $this->calendars[self::CAL_GRP_CURRENT_CONT_CONS][] = $cal;
208  } elseif ($cal["type"] == ilCalendarCategory::TYPE_OBJ && ($this->obj_id > 0 && ($cal["obj_id"] == $this->obj_id
209  || $this->ref_id == $cal["source_ref_id"]))) {
210  $this->calendars[self::CAL_GRP_CURRENT_CONT][] = $cal;
211  } elseif ($cal["type"] == ilCalendarCategory::TYPE_USR || $cal["type"] == ilCalendarCategory::TYPE_BOOK ||
212  ($cal["type"] == ilCalendarCategory::TYPE_CH && $this->user->getId() == $cal["obj_id"])) {
213  $this->calendars[self::CAL_GRP_PERSONAL][] = $cal;
214  } else {
215  $this->calendars[self::CAL_GRP_OTHERS][] = $cal;
216  }
217  }
218  }
static sortArray( $array, $a_array_sortby, $a_array_sortorder=0, $a_numeric=false, $a_keep_keys=false)
sortArray
static lookupCategorySortIndex($a_type_id)
Lookup sort index of calendar type.
user()
Definition: user.php:4
static _getAllReferences($a_id)
get all reference ids of object
static _getInstanceByUserId($a_user_id, $a_ref_id=0)
get instance by user id
$ilUser
Definition: imgupload.php:18
buildPath($a_ref_id)
Build path for ref id.
static _getInstance($a_usr_id=0)
get singleton instance
Create styles array
The data for the language used.
static _lookupType($a_id, $a_reference=false)
lookup object type
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getHTML()

ilCalendarSelectionBlockGUI::getHTML ( )

Get block HTML code.

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

References $ilCtrl, $ilSetting, $ilUser, ilBlockGUI\$lng, and getCalendars().

355  {
356  global $ilCtrl, $lng, $ilUser, $ilAccess, $ilSetting;
357 
358  $this->getCalendars();
359 
360  return parent::getHTML();
361  }
global $ilCtrl
Definition: ilias.php:18
$ilUser
Definition: imgupload.php:18
global $ilSetting
Definition: privfeed.php:17
+ Here is the call graph for this function:

◆ getScreenMode()

static ilCalendarSelectionBlockGUI::getScreenMode ( )
static

Get Screen Mode for current command.

Definition at line 118 of file class.ilCalendarSelectionBlockGUI.php.

References $ilCtrl, and IL_SCREEN_SIDE.

119  {
120  global $ilCtrl;
121 
122  return IL_SCREEN_SIDE;
123  }
global $ilCtrl
Definition: ilias.php:18
const IL_SCREEN_SIDE

◆ isRepositoryObject()

static ilCalendarSelectionBlockGUI::isRepositoryObject ( )
static

Is this a repository object.

Returns
string Block type.

Definition at line 100 of file class.ilCalendarSelectionBlockGUI.php.

101  {
102  return false;
103  }

◆ renderItem()

ilCalendarSelectionBlockGUI::renderItem (   $a_set,
  $a_tpl 
)
protected

Render item.

Parameters
array$a_setitem datat

Definition at line 287 of file class.ilCalendarSelectionBlockGUI.php.

References $_GET, $ilCtrl, $type, ilObject\_lookupType(), ilUtil\getImagePath(), ilCalendarCategory\TYPE_BOOK, ilCalendarCategory\TYPE_CH, ilCalendarCategory\TYPE_GLOBAL, ilCalendarCategory\TYPE_OBJ, and ilCalendarCategory\TYPE_USR.

Referenced by fillDataSection().

288  {
289  global $ilCtrl;
290 
291  if (strlen($a_set['path'])) {
292  $a_tpl->setCurrentBlock('calendar_path');
293  $a_tpl->setVariable('ADD_PATH_INFO', $a_set['path']);
294  $a_tpl->parseCurrentBlock();
295  }
296 
297  $a_tpl->setCurrentBlock("item");
298 
299  $a_tpl->setVariable('VAL_ID', $a_set['id']);
300  if ($this->obj_id == 0) {
301  if (!$a_set['hidden']) {
302  $a_tpl->setVariable('VAL_CHECKED', 'checked="checked"');
303  }
304  } else { // if calendar is shown and repo object id (course group given)
305  if ($a_set["obj_id"] == $this->obj_id) {
306  $a_tpl->setVariable('VAL_CHECKED', 'checked="checked"');
307  $a_tpl->setVariable('VAL_DISABLED', 'disabled');
308  } elseif ($a_set['visible']) {
309  $a_tpl->setVariable('VAL_CHECKED', 'checked="checked"');
310  }
311  }
312  $a_tpl->setVariable('VAL_TITLE', $a_set['title']);
313  $a_tpl->setVariable('BGCOLOR', $a_set['color']);
314 
315  $ilCtrl->setParameterByClass("ilcalendarpresentationgui", 'category_id', $a_set['id']);
316  $a_tpl->setVariable('EDIT_LINK', $ilCtrl->getLinkTargetByClass("ilcalendarpresentationgui", ''));
317  $ilCtrl->setParameterByClass("ilcalendarpresentationgui", 'category_id', $_GET["category_id"]);
318  $a_tpl->setVariable('TXT_EDIT', $this->lng->txt('edit'));
319 
320  switch ($a_set['type']) {
322  $a_tpl->setVariable('IMG_SRC', ilUtil::getImagePath('icon_calg.svg'));
323  $a_tpl->setVariable('IMG_ALT', $this->lng->txt('cal_type_system'));
324  break;
325 
327  $a_tpl->setVariable('IMG_SRC', ilUtil::getImagePath('icon_usr.svg'));
328  $a_tpl->setVariable('IMG_ALT', $this->lng->txt('cal_type_personal'));
329  break;
330 
332  $type = ilObject::_lookupType($a_set['obj_id']);
333  $a_tpl->setVariable('IMG_SRC', ilUtil::getImagePath('icon_' . $type . '.svg'));
334  $a_tpl->setVariable('IMG_ALT', $this->lng->txt('cal_type_' . $type));
335  break;
336 
338  $a_tpl->setVariable('IMG_SRC', ilUtil::getImagePath('icon_book.svg'));
339  $a_tpl->setVariable('IMG_ALT', $this->lng->txt('cal_type_' . $type));
340  break;
341 
343  $a_tpl->setVariable('IMG_SRC', ilUtil::getImagePath('icon_calch.svg'));
344  $a_tpl->setVariable('IMG_ALT', $this->lng->txt('cal_ch_ch'));
345  break;
346  }
347 
348  $a_tpl->parseCurrentBlock();
349  }
$type
$_GET["client_id"]
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)
static _lookupType($a_id, $a_reference=false)
lookup object type
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $block_type

ilCalendarSelectionBlockGUI::$block_type = "cal_sel"
static

Definition at line 17 of file class.ilCalendarSelectionBlockGUI.php.

◆ $calendar_groups

ilCalendarSelectionBlockGUI::$calendar_groups = array()
protected

Definition at line 25 of file class.ilCalendarSelectionBlockGUI.php.

◆ $calendars

ilCalendarSelectionBlockGUI::$calendars = array()
protected

Definition at line 26 of file class.ilCalendarSelectionBlockGUI.php.

◆ $obj_id

ilCalendarSelectionBlockGUI::$obj_id = 0
protected

Definition at line 36 of file class.ilCalendarSelectionBlockGUI.php.

◆ $ref_id

ilCalendarSelectionBlockGUI::$ref_id = 0
protected

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

Referenced by getCalendars().

◆ CAL_GRP_CURRENT_CONT

const ilCalendarSelectionBlockGUI::CAL_GRP_CURRENT_CONT = "curr_cont"

Definition at line 20 of file class.ilCalendarSelectionBlockGUI.php.

◆ CAL_GRP_CURRENT_CONT_CONS

const ilCalendarSelectionBlockGUI::CAL_GRP_CURRENT_CONT_CONS = "curr_cont_cons"

Definition at line 19 of file class.ilCalendarSelectionBlockGUI.php.

◆ CAL_GRP_OTHERS

const ilCalendarSelectionBlockGUI::CAL_GRP_OTHERS = "others"

Definition at line 22 of file class.ilCalendarSelectionBlockGUI.php.

◆ CAL_GRP_PERSONAL

const ilCalendarSelectionBlockGUI::CAL_GRP_PERSONAL = "personal"

Definition at line 21 of file class.ilCalendarSelectionBlockGUI.php.


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