diff --git a/.gitignore b/.gitignore index de95987a8..8ebe61e25 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,8 @@ documents/ .project .buildpath application/config/development/ +application/config/testing/ +application/config/production application/extensions/ application/controllers/extensions/ application/config/extensions/ @@ -30,3 +32,4 @@ tests/codeception/tests/acceptance.suite.yml tests/codeception/tests/unit.suite.yml /sparks/* /webdav/google.php +system/sql/ diff --git a/application/config/roles.php b/application/config/roles.php index a95a94215..75a928db0 100644 --- a/application/config/roles.php +++ b/application/config/roles.php @@ -56,7 +56,7 @@ $config['roles'] = array 'basis/adresse','basis/akte','basis/kontakt','basis/log','basis/nation','basis/notiz','basis/notizzuordnung', 'basis/person','basis/prestudent','basis/prestudentstatus','basis/status','basis/zgv','basis/zgvmaster', 'lehre/studienplan','system/filters','fs/dms','basis/message','basis/benutzerrolle', 'basis/sprache', - 'system/personlock','basis/benutzerfunktion','system/vorlagestudiengang' + 'system/personlock','basis/benutzerfunktion','system/vorlagestudiengang', 'basis/bewerbungstermine' ) ) ); diff --git a/application/core/FHC_Controller.php b/application/core/FHC_Controller.php index f6f138441..815c03da2 100644 --- a/application/core/FHC_Controller.php +++ b/application/core/FHC_Controller.php @@ -4,6 +4,10 @@ if (! defined('BASEPATH')) exit('No direct script access allowed'); class FHC_Controller extends CI_Controller { + const FHC_CONTROLLER_ID = 'fhc_controller_id'; // name of the parameter used to identify uniquely a call to a controller + + private $_controllerId; // contains the unique identifier of a call to a controller + /** * Standard construct for all the controllers, loads the authentication system */ @@ -11,6 +15,8 @@ class FHC_Controller extends CI_Controller { parent::__construct(); + $this->_controllerId = null; // set _controllerId as null by default + $this->load->helper('fhcauth'); } @@ -23,4 +29,34 @@ class FHC_Controller extends CI_Controller { $this->load->library('PhrasesLib', array($categories, $language), 'p'); } + + /** + * Sets the unique id for the called controller + * NOTE: it is only working with HTTP GET request, not neeaded with POST + * because the first call to the controller is via HTTP GET, + * therefore a fhc_controller_id is already generated + */ + protected function setControllerId() + { + if ($_SERVER['REQUEST_METHOD'] === 'GET') + { + $this->_controllerId = $this->input->get(self::FHC_CONTROLLER_ID); + + if (!isset($this->_controllerId) || empty($this->_controllerId)) + { + $this->_controllerId = uniqid(); // generate a unique id + // Redirect to the same URL, but giving FHC_CONTROLLER_ID as HTTP GET parameter + header(sprintf('Location: %s?%s=%s', $_SERVER['REQUEST_URI'], self::FHC_CONTROLLER_ID, $this->_controllerId)); + exit; // terminate immediately the execution of this controller + } + } + } + + /** + * Return the value of the property _controllerId + */ + protected function getControllerId() + { + return $this->_controllerId; + } } diff --git a/application/libraries/DocumentLib.php b/application/libraries/DocumentLib.php index 204b1d30f..ed87a9f38 100644 --- a/application/libraries/DocumentLib.php +++ b/application/libraries/DocumentLib.php @@ -57,8 +57,19 @@ class DocumentLib case 'application/vnd.ms-word': case 'application/vnd.oasis.opendocument.text': case 'text/plain': - $this->convert($filename, $outFile, 'pdf'); - return success($outFile); + // Unoconv Version 0.6 seems to fail on converting TXT Files + if ($this->unoconv_version == '0.6') + return error(); + + $ret = $this->convert($filename, $outFile, 'pdf'); + if(isSuccess($ret)) + { + return success($outFile); + } + else + { + return error($ret->retval); + } case 'application/pdf': return success($filename); default: diff --git a/application/views/system/infocenter/infocenterData.php b/application/views/system/infocenter/infocenterData.php index 2d9d30cf2..8abc163b7 100755 --- a/application/views/system/infocenter/infocenterData.php +++ b/application/views/system/infocenter/infocenterData.php @@ -14,7 +14,7 @@ SELECT zeitpunkt FROM system.tbl_log WHERE taetigkeit_kurzbz IN(\'bewerbung\',\'kommunikation\') - AND logdata->>\'name\' NOT IN (\'Login with code\', \'New application\') + AND logdata->>\'name\' NOT IN (\'Login with code\', \'New application\', \'Interessent rejected\') AND person_id = p.person_id ORDER BY zeitpunkt DESC LIMIT 1 @@ -23,7 +23,7 @@ SELECT insertvon FROM system.tbl_log WHERE taetigkeit_kurzbz IN(\'bewerbung\',\'kommunikation\') - AND logdata->>\'name\' NOT IN (\'Login with code\', \'New application\') + AND logdata->>\'name\' NOT IN (\'Login with code\', \'New application\', \'Interessent rejected\') AND person_id = p.person_id ORDER BY zeitpunkt DESC LIMIT 1 diff --git a/application/views/templates/FHC-Header.php b/application/views/templates/FHC-Header.php index 52ed50dbd..853eb8de7 100755 --- a/application/views/templates/FHC-Header.php +++ b/application/views/templates/FHC-Header.php @@ -2,7 +2,7 @@ if (! defined('BASEPATH')) exit('No direct script access allowed'); -// Retrives the URL path of the called controller + controller method +// Retrives the URL path of the called controller + called controller method // NOTE: placed here because it doesn't work inside functions $calledPath = $this->router->directory.$this->router->class; $calledMethod = $this->router->method; @@ -15,6 +15,7 @@ $customJSs = isset($customJSs) ? $customJSs : null; // By default set the parameters to false $jquery = isset($jquery) ? $jquery : false; $jqueryui = isset($jqueryui) ? $jqueryui : false; +$ajaxlib = isset($ajaxlib) ? $ajaxlib : false; $bootstrap = isset($bootstrap) ? $bootstrap : false; $fontawesome = isset($fontawesome) ? $fontawesome : false; $tablesorter = isset($tablesorter) ? $tablesorter : false; @@ -141,12 +142,15 @@ function _generateAddonsJSsInclude($calledFrom) // jQuery UI CSS if ($jqueryui === true) _generateCSSsInclude('vendor/components/jqueryui/themes/base/jquery-ui.min.css'); - // bootstrap CSS + // Bootstrap CSS if ($bootstrap === true) _generateCSSsInclude('vendor/twbs/bootstrap/dist/css/bootstrap.min.css'); - // font awesome CSS + // Font Awesome CSS if ($fontawesome === true) _generateCSSsInclude('vendor/components/font-awesome/css/font-awesome.min.css'); + // AjaxLib CSS + if ($ajaxlib === true) _generateCSSsInclude('public/css/AjaxLib.css'); + // Table sorter CSS if ($tablesorter === true) { @@ -154,7 +158,7 @@ function _generateAddonsJSsInclude($calledFrom) _generateCSSsInclude('vendor/mottie/tablesorter/dist/css/jquery.tablesorter.pager.min.css'); } - // sb admin template CSS + // SB Admin 2 template CSS if ($sbadmintemplate === true) { _generateCSSsInclude('vendor/BlackrockDigital/startbootstrap-sb-admin-2/vendor/metisMenu/metisMenu.min.css'); @@ -164,10 +168,11 @@ function _generateAddonsJSsInclude($calledFrom) // Eventually required CSS _generateCSSsInclude($customCSSs); // Eventually required CSS + // -------------------------------------------------------------------------------------------------------- // Javascripts - // Generates the global object to pass useful parms to the other javascripts + // Generates the global object to pass useful parameters to other javascripts // NOTE: must be called before any other JS include _generateJSDataStorageObject($calledPath, $calledMethod); @@ -178,11 +183,13 @@ function _generateAddonsJSsInclude($calledFrom) if ($jqueryui === true) { _generateJSsInclude('vendor/components/jqueryui/jquery-ui.min.js'); - //datepicker german language file - _generateJSsInclude('vendor/components/jqueryui/ui/i18n/datepicker-de.js'); + _generateJSsInclude('vendor/components/jqueryui/ui/i18n/datepicker-de.js'); // datepicker german language file } - // bootstrap JS + // AjaxLib JS + if ($ajaxlib === true) _generateJSsInclude('public/js/AjaxLib.js'); + + // Bootstrap JS if ($bootstrap === true) _generateJSsInclude('vendor/twbs/bootstrap/dist/js/bootstrap.min.js'); // Table sorter JS @@ -193,10 +200,10 @@ function _generateAddonsJSsInclude($calledFrom) _generateJSsInclude('vendor/mottie/tablesorter/dist/js/extras/jquery.tablesorter.pager.min.js'); } - //tinymce JS + // Tinymce JS if($tinymce === true) _generateJSsInclude('vendor/tinymce/tinymce/tinymce.min.js') ; - // sb admin template JS + // SB Admin 2 template JS if ($sbadmintemplate === true) { _generateJSsInclude('vendor/BlackrockDigital/startbootstrap-sb-admin-2/vendor/metisMenu/metisMenu.min.js'); diff --git a/content/student/studentenoverlay.xul.php b/content/student/studentenoverlay.xul.php index 8f311784d..a9de22360 100644 --- a/content/student/studentenoverlay.xul.php +++ b/content/student/studentenoverlay.xul.php @@ -288,10 +288,6 @@ else class="sortDirectionIndicator" sort="rdf:http://www.technikum-wien.at/student/rdf#matrikelnummer" onclick="StudentTreeSort()"/> -