-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathLV_SGPlugin.php
63 lines (46 loc) · 1.51 KB
/
LV_SGPlugin.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<?php
require 'bootstrap.php';
/**
* LV_SGPlugin.class.php
*
* ...
*
* @author Matthias Janssen
* @version 0.5
*/
class LV_SGPlugin extends StudIPPlugin implements SystemPlugin {
public function __construct() {
parent::__construct();
$this->build_menu();
}
private function build_menu () {
#PageLayout::disableHeader();
$plugin_title = 'LV-SG';
$navigation = new AutoNavigation(_($plugin_title));
$navigation->setURL(PluginEngine::GetURL($this, array(), 'main'));
if ($GLOBALS['perm']->have_perm('root')) {
$navigation->setImage($this->getPluginURL().'/assets/images/lv_sg.png');
}
Navigation::addItem('/lv_sgplugin', $navigation);
#-----
# $headline = 'Veranstaltungen f'.chr(252).'r das Studium Generale';
$headline
= 'Veranstaltungsverzeichnis f'.chr(252).'r Gasth'.chr(246).'rende';
$navigation = new AutoNavigation(_($headline));
$navigation->setURL(PluginEngine::GetURL($this, array(), 'main'));
Navigation::addItem('/lv_sgplugin/main', $navigation);
}
public function initialize () {
require_once 'bootstrap.php';
}
public function perform($unconsumed_path) {
$dispatcher = new Trails_Dispatcher(
$this->getPluginPath(),
rtrim(PluginEngine::getLink($this, array(), null), '/'),
'main'
);
$dispatcher->controller = $this;
$dispatcher->dispatch($unconsumed_path);
}
}
#?>