ILIAS  release_7 Revision v7.30-3-g800a261c036
class.ilQuestionBrowserTableGUI.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2013 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once('./Services/Table/classes/class.ilTable2GUI.php');
5require_once 'Modules/TestQuestionPool/classes/class.ilAssQuestionPreviewGUI.php';
6require_once 'Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php';
7
19{
20 protected $notes;
21 protected $ui_factory;
22 protected $renderer;
23 protected $editable = true;
24 protected $writeAccess = false;
25 protected $totalPoints = 0;
26 protected $totalWorkingTime = '00:00:00';
27 protected $confirmdelete;
28
29 protected $taxIds = array();
30
34 protected $questionCommentingEnabled = false;
35
43 public function __construct($a_parent_obj, $a_parent_cmd, $a_write_access = false, $confirmdelete = false, $taxIds = array(), $enableCommenting = false)
44 {
45 $this->setQuestionCommentingEnabled($enableCommenting);
46
47 // Bugfix: #0019539
48 if ($confirmdelete) {
49 $this->setId("qpl_confirm_del_" . $a_parent_obj->object->getRefId());
50 } else {
51 $this->setId("qpl_qst_brows_" . $a_parent_obj->object->getRefId());
52 }
53
54 parent::__construct($a_parent_obj, $a_parent_cmd);
55
56 global $DIC;
57 $lng = $DIC['lng'];
58 $ilCtrl = $DIC['ilCtrl'];
59
60 $this->lng = $lng;
61 $this->ctrl = $ilCtrl;
62
63 $this->confirmdelete = $confirmdelete;
64 $this->setWriteAccess($a_write_access);
65 $this->taxIds = $taxIds;
66
67 $qplSetting = new ilSetting("qpl");
68
69 $this->setFormName('questionbrowser');
70 $this->setStyle('table', 'fullwidth');
71 if (!$confirmdelete) {
72 $this->addColumn('', '', '1%');
73 $this->addColumn($this->lng->txt("title"), 'title', '');
74 foreach ($this->getSelectedColumns() as $c) {
75 if (strcmp($c, 'description') == 0) {
76 $this->addColumn($this->lng->txt("description"), 'description', '');
77 }
78 if (strcmp($c, 'type') == 0) {
79 $this->addColumn($this->lng->txt("question_type"), 'ttype', '');
80 }
81 // According to mantis #12713
82 if (strcmp($c, 'points') == 0) {
83 $this->addColumn($this->lng->txt("points"), 'points', '', false, 'ilCenterForced');
84 }
85 if (strcmp($c, 'statistics') == 0) {
86 $this->addColumn($this->lng->txt('statistics'), '', '');
87 }
88 if (strcmp($c, 'author') == 0) {
89 $this->addColumn($this->lng->txt("author"), 'author', '');
90 }
91 if ($c == 'lifecycle') {
92 $this->addColumn($this->lng->txt('qst_lifecycle'), 'lifecycle', '');
93 }
94 if ($this->isQuestionCommentingEnabled() && $c == 'comments') {
95 $this->addColumn($this->lng->txt("ass_comments"), 'comments', '');
96 }
97 if (strcmp($c, 'created') == 0) {
98 $this->addColumn($this->lng->txt("create_date"), 'created', '');
99 }
100 if (strcmp($c, 'tstamp') == 0) {
101 $this->addColumn($this->lng->txt("last_update"), 'tstamp', '');
102 }
103 if (strcmp($c, 'working_time') == 0) {
104 $this->addColumn($this->lng->txt("working_time"), 'working_time', '');
105 }
106 }
107 $this->addColumn($this->lng->txt('actions'), '');
108 $this->setSelectAllCheckbox('q_id');
109 } else {
110 $this->addColumn($this->lng->txt("title"), 'title', '');
111 foreach ($this->getSelectedColumns() as $c) {
112 if (strcmp($c, 'description') == 0) {
113 $this->addColumn($this->lng->txt("description"), 'description', '');
114 }
115 if (strcmp($c, 'type') == 0) {
116 $this->addColumn($this->lng->txt("question_type"), 'ttype', '');
117 }
118 }
119 }
120
121 if ($this->getWriteAccess()) {
122 if ($confirmdelete) {
123 $this->addCommandButton('confirmDeleteQuestions', $this->lng->txt('confirm'));
124 $this->addCommandButton('cancelDeleteQuestions', $this->lng->txt('cancel'));
125 } else {
126 $this->addMultiCommand('copy', $this->lng->txt('copy'));
127 $this->addMultiCommand('move', $this->lng->txt('move'));
128 $this->addMultiCommand('exportQuestion', $this->lng->txt('export'));
129 $this->addMultiCommand('deleteQuestions', $this->lng->txt('delete'));
130 }
131 }
132
133 $this->setRowTemplate("tpl.il_as_qpl_questionbrowser_row.html", "Modules/TestQuestionPool");
134
135 $this->setFormAction($this->ctrl->getFormAction($a_parent_obj, $a_parent_cmd));
136 $this->setDefaultOrderField("title");
137 $this->setDefaultOrderDirection("asc");
138
139 $this->setShowRowsSelector(true);
140
141 if ($confirmdelete) {
142 $this->disable('sort');
143 $this->disable('select_all');
144 } else {
145 $this->enable('sort');
146 $this->enable('header');
147 $this->enable('select_all');
148 $this->setFilterCommand('filterQuestionBrowser');
149 $this->setResetCommand('resetQuestionBrowser');
150 $this->initFilter();
151 }
152
153 if ($this->isQuestionCommentingEnabled()) {
154 global $DIC; /* @var ILIAS\DI\Container $DIC */
155
156 $notesUrl = $this->ctrl->getLinkTargetByClass(
157 array("ilcommonactiondispatchergui", "ilnotegui"),
158 "",
159 "",
160 true,
161 false
162 );
163
164 ilNoteGUI::initJavascript($notesUrl, IL_NOTE_PUBLIC, $DIC->ui()->mainTemplate());
165 }
166 }
167
171 public function isQuestionCommentingEnabled() : bool
172 {
174 }
175
180 {
181 $this->questionCommentingEnabled = $questionCommentingEnabled;
182 }
183
184 protected function isCommentsColumnSelected()
185 {
186 return in_array('comments', $this->getSelectedColumns());
187 }
188
189 public function setQuestionData($questionData)
190 {
191 if ($this->isQuestionCommentingEnabled() && ($this->isCommentsColumnSelected() || $this->filter['commented'])) {
192 foreach ($questionData as $key => $data) {
193 $numComments = count(ilNote::_getNotesOfObject(
194 $this->parent_obj->object->getId(),
195 $data['question_id'],
196 'quest',
198 ));
199
200 if ($this->filter['commented'] && !$numComments) {
201 unset($questionData[$key]);
202 continue;
203 }
204
205 $questionData[$key]['comments'] = $numComments;
206 }
207 }
208
209 $this->setData($questionData);
210 }
211
212 public function getSelectableColumns()
213 {
214 global $DIC;
215 $lng = $DIC['lng'];
216 $cols["description"] = array(
217 "txt" => $lng->txt("description"),
218 "default" => true
219 );
220 $cols["type"] = array(
221 "txt" => $lng->txt("question_type"),
222 "default" => true
223 );
224 if (!$this->confirmdelete) {
225 $cols["points"] = array(
226 "txt" => $lng->txt("points"),
227 "default" => true
228 );
229 $cols["statistics"] = array(
230 "txt" => $lng->txt("statistics"),
231 "default" => true
232 );
233 $cols["author"] = array(
234 "txt" => $lng->txt("author"),
235 "default" => true
236 );
237 $cols['lifecycle'] = array(
238 'txt' => $lng->txt('qst_lifecycle'),
239 'default' => true
240 );
241 if ($this->isQuestionCommentingEnabled()) {
242 $cols["comments"] = array(
243 "txt" => $lng->txt("comments"),
244 "default" => true
245 );
246 }
247 $cols["created"] = array(
248 "txt" => $lng->txt("create_date"),
249 "default" => true
250 );
251 $cols["tstamp"] = array(
252 "txt" => $lng->txt("last_update"),
253 "default" => true
254 );
255 $cols["working_time"] = array(
256 "txt" => $lng->txt("working_time"),
257 "default" => true
258 );
259 }
260 return $cols;
261 }
262
266 public function initFilter()
267 {
268 global $DIC;
269 $lng = $DIC['lng'];
270 $rbacreview = $DIC['rbacreview'];
271 $ilUser = $DIC['ilUser'];
272
273 // title
274 include_once("./Services/Form/classes/class.ilTextInputGUI.php");
275 $ti = new ilTextInputGUI($lng->txt("title"), "title");
276 $ti->setMaxLength(64);
277 $ti->setValidationRegexp('/^[^%]+$/is');
278 $ti->setSize(20);
279 $this->addFilterItem($ti);
280 $ti->readFromSession();
281 $this->filter["title"] = $ti->getValue();
282
283 // description
284 $ti = new ilTextInputGUI($lng->txt("description"), "description");
285 $ti->setMaxLength(64);
286 $ti->setSize(20);
287 $ti->setValidationRegexp('/^[^%]+$/is');
288 $this->addFilterItem($ti);
289 $ti->readFromSession();
290 $this->filter["description"] = $ti->getValue();
291
292 if (!$this->confirmdelete) {
293 // author
294 $ti = new ilTextInputGUI($lng->txt("author"), "author");
295 $ti->setMaxLength(64);
296 $ti->setSize(20);
297 $ti->setValidationRegexp('/^[^%]+$/is');
298 $this->addFilterItem($ti);
299 $ti->readFromSession();
300 $this->filter["author"] = $ti->getValue();
301 }
302
303 // lifecycle
304 $lifecycleOptions = array_merge(
305 array('' => $this->lng->txt('qst_lifecycle_filter_all')),
306 ilAssQuestionLifecycle::getDraftInstance()->getSelectOptions($this->lng)
307 );
308 $lifecycleInp = new ilSelectInputGUI($this->lng->txt('qst_lifecycle'), 'lifecycle');
309 $lifecycleInp->setOptions($lifecycleOptions);
310 $this->addFilterItem($lifecycleInp);
311 $lifecycleInp->readFromSession();
312 $this->filter['lifecycle'] = $lifecycleInp->getValue();
313
314 // questiontype
315 include_once("./Services/Form/classes/class.ilSelectInputGUI.php");
316 include_once("./Modules/TestQuestionPool/classes/class.ilObjQuestionPool.php");
318 $options = array();
319 $options[""] = $lng->txt('filter_all_question_types');
320 foreach ($types as $translation => $row) {
321 $options[$row['type_tag']] = $translation;
322 }
323
324 $si = new ilSelectInputGUI($this->lng->txt("question_type"), "type");
325 $si->setOptions($options);
326 $this->addFilterItem($si);
327 $si->readFromSession();
328 $this->filter["type"] = $si->getValue();
329
330 if ($this->parent_obj->object->getShowTaxonomies()) {
331 require_once 'Services/Taxonomy/classes/class.ilTaxSelectInputGUI.php';
332
333 foreach ($this->taxIds as $taxId) {
334 if ($taxId == $this->parent_obj->object->getNavTaxonomyId()) {
335 continue;
336 }
337
338 $postvar = "tax_$taxId";
339
340 $inp = new ilTaxSelectInputGUI($taxId, $postvar, true);
341 $this->addFilterItem($inp);
342 $inp->readFromSession();
343 $this->filter[$postvar] = $inp->getValue();
344 }
345 }
346
347 // comments
348 if ($this->isQuestionCommentingEnabled()) {
349 $comments = new ilCheckboxInputGUI($lng->txt('ass_commented_questions_only'), 'commented');
350 $this->addFilterItem($comments);
351 $comments->readFromSession();
352 $this->filter['commented'] = $comments->getChecked();
353 }
354 }
355
356 public function fillHeader()
357 {
358 foreach ($this->column as $key => $column) {
359 if (strcmp($column['text'], $this->lng->txt("points")) == 0) {
360 $this->column[$key]['text'] = $this->lng->txt("points") . "&nbsp;(" . $this->totalPoints . ")";
361 } elseif (strcmp($column['text'], $this->lng->txt("working_time")) == 0) {
362 $this->column[$key]['text'] = $this->lng->txt("working_time") . "&nbsp;(" . $this->totalWorkingTime . ")";
363 }
364 }
365 parent::fillHeader();
366 }
367
375 public function fillRow($data)
376 {
377 global $DIC;
378 $ilUser = $DIC['ilUser'];
379 $ilAccess = $DIC['ilAccess'];
380 include_once "./Modules/TestQuestionPool/classes/class.assQuestion.php";
381 include_once "./Modules/TestQuestionPool/classes/class.assQuestionGUI.php";
382 $class = strtolower(assQuestionGUI::_getGUIClassNameForId($data["question_id"]));
383 $this->ctrl->setParameterByClass("ilAssQuestionPageGUI", "q_id", $data["question_id"]);
384 $this->ctrl->setParameterByClass("ilAssQuestionPreviewGUI", "q_id", $data["question_id"]);
385 $this->ctrl->setParameterByClass($class, "q_id", $data["question_id"]);
386 $points = 0;
387
388 $actions = new ilAdvancedSelectionListGUI();
389 $actions->setId('qst' . $data["question_id"]);
390 $actions->setListTitle($this->lng->txt('actions'));
391
392 if (!$this->confirmdelete) {
393 $this->tpl->setCurrentBlock('checkbox');
394 $this->tpl->setVariable('CB_QUESTION_ID', $data["question_id"]);
395 $this->tpl->parseCurrentBlock();
396
397 if ($data["complete"] == 0) {
398 $this->tpl->setCurrentBlock("qpl_warning");
399 $this->tpl->setVariable("IMAGE_WARNING", ilUtil::getImagePath("icon_alert.svg"));
400 $this->tpl->setVariable("ALT_WARNING", $this->lng->txt("warning_question_not_complete"));
401 $this->tpl->setVariable("TITLE_WARNING", $this->lng->txt("warning_question_not_complete"));
402 $this->tpl->parseCurrentBlock();
403 } else {
404 $points = $data["points"];
405 $this->totalWorkingTime = assQuestion::sumTimesInISO8601FormatH_i_s_Extended($this->totalWorkingTime, $data['working_time']);
406 }
407 $this->totalPoints += $points;
408
409 foreach ($this->getSelectedColumns() as $c) {
410 if (strcmp($c, 'points') == 0) {
411 $this->tpl->setCurrentBlock('points');
412 $this->tpl->setVariable("QUESTION_POINTS", $points);
413 $this->tpl->parseCurrentBlock();
414 }
415 if (strcmp($c, 'statistics') == 0) {
416 $this->tpl->setCurrentBlock('statistics');
417 $this->tpl->setVariable("LINK_ASSESSMENT", $this->ctrl->getLinkTargetByClass('ilAssQuestionPreviewGUI', ilAssQuestionPreviewGUI::CMD_STATISTICS));
418 $this->tpl->setVariable("TXT_ASSESSMENT", $this->lng->txt("statistics"));
419 include_once "./Services/Utilities/classes/class.ilUtil.php";
420 $this->tpl->setVariable("IMG_ASSESSMENT", ilUtil::getImagePath("assessment.gif", "Modules/TestQuestionPool"));
421 $this->tpl->parseCurrentBlock();
422 }
423 if (strcmp($c, 'author') == 0) {
424 $this->tpl->setCurrentBlock('author');
425 $this->tpl->setVariable("QUESTION_AUTHOR", $data["author"]);
426 $this->tpl->parseCurrentBlock();
427 }
428 if ($c == 'lifecycle') {
429 $lifecycle = ilAssQuestionLifecycle::getInstance($data['lifecycle']);
430
431 $this->tpl->setCurrentBlock('lifecycle');
432 $this->tpl->setVariable("QUESTION_LIFECYCLE", $lifecycle->getTranslation($this->lng));
433 $this->tpl->parseCurrentBlock();
434 }
435 if ($c == 'comments' && $this->isQuestionCommentingEnabled()) {
436 $this->tpl->setCurrentBlock('comments');
437 $this->tpl->setVariable("COMMENTS", $this->getCommentsHtml($data));
438 $this->tpl->parseCurrentBlock();
439 }
440 if (strcmp($c, 'created') == 0) {
441 $this->tpl->setCurrentBlock('created');
442 $this->tpl->setVariable('QUESTION_CREATED', ilDatePresentation::formatDate(new ilDateTime($data['created'], IL_CAL_UNIX)));
443 $this->tpl->parseCurrentBlock();
444 }
445 if (strcmp($c, 'tstamp') == 0) {
446 $this->tpl->setCurrentBlock('updated');
447 $this->tpl->setVariable('QUESTION_UPDATED', ilDatePresentation::formatDate(new ilDateTime($data['tstamp'], IL_CAL_UNIX)));
448 $this->tpl->parseCurrentBlock();
449 }
450 if (strcmp($c, 'working_time') == 0) {
451 $this->tpl->setCurrentBlock('working_time');
452 $this->tpl->setVariable('WORKING_TIME', $data["working_time"]);
453 $this->tpl->parseCurrentBlock();
454 }
455 }
456
457 $actions->addItem(
458 $this->lng->txt('preview'),
459 '',
460 $this->ctrl->getLinkTargetByClass('ilAssQuestionPreviewGUI', ilAssQuestionPreviewGUI::CMD_SHOW)
461 );
462 $actions->addItem(
463 $this->lng->txt('statistics'),
464 '',
465 $this->ctrl->getLinkTargetByClass('ilAssQuestionPreviewGUI', ilAssQuestionPreviewGUI::CMD_STATISTICS)
466 );
467 if ($this->getEditable()) {
468 $editHref = $this->ctrl->getLinkTargetByClass($data['type_tag'] . 'GUI', 'editQuestion');
469 $actions->addItem($this->lng->txt('edit_question'), '', $editHref);
470
471 $editPageHref = $this->ctrl->getLinkTargetByClass('ilAssQuestionPageGUI', 'edit');
472 $actions->addItem($this->lng->txt('edit_page'), '', $editPageHref);
473 }
474
475 if ($this->getWriteAccess()) {
476 $this->ctrl->setParameter($this->parent_obj, 'q_id', $data['question_id']);
477 $moveHref = $this->ctrl->getLinkTarget($this->parent_obj, 'move');
478 $this->ctrl->setParameter($this->parent_obj, 'q_id', null);
479 $actions->addItem($this->lng->txt('move'), '', $moveHref);
480
481 $this->ctrl->setParameter($this->parent_obj, 'q_id', $data['question_id']);
482 $copyHref = $this->ctrl->getLinkTarget($this->parent_obj, 'copy');
483 $this->ctrl->setParameter($this->parent_obj, 'q_id', null);
484 $actions->addItem($this->lng->txt('copy'), '', $copyHref);
485
486 $this->ctrl->setParameter($this->parent_obj, 'q_id', $data['question_id']);
487 $deleteHref = $this->ctrl->getLinkTarget($this->parent_obj, 'deleteQuestions');
488 $this->ctrl->setParameter($this->parent_obj, 'q_id', null);
489 $actions->addItem($this->lng->txt('delete'), '', $deleteHref);
490 }
491
492 if ($this->getEditable()) {
493 require_once 'Modules/TestQuestionPool/classes/class.ilAssQuestionFeedbackEditingGUI.php';
494 $this->ctrl->setParameterByClass('ilAssQuestionFeedbackEditingGUI', 'q_id', $data['question_id']);
495 $feedbackHref = $this->ctrl->getLinkTargetByClass('ilAssQuestionFeedbackEditingGUI', ilAssQuestionFeedbackEditingGUI::CMD_SHOW);
496 $this->ctrl->setParameterByClass('ilAssQuestionFeedbackEditingGUI', 'q_id', null);
497 $actions->addItem($this->lng->txt('tst_feedback'), '', $feedbackHref);
498
499 $this->ctrl->setParameterByClass('ilAssQuestionHintsGUI', 'q_id', $data['question_id']);
500 $hintsHref = $this->ctrl->getLinkTargetByClass('ilAssQuestionHintsGUI', ilAssQuestionHintsGUI::CMD_SHOW_LIST);
501 $this->ctrl->setParameterByClass('ilAssQuestionHintsGUI', 'q_id', null);
502 $actions->addItem($this->lng->txt('tst_question_hints_tab'), '', $hintsHref);
503 }
504
505 if ($this->isQuestionCommentingEnabled()) {
506 $actions->addItem(
507 $this->lng->txt('ass_comments'),
508 'comments',
509 '',
510 '',
511 '',
512 '',
513 '',
514 '',
515 $this->getCommentsAjaxLink($data['question_id'])
516 );
517 }
518 } else {
519 $this->tpl->setCurrentBlock('hidden');
520 $this->tpl->setVariable('HIDDEN_QUESTION_ID', $data["question_id"]);
521 $this->tpl->parseCurrentBlock();
522 }
523
524 foreach ($this->getSelectedColumns() as $c) {
525 if (strcmp($c, 'description') == 0) {
526 $this->tpl->setCurrentBlock('description');
527 $this->tpl->setVariable("QUESTION_COMMENT", $data['description']);
528 $this->tpl->parseCurrentBlock();
529 }
530 if (strcmp($c, 'type') == 0) {
531 $this->tpl->setCurrentBlock('type');
532 $this->tpl->setVariable("QUESTION_TYPE", assQuestion::_getQuestionTypeName($data["type_tag"]));
533 $this->tpl->parseCurrentBlock();
534 }
535 }
536 $this->tpl->setVariable('QUESTION_ID', $data["question_id"]);
537 if (!$this->confirmdelete) {
538 $this->tpl->setVariable('QUESTION_HREF_LINKED', $this->ctrl->getLinkTargetByClass('ilAssQuestionPreviewGUI', ilAssQuestionPreviewGUI::CMD_SHOW));
539 $this->tpl->setVariable('QUESTION_TITLE_LINKED', $data['title']);
540 $this->tpl->setVariable('ACTIONS', $actions->getHTML());
541 } else {
542 $this->tpl->setVariable('QUESTION_ID_UNLINKED', $data['question_id']);
543 $this->tpl->setVariable('QUESTION_TITLE_UNLINKED', $data['title']);
544 }
545 }
546
547 public function setEditable($value)
548 {
549 $this->editable = $value;
550 }
551
552 public function getEditable()
553 {
554 return $this->editable;
555 }
556
557 public function setWriteAccess($value)
558 {
559 $this->writeAccess = $value;
560 }
561
562 public function getWriteAccess()
563 {
564 return $this->writeAccess;
565 }
566
571 public function numericOrdering($column)
572 {
573 if (in_array($column, array('points', 'created', 'tstamp', 'comments'))) {
574 return true;
575 }
576
577 return false;
578 }
579
580 protected function getCommentsHtml($qData)
581 {
582 if (!$qData['comments']) {
583 return '';
584 }
585
586 $ajaxLink = $this->getCommentsAjaxLink($qData['question_id']);
587
588 return "<a class='comment' href='#' onclick=\"return " . $ajaxLink . "\">
589 <img src='" . ilUtil::getImagePath("comment_unlabeled.svg")
590 . "' alt='{$qData['comments']}'><span class='ilHActProp'>{$qData['comments']}</span></a>";
591 }
592
593 protected function getCommentsAjaxLink($questionId)
594 {
595 $ajax_hash = ilCommonActionDispatcherGUI::buildAjaxHash(1, $_GET['ref_id'], 'quest', $this->parent_obj->object->getId(), 'quest', $questionId);
596 return ilNoteGUI::getListCommentsJSCall($ajax_hash, '');
597 }
598}
$_GET["client_id"]
An exception for terminatinating execution or to throw for unit testing.
const IL_CAL_UNIX
const IL_NOTE_PUBLIC
Definition: class.ilNote.php:6
static _getGUIClassNameForId($a_q_id)
static sumTimesInISO8601FormatH_i_s_Extended($time1, $time2)
static _getQuestionTypeName($type_tag)
Return the translation for a given question type tag.
User interface class for advanced drop-down selection lists.
const CMD_SHOW_LIST
command constants
This class represents a checkbox property in a property form.
static buildAjaxHash( $a_node_type, $a_node_id, $a_obj_type, $a_obj_id, $a_sub_type=null, $a_sub_id=null, $a_news_id=0)
Build ajax hash.
static formatDate(ilDateTime $date, $a_skip_day=false, $a_include_wd=false, $include_seconds=false)
Format a date @access public.
@classDescription Date and time handling
static initJavascript($a_ajax_url, $a_type=IL_NOTE_PRIVATE, ilGlobalTemplateInterface $a_main_tpl=null)
Init javascript.
static getListCommentsJSCall($a_hash, $a_update_code=null)
Get list comments js call.
static _getNotesOfObject( $a_rep_obj_id, $a_obj_id, $a_obj_type, $a_type=IL_NOTE_PRIVATE, $a_incl_sub=false, $a_filter="", $a_all_public="y", $a_repository_mode=true, $a_sort_ascending=false, $a_news_id=0)
get all notes related to a specific object
static _getQuestionTypes($all_tags=false, $fixOrder=false, $withDeprecatedTypes=true)
setQuestionCommentingEnabled(bool $questionCommentingEnabled)
__construct($a_parent_obj, $a_parent_cmd, $a_write_access=false, $confirmdelete=false, $taxIds=array(), $enableCommenting=false)
Constructor.
getSelectableColumns()
Get selectable columns.
This class represents a selection list property in a property form.
ILIAS Setting Class.
Class ilTable2GUI.
getSelectedColumns()
Get selected columns.
setShowRowsSelector($a_value)
Toggle rows-per-page selector.
setSelectAllCheckbox($a_select_all_checkbox, $a_select_all_on_top=false)
Set the name of the checkbox that should be toggled with a select all button.
setData($a_data)
set table data @access public
setResetCommand($a_val, $a_caption=null)
Set reset filter command.
setRowTemplate($a_template, $a_template_dir="")
Set row template.
addMultiCommand($a_cmd, $a_text)
Add Command button.
addFilterItem($a_input_item, $a_optional=false)
Add filter item.
setDefaultOrderField($a_defaultorderfield)
Set Default order field.
addColumn( $a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="", $a_tooltip_with_html=false)
Add a column to the header.
setId($a_val)
Set id.
setFormName($a_formname="")
Set Form name.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
setDefaultOrderDirection($a_defaultorderdirection)
Set Default order direction.
setFilterCommand($a_val, $a_caption=null)
Set filter command.
addCommandButton($a_cmd, $a_text, $a_onclick='', $a_id="", $a_class=null)
Add Command button.
disable($a_module_name)
diesables particular modules of table
setStyle($a_element, $a_style)
enable($a_module_name)
enables particular modules of table
Select taxonomy nodes input GUI.
This class represents a text property in a property form.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
$c
Definition: cli.php:37
filter()
Definition: filter.php:2
global $DIC
Definition: goto.php:24
$ilUser
Definition: imgupload.php:18
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
$cols
Definition: xhr_table.php:11