From efe1f83a7cc419df700dfe36ef11da20607d8eae Mon Sep 17 00:00:00 2001 From: MaZderMind Date: Sun, 8 Nov 2015 14:40:30 +0100 Subject: implement mandator handling, supporting different styles per mandantor --- model/Conferences.php | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 model/Conferences.php (limited to 'model/Conferences.php') diff --git a/model/Conferences.php b/model/Conferences.php new file mode 100644 index 0000000..05d3c52 --- /dev/null +++ b/model/Conferences.php @@ -0,0 +1,59 @@ +isClosed(); + unset($GLOBALS['CONFIG']); + + if(isset($saved_config)) + $GLOBALS['CONFIG'] = $saved_config; + + return $active; + } + + public static function hasCustomStyles($mandator) { + return file_exists(Conferences::getCustomStyles($mandator)); + } + public static function getCustomStyles($mandator) { + return forceslash(Conferences::getCustomStylesDir($mandator)).'main.less'; + } + public static function getCustomStylesDir($mandator) { + return forceslash(Conferences::MANDATOR_DIR).forceslash($mandator); + } + + public static function load($mandator) { + $GLOBALS['MANDATOR'] = $mandator; + include(forceslash(Conferences::MANDATOR_DIR).forceslash($mandator).'config.php'); + } +} -- cgit v1.2.3