예제 #1
0
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->auth();
     if (!$this->user->isAdmin()) {
         throw new Exception('You do not have access to this page.');
     }
     $this->template = new SimpleSAML_XHTML_Template($this->config, 'accountmapping-prepare.php', 'foodle_foodle');
     $this->prepare();
     $limit = TRUE;
     if (!empty($_REQUEST['showall'])) {
         $limit = FALSE;
     }
     $realmFrom = 'hio.no';
     if (!empty($_REQUEST['realmFrom'])) {
         $realmFrom = $_REQUEST['realmFrom'];
     }
     $realmTo = 'hioa.no';
     if (!empty($_REQUEST['realmTo'])) {
         $realmTo = $_REQUEST['realmTo'];
     }
     $this->template->data['realmFrom'] = $realmFrom;
     $this->template->data['realmTo'] = $realmTo;
     $this->allusers = $this->fdb->searchUsersRealm($realmFrom);
     foreach ($this->allusers as $k => $u) {
         $this->allusers[$k]['stats'] = $this->fdb->getUserStats($u['userid']);
     }
 }
예제 #2
0
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->template = new SimpleSAML_XHTML_Template($this->config, 'attributecheck.php', 'foodle_foodle');
     $this->setLocale();
     $this->auth();
     $this->timezone = new TimeZone($this->fdb, null, $this->user);
 }
예제 #3
0
파일: Debug.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     if (count($parameters) < 1) {
         throw new Exception('Missing [foodleid] parameter in URL.');
     }
     Data_Foodle::requireValidIdentifier($parameters[0]);
     $this->foodleid = $parameters[0];
     $this->foodlepath = '/foodle/' . $this->foodleid;
     $this->foodle = $this->fdb->readFoodle($this->foodleid);
 }
예제 #4
0
파일: PageUser.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->template = new SimpleSAML_XHTML_Template($this->config, 'user.php', 'foodle_foodle');
     //$this->setLocale();
     $this->auth();
     if (count($parameters) !== 1) {
         throw new Exception('Wrong number of parameters to User Profile page. You should never be sent to this URL.');
     }
     $this->showuser = $this->fdb->readUser($parameters[0]);
     if (empty($this->showuser)) {
         throw new Exception('Could not find user with ID ' . $parameters[0]);
     }
     $this->timezone = new TimeZone($this->fdb, null, $this->showuser);
     $this->checkToken();
 }
예제 #5
0
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->template = new SimpleSAML_XHTML_Template($this->config, 'accountmapping.php', 'foodle_foodle');
     $this->auth();
     #		$this->timezone = new TimeZone(null, $this->user);
     if (!$this->user->isAdmin()) {
         throw new Exception('You do not have access to this page.');
     }
     $this->prepare();
     $limit = TRUE;
     if (!empty($_REQUEST['showall'])) {
         $limit = FALSE;
     }
     $this->allusers = $this->fdb->getAllUsers($limit);
     // foreach($this->allusers AS $k => $u) {
     // 	$this->allusers[$k]['stats'] = $this->fdb->getUserStats($u['userid']);
     // }
 }
예제 #6
0
파일: PageFoodle.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     if (count($parameters) < 1) {
         throw new Exception('Missing [foodleid] parameter in URL.');
     }
     $this->template = new SimpleSAML_XHTML_Template($this->config, 'foodleresponse.php', 'foodle_foodle');
     $this->setLocale();
     Data_Foodle::requireValidIdentifier($parameters[0]);
     $this->foodleid = $parameters[0];
     $this->foodlepath = '/foodle/' . $this->foodleid;
     #Timer::tick('Preparation started');
     $this->foodle = $this->fdb->readFoodle($this->foodleid);
     #Timer::tick('Foodle read');
     // $this->foodle->getColumnDates();
     // $this->calendarEnabled = $this->foodle->calendarEnabled();
     // $this->timezoneEnable = $this->foodle->timeZoneEnabled();
     // $this->datesonly = $this->foodle->datesOnly();
     #Timer::tick('Timezone preparations');
     $this->auth();
 }
예제 #7
0
파일: PageCreate.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->auth();
     $this->timezone = new TimeZone($this->fdb, NULL, $this->user);
 }
예제 #8
0
파일: PageDisco.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
 }
예제 #9
0
파일: Login.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     // error_log('Foodle /login ');
     $this->auth();
 }
예제 #10
0
파일: PageSupport.php 프로젝트: r4mp/Foodle
 function __construct($config, $parameters)
 {
     parent::__construct($config, $parameters);
     $this->auth();
 }