From 01dee35ebe1f3ab0e8a7f986015a9fa43a80b061 Mon Sep 17 00:00:00 2001 From: Guillaume AMAT Date: Thu, 13 Feb 2014 10:47:03 +0100 Subject: [PATCH] Adds OC_Defaults values in javascript config --- core/js/config.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/core/js/config.php b/core/js/config.php index 517ea1615a..7ec0904ec3 100644 --- a/core/js/config.php +++ b/core/js/config.php @@ -16,6 +16,9 @@ header("Expires: Sat, 26 Jul 1997 05:00:00 GMT"); // Enable l10n support $l = OC_L10N::get('core'); +// Enable OC_Defaults support +$defaults = new OC_Defaults(); + // Get the config $apps_paths = array(); foreach(OC_App::getEnabledApps() as $app) { @@ -60,6 +63,20 @@ $array = array( 'session_lifetime' => \OCP\Config::getSystemValue('session_lifetime', 60 * 60 * 24), 'session_keepalive' => \OCP\Config::getSystemValue('session_keepalive', true) ) + ), + "oc_defaults" => json_encode( + array( + 'entity' => $defaults->getEntity(), + 'name' => $defaults->getName(), + 'title' => $defaults->getTitle(), + 'baseUrl' => $defaults->getBaseUrl(), + 'syncClientUrl' => $defaults->getSyncClientUrl(), + 'docBaseUrl' => $defaults->getDocBaseUrl(), + 'slogan' => $defaults->getSlogan(), + 'logoClaim' => $defaults->getLogoClaim(), + 'shortFooter' => $defaults->getShortFooter(), + 'longFooter' => $defaults->getLongFooter() + ) ) );