/**
  * Getter for registration link
  */
 public function getRegisterLink()
 {
     $o = $this->owner;
     //$link = $o->getInternalLink() . "/register";
     //return $link;
     $detailStr = 'register/' . $o->ID;
     $calendarPage = CalendarPage::get()->First();
     return $calendarPage->Link() . $detailStr;
 }
 /**
  * Getter for internal event link
  * NOTE: The current implementation only works properly as long as there's only one
  * {@see CalendarPage} in the site
  */
 public function getInternalLink()
 {
     $detailStr = 'detail/' . $this->ID;
     //for now all event details will only have one link - that is the main calendar page
     //NOTE: this could be amended by calling that link via AJAX, and thus could be shown as an overlay
     //everywhere on the site
     //		//if the event page is enabled, we provide for links to event pages
     //		if (CalendarConfig::subpackage_setting('pagetypes','enable_eventpage')) {
     //			$eventPage = $this->EventPage();
     //			if ($eventPage->exists()) {
     //				return $eventPage->Link();
     //			} else {
     //				$calendarPage = CalendarPage::get()->First();
     //				return $calendarPage->Link() .  $detailStr;
     //			}
     //		} else {
     $calendarPage = CalendarPage::get()->First();
     return $calendarPage->Link() . $detailStr;
     //		}
 }
Example #3
0
<?php

/**
Copyright 2011-2014 Nick Korbel

This file is part of Booked Scheduler.

Booked Scheduler is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Booked Scheduler is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Booked Scheduler.  If not, see <http://www.gnu.org/licenses/>.
*/
define('ROOT_DIR', '../');
require_once ROOT_DIR . 'Pages/CalendarPage.php';
$page = new CalendarPage();
$page->PageLoad();
Example #4
0
                 $oblocks++;
             }
             break;
         case "tab_wiki":
             $wikilist = $wikipage->getLinks_Home();
             if ($allow_wiki && ($access_isGroupMember || $open_wiki) && !empty($wikilist)) {
                 if ($oblocks % 2 == 1) {
                     $pg->addBlock($pg->RightColumn, $treng->_('Wiki', "modulewiki"), $wikilist, $treng->_('Wiki', "modulewiki"), false, false, false, false, $op);
                 } else {
                     $pg->addBlock($pg->LeftColumn, $treng->_('Wiki', "modulewiki"), $wikilist, $treng->_('Wiki', "modulewiki"), false, false, false, false, $op);
                 }
                 $oblocks++;
             }
             break;
         case "tab_calendar":
             $cal = new CalendarPage($group_name);
             if ($allow_calendar) {
                 if ($oblocks % 2 == 1) {
                     $pg->addBlock($pg->RightColumn, $treng->_('Calendar', "modulewcalendar"), $cal->getHomeBlock(), "", false, false, false, false, $op);
                 } else {
                     $pg->addBlock($pg->LeftColumn, $treng->_('Calendar', "modulecalendar"), $cal->getHomeBlock(), "", false, false, false, false, $op);
                 }
                 $oblocks++;
             }
             break;
     }
 }
 // We only have About Us block
 // make it wider
 if ($oblocks == 1) {
     $pg->removeLastBlock();
Example #5
0
 public function Level($num)
 {
     return CalendarPage::get_one('CalendarPage');
 }
 function getPermalink()
 {
     return CalendarPage::get()->byID($this->CalendarPageID)->AbsoluteLink('show/' . $this->ID);
 }
Example #7
0
 public function CalendarPage()
 {
     return CalendarPage::get_one('CalendarPage');
 }