ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
class.ilBookingReservationsTableGUI.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2010 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once("./Services/Table/classes/class.ilTable2GUI.php");
5include_once 'Modules/BookingManager/classes/class.ilBookingReservation.php';
6require_once "Services/Calendar/classes/class.ilCalendarUtil.php";
7
17{
18 protected $ref_id; // int
19 protected $filter; // array
20 protected $pool_id; // int
21 protected $show_all; // bool
22 protected $has_schedule; // bool
23 protected $objects; // array
24 protected $group_id; // int
25 protected $advmd; // [array]
26
38 function __construct($a_parent_obj, $a_parent_cmd, $a_ref_id, $a_pool_id, $a_show_all, $a_has_schedule, array $a_filter_pre = null, $a_group_id = null)
39 {
40 global $ilCtrl, $lng, $ilUser, $ilAccess;
41
42 $this->pool_id = $a_pool_id;
43 $this->ref_id = $a_ref_id;
44 $this->show_all = $a_show_all;
45 $this->has_schedule = (bool)$a_has_schedule;
46 $this->group_id = $a_group_id;
47
48 $this->advmd = ilObjBookingPool::getAdvancedMDFields($this->pool_id);
49
50 $this->setId("bkrsv".$a_ref_id);
51
52 parent::__construct($a_parent_obj, $a_parent_cmd);
53
54 $this->setTitle($lng->txt("book_reservations_list"));
55
56 $this->addColumn("", "", 1);
57 $this->addColumn($this->lng->txt("title"), "title");
58
59 $selected = $this->getSelectedColumns();
60 $cols = $this->getSelectableColumns();
61
62 if($this->has_schedule)
63 {
64 $this->lng->loadLanguageModule("dateplaner");
65
66 $this->addColumn($this->lng->txt("date"), "date");
67 if(in_array("week", $selected))
68 {
69 $this->addColumn($this->lng->txt("wk_short"), "week");
70 unset($cols["week"]);
71 }
72 if(in_array("weekday", $selected))
73 {
74 $this->addColumn($this->lng->txt("cal_weekday"), "weekday");
75 unset($cols["weekday"]);
76 }
77 $this->addColumn($this->lng->txt("book_schedule_slot"), "slot");
78 $this->addColumn($this->lng->txt("book_no_of_objects"), "counter");
79
80 $this->setDefaultOrderField("date");
81 $this->setDefaultOrderDirection("asc");
82 }
83 else
84 {
85 $this->addColumn($this->lng->txt("status"), "status");
86
87 $this->setDefaultOrderField("title");
88 $this->setDefaultOrderDirection("asc");
89 }
90
91 foreach($this->getSelectedColumns() as $col)
92 {
93 if(array_key_exists($col, $cols))
94 {
95 $this->addColumn($cols[$col]["txt"], $col);
96 }
97 }
98
99 $this->addColumn($this->lng->txt("user"), "user_name");
100 $this->addColumn($this->lng->txt("actions"));
101
102 $this->setEnableHeader(true);
103 $this->setFormAction($ilCtrl->getFormAction($a_parent_obj, $a_parent_cmd));
104 $this->setRowTemplate("tpl.booking_reservation_row.html", "Modules/BookingManager");
105 $this->setResetCommand("resetLogFilter");
106 $this->setFilterCommand("applyLogFilter");
107 $this->setDisableFilterHiding(true);
108
109 $this->initFilter($a_filter_pre);
110
111 if($this->group_id)
112 {
113 $this->setLimit(9999);
114 $this->disable("numinfo");
115 $this->filters = array();
116 }
117 else
118 {
119 $this->setExportFormats(array(self::EXPORT_CSV, self::EXPORT_EXCEL));
120 }
121
122 if($ilUser->getId() != ANONYMOUS_USER_ID)
123 {
124 /*
125 if($ilAccess->checkAccess('write', '', $this->ref_id))
126 {
127 $this->addMultiCommand('rsvInUse', $lng->txt('book_set_in_use'));
128 $this->addMultiCommand('rsvNotInUse', $lng->txt('book_set_not_in_use'));
129 }
130 */
131
132 $this->addMultiCommand('rsvConfirmCancel', $lng->txt('book_set_cancel'));
133 // $this->addMultiCommand('rsvUncancel', $lng->txt('book_set_not_cancel'));
134 $this->setSelectAllCheckbox('mrsv');
135 }
136
137 $this->getItems($this->getCurrentFilter());
138
140 }
141
142 function getSelectableColumns($a_only_advmd = false)
143 {
144 $cols = array();
145
146 if($this->has_schedule &&
147 !(bool)$a_only_advmd)
148 {
149 $this->lng->loadLanguageModule("dateplaner");
150
151 $cols["week"] = array(
152 "txt" => $this->lng->txt("wk_short"),
153 "default" => true
154 );
155
156 $cols["weekday"] = array(
157 "txt" => $this->lng->txt("cal_weekday"),
158 "default" => true
159 );
160 }
161
162 foreach($this->advmd as $field)
163 {
164 $cols["advmd".$field["id"]] = array(
165 "txt" => $field["title"],
166 "default" => false
167 );
168 }
169
170 return $cols;
171 }
172
173
177 function initFilter(array $a_filter_pre = null)
178 {
179 if(is_array($a_filter_pre) &&
180 isset($a_filter_pre["object"]))
181 {
182 $_SESSION["form_".$this->getId()]["object"] = serialize($a_filter_pre["object"]);
183 if($this->has_schedule)
184 {
185 $_SESSION["form_".$this->getId()]["fromto"] = serialize(array(
186 "from" => serialize(new ilDateTime(date("Y-m-d"), IL_CAL_DATE)),
187 "to" => ""
188 ));
189 }
190 }
191
192 $this->objects = array();
193 include_once "Modules/BookingManager/classes/class.ilBookingObject.php";
194 foreach(ilBookingObject::getList($this->pool_id) as $item)
195 {
196 $this->objects[$item["booking_object_id"]] = $item["title"];
197 }
198 $item = $this->addFilterItemByMetaType("object", ilTable2GUI::FILTER_SELECT);
199 $item->setOptions(array(""=>$this->lng->txt('book_all'))+$this->objects);
200 $this->filter["object"] = $item->getValue();
201
203 "title",
205 false,
206 $this->lng->txt("object")." ".$this->lng->txt("title")."/".$this->lng->txt("description")
207 );
208 $this->filter["title"] = $title->getValue();
209
210 if($this->has_schedule)
211 {
212 if(!$_SESSION["form_".$this->getId()]["fromto"])
213 {
214 // default: from today
215 $_SESSION["form_".$this->getId()]["fromto"] = serialize(array(
216 "from" => serialize(new ilDateTime(date("Y-m-d"), IL_CAL_DATE)),
217 "to" => null
218 ));
219 }
220
221 $item = $this->addFilterItemByMetaType("fromto", ilTable2GUI::FILTER_DATE_RANGE, false, $this->lng->txt('book_fromto'));
222 $this->filter["fromto"] = $item->getDate();
223
224 // only needed for full log
225 if($this->show_all)
226 {
227 // see ilObjBookingPoolGUI::buildDatesBySchedule()
228 $map = array_flip(array('su', 'mo', 'tu', 'we', 'th', 'fr', 'sa'));
229
230 $options = array(""=>$this->lng->txt('book_all'));
231
232 // schedule to slot
233 require_once "Modules/BookingManager/classes/class.ilBookingSchedule.php";
234 foreach(ilBookingSchedule::getList($this->pool_id) as $def)
235 {
236 $schedule = new ilBookingSchedule($def["booking_schedule_id"]);
237 foreach($schedule->getDefinition() as $day => $slots)
238 {
239 $day_caption = ilCalendarUtil::_numericDayToString($map[$day], false);
240
241 foreach($slots as $slot)
242 {
243 $idx = $map[$day]."_".$slot;
244 $options[$idx] = $day_caption.", ".$slot;
245 }
246 }
247 }
248
249 ksort($options);
250
251 $item = $this->addFilterItemByMetaType("book_schedule_slot", ilTable2GUI::FILTER_SELECT);
252 $item->setOptions($options);
253 $this->filter["slot"] = $item->getValue();
254 }
255 }
256
257 // status
258 $valid_status = array(-ilBookingReservation::STATUS_CANCELLED,
260 if(!$this->has_schedule)
261 {
262 $options = array(""=>$this->lng->txt('book_all'));
263 }
264 else
265 {
266 $options = array();
267 }
268 foreach($valid_status as $loop)
269 {
270 if($loop > 0)
271 {
272 $options[$loop] = $this->lng->txt('book_reservation_status_'.$loop);
273 }
274 else
275 {
276 $options[$loop] = $this->lng->txt('book_not').' '.$this->lng->txt('book_reservation_status_'.-$loop);
277 }
278 }
279 $item = $this->addFilterItemByMetaType("status", ilTable2GUI::FILTER_SELECT);
280 $item->setOptions($options);
281 $this->filter["status"] = $item->getValue();
282
283 // only needed for full log
284 if($this->show_all)
285 {
286 $options = array(""=>$this->lng->txt('book_all'))+
287 ilBookingReservation::getUserFilter(array_keys($this->objects));
289 $item->setOptions($options);
290 $this->filter["user_id"] = $item->getValue();
291 }
292 }
293
299 {
300 $filter = array();
301 if($this->filter["object"])
302 {
303 $filter["object"] = $this->filter["object"];
304 }
305 if($this->filter["title"])
306 {
307 $filter["title"] = $this->filter["title"];
308 }
309 if($this->filter["status"])
310 {
311 $filter["status"] = $this->filter["status"];
312 }
313 if($this->filter["user_id"])
314 {
315 $filter["user_id"] = $this->filter["user_id"];
316 }
317
318 if($this->has_schedule)
319 {
320 if(!$filter["status"])
321 {
322 // needs distinct status because of aggregation
324 }
325 if($this->filter["slot"])
326 {
327 $filter["slot"] = $this->filter["slot"];
328 }
329
330 if($this->filter["fromto"]["from"] || $this->filter["fromto"]["to"])
331 {
332 if($this->filter["fromto"]["from"])
333 {
334 $filter["from"] = $this->filter["fromto"]["from"]->get(IL_CAL_UNIX);
335 }
336 if($this->filter["fromto"]["to"])
337 {
338 $day_end = new ilDateTime($this->filter["fromto"]["to"]->get(IL_CAL_DATE)." 23:59:59", IL_CAL_DATETIME);
339 $filter["to"] = $day_end->get(IL_CAL_UNIX);
340 }
341 }
342 }
343
344 return $filter;
345 }
346
347 function numericOrdering($a_field)
348 {
349 return in_array($a_field, array("counter", "date", "week", "weekday"));
350 }
351
356 function getItems(array $filter)
357 {
358 global $ilUser;
359
360 if(!$filter["object"])
361 {
362 $ids = array_keys($this->objects);
363 }
364 else
365 {
366 $ids = array($filter["object"]);
367 }
368
369 if(!$this->show_all)
370 {
371 $filter["user_id"] = $ilUser->getId();
372 }
373
374 include_once "Modules/BookingManager/classes/class.ilBookingReservation.php";
375 $data = ilBookingReservation::getListByDate($this->has_schedule, $ids, $filter);
376
377 if($this->advmd)
378 {
379 // advanced metadata
380 include_once('Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php');
381 $this->record_gui = new ilAdvancedMDRecordGUI(ilAdvancedMDRecordGUI::MODE_FILTER, "book", $this->pool_id, "bobj");
382 $this->record_gui->setTableGUI($this);
383 $this->record_gui->parse();
384
385 foreach(array_keys($data) as $idx)
386 {
387 $data[$idx]["pool_id"] = $this->pool_id;
388 }
389
390 include_once("./Services/AdvancedMetaData/classes/class.ilAdvancedMDValues.php");
391 $data = ilAdvancedMDValues::queryForRecords($this->pool_id, "bobj", $data, "pool_id", "object_id", $this->record_gui->getFilterElements());
392 }
393
394 $this->setData($data);
395 }
396
397 public function getAdvMDRecordGUI()
398 {
399 return $this->record_gui;
400 }
401
402 public function getOrderField()
403 {
404 $field = parent::getOrderField();
405
406 // #16560 - this will enable matchting slot sorting to date/week
407 if(in_array($field, array("date", "week")))
408 {
409 $field = "_sortdate";
410 }
411
412 return $field;
413 }
414
419 protected function fillRow($a_set)
420 {
421 global $lng, $ilAccess, $ilCtrl, $ilUser;
422
423 $selected = $this->getSelectedColumns();
424
425 $this->tpl->setVariable("TXT_TITLE", $a_set["title"]);
426
427 $can_be_cancelled = (($ilAccess->checkAccess('write', '', $this->ref_id) ||
428 $a_set['user_id'] == $ilUser->getId()) &&
429 $a_set["can_be_cancelled"]);
430
431 if($can_be_cancelled)
432 {
433 $this->tpl->setVariable("MULTI_ID", $a_set["booking_reservation_id"]);
434 }
435
436 // #11995
437 $uname = $a_set["user_name"];
438 if(!trim($uname))
439 {
440 $uname = "[".$lng->txt("user_deleted")."]";
441 }
442 else
443 {
444 //$ilCtrl->setParameter($this->parent_obj, 'user_id', $a_set['user_id']);
445 //$this->tpl->setVariable("HREF_PROFILE", $ilCtrl->getLinkTarget($this->parent_obj, 'showprofile'));
446 //$ilCtrl->setParameter($this->parent_obj, 'user_id', '');
447 include_once("./Services/User/classes/class.ilUserUtil.php");
448 $uname = ilUserUtil::getNamePresentation($a_set['user_id'], false, true, "", true);
449 }
450 $this->tpl->setVariable("TXT_CURRENT_USER", $uname);
451
452 if($this->has_schedule)
453 {
454 $this->tpl->setVariable("VALUE_DATE", ilDatePresentation::formatDate(new ilDate($a_set["date"], IL_CAL_DATE)));
455 if(in_array("week", $selected))
456 {
457 $this->tpl->setVariable("VALUE_WEEK", $a_set["week"]);
458 }
459 if(in_array("weekday", $selected))
460 {
461 $this->tpl->setVariable("VALUE_WEEKDAY", ilCalendarUtil::_numericDayToString($a_set["weekday"], false));
462 }
463 $this->tpl->setVariable("VALUE_SLOT", $a_set["slot"]);
464 $this->tpl->setVariable("VALUE_COUNTER", $a_set["counter"]);
465 }
466 else
467 {
469 {
470 $this->tpl->setVariable("TXT_STATUS", $lng->txt('book_reservation_status_'.$a_set['status']));
471 }
472 else
473 {
474 $this->tpl->setVariable("TXT_STATUS", "&nbsp;");
475 }
476 }
477
478 if($this->advmd)
479 {
480 foreach($this->advmd as $item)
481 {
482 $advmd_id = (int)$item["id"];
483
484 if(!in_array("advmd".$advmd_id, $selected))
485 {
486 continue;
487 }
488
489 $val = " ";
490 if(isset($a_set["md_".$advmd_id."_presentation"]))
491 {
492 $pb = $a_set["md_".$advmd_id."_presentation"]->getList();
493 if($pb)
494 {
495 $val = $pb;
496 }
497 }
498
499 $this->tpl->setCurrentBlock("advmd_bl");
500 $this->tpl->setVariable("VALUE_ADVMD", $val);
501 $this->tpl->parseCurrentBlock();
502 }
503 }
504
505 if($can_be_cancelled)
506 {
507 $ilCtrl->setParameter($this->parent_obj, 'reservation_id', $a_set['booking_reservation_id']);
508 $this->tpl->setVariable("URL_ACTION", $ilCtrl->getLinkTarget($this->parent_obj, 'rsvConfirmCancel'));
509 $ilCtrl->setParameter($this->parent_obj, 'reservation_id', "");
510 $this->tpl->setVariable("TXT_ACTION", $lng->txt('book_set_cancel'));
511 }
512
513 /* advsellist version
514 if (!$this->has_schedule || $date_to->get(IL_CAL_UNIX) > time())
515 {
516 include_once("./Services/UIComponent/AdvancedSelectionList/classes/class.ilAdvancedSelectionListGUI.php");
517 $alist = new ilAdvancedSelectionListGUI();
518 $alist->setId($a_set['booking_reservation_id']);
519 $alist->setListTitle($lng->txt("actions"));
520
521 $ilCtrl->setParameter($this->parent_obj, 'reservation_id', $a_set['booking_reservation_id']);
522
523 if(!$a_set['group_id'])
524 {
525 if($ilAccess->checkAccess('write', '', $this->ref_id))
526 {
527 if($a_set['status'] == ilBookingReservation::STATUS_CANCELLED)
528 {
529 // can be uncancelled?
530 // if(ilBookingReservation::getAvailableObject(array($a_set['object_id']), $date_from->get(IL_CAL_UNIX), $date_to->get(IL_CAL_UNIX)))
531 // {
532 // $alist->addItem($lng->txt('book_set_not_cancel'), 'not_cancel', $ilCtrl->getLinkTarget($this->parent_obj, 'rsvUncancel'));
533 // }
534 }
535 else if($a_set['status'] != ilBookingReservation::STATUS_IN_USE)
536 {
537 if($this->has_schedule)
538 {
539 $alist->addItem($lng->txt('book_set_in_use'), 'in_use', $ilCtrl->getLinkTarget($this->parent_obj, 'rsvInUse'));
540 }
541 $alist->addItem($lng->txt('book_set_cancel'), 'cancel', $ilCtrl->getLinkTarget($this->parent_obj, 'rsvConfirmCancel'));
542 }
543 else if($this->has_schedule)
544 {
545 $alist->addItem($lng->txt('book_set_not_in_use'), 'not_in_use', $ilCtrl->getLinkTarget($this->parent_obj, 'rsvNotInUse'));
546 }
547 }
548 else if($a_set['user_id'] == $ilUser->getId() && $a_set['status'] != ilBookingReservation::STATUS_CANCELLED)
549 {
550 $alist->addItem($lng->txt('book_set_cancel'), 'cancel', $ilCtrl->getLinkTarget($this->parent_obj, 'rsvConfirmCancel'));
551 }
552 }
553 else if($ilAccess->checkAccess('write', '', $this->ref_id) || $a_set['user_id'] == $ilUser->getId())
554 {
555 $alist->addItem($lng->txt('details'), 'details', $ilCtrl->getLinkTarget($this->parent_obj, 'logDetails'));
556 }
557
558 if(sizeof($alist->getItems()))
559 {
560 if(!$a_set['group_id'])
561 {
562 $this->tpl->setVariable('MULTI_ID', $a_set['booking_reservation_id']);
563 }
564 $this->tpl->setVariable('LAYER', $alist->getHTML());
565 }
566 }
567 */
568 }
569
570 protected function fillHeaderExcel($a_worksheet, &$a_row)
571 {
572 $a_worksheet->write($a_row, 0, $this->lng->txt("title"));
573 $col = 0;
574 if($this->has_schedule)
575 {
576 $a_worksheet->write($a_row, ++$col, $this->lng->txt("date"));
577 $a_worksheet->write($a_row, ++$col, $this->lng->txt("wk_short"));
578 $a_worksheet->write($a_row, ++$col, $this->lng->txt("cal_weekday"));
579 $a_worksheet->write($a_row, ++$col, $this->lng->txt("book_schedule_slot"));
580 $a_worksheet->write($a_row, ++$col, $this->lng->txt("book_no_of_objects"));
581 }
582 else
583 {
584 $a_worksheet->write($a_row, ++$col, $this->lng->txt("status"));
585 }
586
587 foreach($this->getSelectableColumns(true) as $advmd_col)
588 {
589 $a_worksheet->write($a_row, ++$col, $advmd_col["txt"]);
590 }
591
592 $a_worksheet->write($a_row, ++$col, $this->lng->txt("user"));
593 }
594
595 protected function fillRowExcel($a_worksheet, &$a_row, $a_set)
596 {
597 $a_worksheet->write($a_row, 0, $a_set["title"]);
598 $col = 0;
599 if($this->has_schedule)
600 {
601 $a_worksheet->write($a_row, ++$col, ilDatePresentation::formatDate(new ilDate($a_set["date"], IL_CAL_DATE)));
602 $a_worksheet->write($a_row, ++$col, $a_set["week"]);
603 $a_worksheet->write($a_row, ++$col, ilCalendarUtil::_numericDayToString($a_set["weekday"], false));
604 $a_worksheet->write($a_row, ++$col, $a_set["slot"]);
605 $a_worksheet->write($a_row, ++$col, $a_set["counter"]);
606 }
607 else
608 {
609 $status = "";
611 {
612 $status = $this->lng->txt('book_reservation_status_'.$a_set['status']);
613 }
614 $a_worksheet->write($a_row, ++$col, $status);
615 }
616 $a_worksheet->write($a_row, ++$col, $a_set['user_name']);
617
618 if($this->advmd)
619 {
620 foreach($this->advmd as $item)
621 {
622 $advmd_id = (int)$item["id"];
623 $val = " ";
624 if(isset($a_set["md_".$advmd_id."_presentation"]))
625 {
626 $pb = $a_set["md_".$advmd_id."_presentation"]->getList();
627 if($pb)
628 {
629 $val = $pb;
630 }
631 }
632 $a_worksheet->write($a_row, ++$col, $val);
633 }
634 }
635 }
636
637 protected function fillHeaderCSV($a_csv)
638 {
639 $a_csv->addColumn($this->lng->txt("title"));
640 if($this->has_schedule)
641 {
642 $a_csv->addColumn($this->lng->txt("date"));
643 $a_csv->addColumn($this->lng->txt("wk_short"));
644 $a_csv->addColumn($this->lng->txt("cal_weekday"));
645 $a_csv->addColumn($this->lng->txt("book_schedule_slot"));
646 $a_csv->addColumn($this->lng->txt("book_no_of_objects"));
647 }
648 else
649 {
650 $a_csv->addColumn($this->lng->txt("status"));
651 }
652
653 foreach($this->getSelectableColumns(true) as $advmd_col)
654 {
655 $a_csv->addColumn($advmd_col["txt"]);
656 }
657
658 $a_csv->addColumn($this->lng->txt("user"));
659 $a_csv->addRow();
660 }
661
662 protected function fillRowCSV($a_csv, $a_set)
663 {
664 $a_csv->addColumn($a_set["title"]);
665 if($this->has_schedule)
666 {
667 $a_csv->addColumn(ilDatePresentation::formatDate(new ilDate($a_set["date"], IL_CAL_DATE)));
668 $a_csv->addColumn($a_set["week"]);
669 $a_csv->addColumn(ilCalendarUtil::_numericDayToString($a_set["weekday"], false));
670 $a_csv->addColumn($a_set["slot"]);
671 $a_csv->addColumn($a_set["counter"]);
672 }
673 else
674 {
675 $status = "";
677 {
678 $status = $this->lng->txt('book_reservation_status_'.$a_set['status']);
679 }
680 $a_csv->addColumn($status);
681 }
682
683 if($this->advmd)
684 {
685 foreach($this->advmd as $item)
686 {
687 $advmd_id = (int)$item["id"];
688 $val = " ";
689 if(isset($a_set["md_".$advmd_id."_presentation"]))
690 {
691 $pb = $a_set["md_".$advmd_id."_presentation"]->getList();
692 if($pb)
693 {
694 $val = $pb;
695 }
696 }
697 $a_csv->addColumn($val);
698 }
699 }
700
701 $a_csv->addColumn($a_set['user_name']);
702 $a_csv->addRow();
703 }
704}
705
706?>
$_SESSION["AccountId"]
const IL_CAL_DATE
const IL_CAL_UNIX
const IL_CAL_DATETIME
static queryForRecords($a_obj_id, $a_subtype, $a_records, $a_obj_id_key, $a_obj_subid_key, array $a_amet_filter=null)
Query data for given object records.
static getList($a_pool_id, $a_title=null)
Get list of booking objects for given type
static getListByDate($a_has_schedule, array $a_object_ids, array $filter=null)
List all reservations by date.
static getUserFilter(array $a_object_ids)
Get all users who have reservations for object(s)
initFilter(array $a_filter_pre=null)
Init filter.
__construct($a_parent_obj, $a_parent_cmd, $a_ref_id, $a_pool_id, $a_show_all, $a_has_schedule, array $a_filter_pre=null, $a_group_id=null)
Constructor.
numericOrdering($a_field)
Should this field be sorted numeric?
fillHeaderExcel($a_worksheet, &$a_row)
Excel Version of Fill Header.
getItems(array $filter)
Gather data and build rows.
fillRowExcel($a_worksheet, &$a_row, $a_set)
Excel Version of Fill Row.
fillRowCSV($a_csv, $a_set)
CSV Version of Fill Row.
fillHeaderCSV($a_csv)
CSV Version of Fill Header.
schedule for booking ressource
static getList($a_pool_id)
Get list of booking objects for given pool.
static _numericDayToString($a_day, $a_long=true)
get
static setUseRelativeDates($a_status)
set use relative dates
static formatDate(ilDateTime $date)
Format a date @access public.
@classDescription Date and time handling
Class for single dates.
static getAdvancedMDFields($a_glossary_id)
Class ilTable2GUI.
getSelectedColumns()
Get selected columns.
setEnableHeader($a_enableheader)
Set Enable Header.
setDisableFilterHiding($a_val=true)
Set disable filter hiding.
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.
setExportFormats(array $formats)
Set available export formats.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
initFilter()
Init filter.
getId()
Get element id.
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.
setLimit($a_limit=0, $a_default_limit=0)
set max.
addMultiCommand($a_cmd, $a_text)
Add Command button.
getSelectableColumns()
Get selectable columns.
setDefaultOrderField($a_defaultorderfield)
Set Default order field.
setSelectAllCheckbox($a_select_all_checkbox)
Set the name of the checkbox that should be toggled with a select all button.
setId($a_val)
Set id.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
addFilterItemByMetaType($id, $type=self::FILTER_TEXT, $a_optional=false, $caption=NULL)
Add filter by standard type.
setDefaultOrderDirection($a_defaultorderdirection)
Set Default order direction.
setFilterCommand($a_val, $a_caption=null)
Set filter command.
disable($a_module_name)
diesables particular modules of table
static getNamePresentation($a_user_id, $a_user_image=false, $a_profile_link=false, $a_profile_back_link="", $a_force_first_lastname=false, $a_omit_login=false, $a_sortable=true, $a_return_data_array=false)
Default behaviour is:
global $ilCtrl
Definition: ilias.php:18
global $lng
Definition: privfeed.php:40
if(!is_array($argv)) $options
global $ilUser
Definition: imgupload.php:15