19 declare(strict_types=1);
35 $this->
lng->loadLanguageModule(
"book");
38 $res_id = $a_app[
'event']->getContextId();
42 $objects_manager = $DIC->bookingManager()->internal()->domain()->objects($obj_id);
49 if (count($refs) > 0) {
53 if ($b_obj->getDescription()) {
66 if ($b_obj->getDescription() || $objects_manager->hasObjectInfo($b_obj->getId())) {
72 $this->
ctrl->setParameterByClass(
"ilObjBookingPoolGUI",
"ref_id", $ref_id);
73 $this->
ctrl->setParameterByClass(
"ilbookingobjectgui",
"object_id",
$res->getObjectId());
76 if ($objects_manager->hasObjectInfo($b_obj->getId())) {
77 $this->has_files =
true;
78 $link = $this->
ctrl->getLinkTargetByClass(array(
"ilRepositoryGUI",
79 "ilObjBookingPoolGUI",
83 $link = $this->
ui->renderer()->render(
84 $this->
ui->factory()->button()->shy($objects_manager->getObjectInfoFilename($b_obj->getId()), $link)
91 $array_info = array();
92 if (($text = $b_obj->getPostText()) !=
"") {
94 $a_app[
'event']->getStart(),
95 $a_app[
'event']->getEnd()
97 $text = str_replace(
"[OBJECT]", $b_obj->getTitle(), $text);
98 $text = str_replace(
"[PERIOD]", $period, $text);
99 $array_info[] = $text;
101 if ($objects_manager->hasBookingInfo($b_obj->getId())) {
102 $this->has_files =
true;
104 $link = $this->
ctrl->getLinkTargetByClass(array(
"ilRepositoryGUI",
105 "ilObjBookingPoolGUI",
106 "ilbookingobjectgui",
107 "ilBookingProcessWithScheduleGUI" 108 ),
"deliverPostFile");
110 $array_info[] = $this->
ui->renderer()->render(
111 $this->
ui->factory()->button()->shy($objects_manager->getBookingInfoFilename($b_obj->getId()), $link)
115 $this->
addInfoProperty($this->
lng->txt(
"book_post_booking_information"), implode(
"<br>", $array_info));
119 $this->
ctrl->setParameterByClass(
'ilcalendarappointmentgui',
'app_id', $a_app[
'event']->getEntryId());
121 $this->
lng->txt(
"cal_ch_cancel_booking"),
122 $this->
ctrl->getLinkTargetByClass(
'ilcalendarappointmentgui',
'cancelBooking')
125 if (count($refs) > 0) {
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
addCalendarInfo(array $cat_info)
addObjectLinks(int $obj_id, ?array $a_appointment=null)
Add object link.
getReadableRefIds(int $a_obj_id)
addInfoSection(string $a_txt)
Add info section.
addInfoProperty(string $a_txt, string $a_val)
Add info property.
static _getStaticLink(?int $a_ref_id, string $a_type='', bool $a_fallback_goto=true, string $append="")
addAction(string $a_txt, string $a_link)
Add action.
collectPropertiesAndActions()
addMetaData(string $a_obj_type, int $a_obj_id, ?string $a_sub_obj_type=null, ?int $a_sub_obj_id=null)
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static formatPeriod(ilDateTime $start, ilDateTime $end, bool $a_skip_starting_day=false, ?ilObjUser $user=null)
Format a period of two dates Shows: 14.