4 include_once(
"./Services/Table/classes/class.ilTable2GUI.php");
 
   23         function __construct($a_parent_obj, $a_parent_cmd, $a_ref_id, $a_type_id)
 
   27                 $this->ref_id = $a_ref_id;
 
   28                 $this->type_id = $a_type_id;
 
   29                 $this->
setId(
"bkobj");
 
   33                 include_once 
'Modules/BookingManager/classes/class.ilBookingType.php';
 
   35                 $this->
setTitle($lng->txt(
"book_objects_list").
" ".$type->getTitle());
 
   39                 $this->
addColumn($this->lng->txt(
"title"), 
"title");
 
   41                 if ($ilAccess->checkAccess(
'write', 
'', $this->ref_id))
 
   43                         $this->
addColumn($this->lng->txt(
"status"));
 
   44                         $this->
addColumn($this->lng->txt(
"book_current_user"));
 
   45                         $this->
addColumn($this->lng->txt(
"book_period"));
 
   48                 $this->
addColumn($this->lng->txt(
"actions"));
 
   51                 $this->
setFormAction($ilCtrl->getFormAction($a_parent_obj, $a_parent_cmd));
 
   52                 $this->
setRowTemplate(
"tpl.booking_object_row.html", 
"Modules/BookingManager");
 
   65                 include_once 
'Modules/BookingManager/classes/class.ilBookingObject.php';
 
   80             $this->tpl->setVariable(
"TXT_TITLE", $a_set[
"title"]);
 
   82                 if ($ilAccess->checkAccess(
'write', 
'', $this->ref_id))
 
   84                         include_once 
'Modules/BookingManager/classes/class.ilBookingReservation.php';
 
   88                 if ($ilAccess->checkAccess(
'write', 
'', $this->ref_id))
 
   90                         $this->tpl->setCurrentBlock(
'details');
 
   99                                         $this->tpl->setVariable(
"TXT_STATUS", $lng->txt(
'book_reservation_status_'.$reservation[
'status']));
 
  101                                 $this->tpl->setVariable(
"TXT_CURRENT_USER", ilObjUser::_lookupFullName($reservation[
'user_id']));
 
  106                                 $this->tpl->setVariable(
"TXT_STATUS", 
"");
 
  107                                 $this->tpl->setVariable(
"TXT_CURRENT_USER", 
"");
 
  108                                 $this->tpl->setVariable(
"VALUE_DATE", 
"");
 
  111                         $this->tpl->parseCurrentBlock();
 
  116                 $ilCtrl->setParameter($this->parent_obj, 
'object_id', $a_set[
'booking_object_id']);
 
  118                 if ($a_set[
"schedule_id"])
 
  120                         $items[
'book'] = array($lng->txt(
'book_book'), $ilCtrl->getLinkTarget($this->parent_obj, 
'book'));
 
  123                 if ($ilAccess->checkAccess(
'write', 
'', $this->ref_id))
 
  127                                 $items[
'delete'] = array($lng->txt(
'delete'), $ilCtrl->getLinkTarget($this->parent_obj, 
'confirmDelete'));
 
  130                         $items[
'edit'] = array($lng->txt(
'edit'), $ilCtrl->getLinkTarget($this->parent_obj, 
'edit'));
 
  135                         $this->tpl->setCurrentBlock(
"actions");
 
  136                         foreach($items as $item)
 
  138                                 $this->tpl->setVariable(
"ACTION_CAPTION", $item[0]);
 
  139                                 $this->tpl->setVariable(
"ACTION_LINK", $item[1]);
 
  140                                 $this->tpl->parseCurrentBlock();