Add project_path and login_destination_url

This commit is contained in:
FusionPBX 2023-05-10 23:08:57 -06:00 committed by GitHub
parent 5cac8f61e7
commit cb32d58f21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -28,6 +28,7 @@ class plugin_database {
//pre-process some settings
$settings['theme']['favicon'] = !empty($settings['theme']['favicon']) ? $settings['theme']['favicon'] : PROJECT_PATH.'/themes/default/favicon.ico';
$settings['login']['destination'] = !empty($settings['login']['destination']) ? $settings['login']['destination'] : '';
//already authorized
if (isset($_SESSION['authentication']['plugin']['database']) && $_SESSION['authentication']['plugin']['database']["authorized"]) {
@ -96,10 +97,13 @@ class plugin_database {
$view->assign("button_login", $text['button-login']);
//assign default values to the template
$view->assign("project_path", PROJECT_PATH);
$view->assign("login_destination_url", $settings['login']['destination']);
$view->assign("favicon", $settings['theme']['favicon']);
$view->assign("project_path", PROJECT_PATH);
$view->assign("login_logo_width", $login_logo_width);
$view->assign("login_logo_height", $login_logo_height);
$view->assign("login_logo_source", $login_logo_source);
$view->assign("favicon", $settings['theme']['favicon']);
//add the token name and hash to the view
//$view->assign("token_name", $token['name']);