/** * Shows access link */ public function showAccessLink() { $this->pluginObj->includeClass('class.ilAdobeConnectUserUtil.php'); $this->pluginObj->includeClass('class.ilAdobeConnectQuota.php'); $this->pluginObj->includeClass('class.ilAdobeConnectServer.php'); $presentation_url = ilAdobeConnectServer::getPresentationUrl(); $this->tabs->activateTab("access"); $form = new ilPropertyFormGUI(); $form->setTitle($this->pluginObj->txt('access_meeting_title')); $this->object->doRead(); if ($this->object->getStartDate() != NULL) { $ilAdobeConnectUser = new ilAdobeConnectUserUtil($this->user->getId()); $ilAdobeConnectUser->ensureAccountExistance(); $xavc_login = $ilAdobeConnectUser->getXAVCLogin(); $quota = new ilAdobeConnectQuota(); // show link $link = new ilNonEditableValueGUI($this->pluginObj->txt("access_link")); if ($this->doProvideAccessLink() && $this->object->isParticipant($xavc_login)) { if (!$quota->mayStartScheduledMeeting($this->object->getScoId())) { $link->setValue($this->txt("meeting_not_available_no_slots")); } else { $link = new ilCustomInputGUI($this->pluginObj->txt("access_link")); $href = '<a href="' . $this->ctrl->getLinkTarget($this, 'performSso') . '" target="_blank" >' . $presentation_url . $this->object->getURL() . '</a>'; $link->setHtml($href); } } else { $link->setValue($this->txt("meeting_not_available")); } $form->addItem($link); $start_date = new ilNonEditableValueGUI($this->txt('start_date')); $start_date->setValue(ilDatePresentation::formatDate(new ilDateTime($this->object->getStartDate()->getUnixTime(), IL_CAL_UNIX))); $form->addItem($start_date); $duration = new ilNonEditableValueGUI($this->txt('duration')); $duration->setValue(ilDatePresentation::formatPeriod(new ilDateTime($this->object->getStartDate()->getUnixTime(), IL_CAL_UNIX), new ilDateTime($this->object->getEndDate()->getUnixTime(), IL_CAL_UNIX))); $form->addItem($duration); $this->tpl->setContent($form->getHTML()); } else { ilUtil::sendFailure($this->txt('error_connect_ac_server')); } }