]> source.dussan.org Git - nextcloud-server.git/commitdiff
make footer and urls aware of ownCloud editions
authorBjörn Schießle <schiessle@owncloud.com>
Wed, 12 Jun 2013 13:44:11 +0000 (15:44 +0200)
committerBjörn Schießle <schiessle@owncloud.com>
Thu, 13 Jun 2013 14:37:14 +0000 (16:37 +0200)
lib/defaults.php
settings/personal.php
settings/templates/admin.php
settings/templates/personal.php

index 59f8d976fe95e5761bcbe4c8e2281d8738ea3a73..a43269dd67e293fde6de0e89867b3fdc584c68f0 100644 (file)
@@ -5,11 +5,13 @@ class OC_Defaults {
        private static $communityEntity = "ownCloud";
        private static $communityName = "ownCloud";
        private static $communityBaseUrl = "http://owncloud.org";
+       private static $communitySyncClientUrl = " http://owncloud.org/sync-clients/";
        private static $communitySlogan = "web services under your control";
 
        private static $enterpriseEntity = "ownCloud Inc.";
        private static $enterpriseName = "ownCloud Enterprise Edition";
        private static $enterpriseBaseUrl = "https://owncloud.com";
+       private static $enterpiseSyncClientUrl = "https://owncloud.com/products/desktop-clients";
        private static $enterpriseSlogan = "Your Cloud, Your Data, Your Way!";
 
 
@@ -21,6 +23,14 @@ class OC_Defaults {
                }
        }
 
+       public static function getSyncClientUrl() {
+               if (OC_Util::getEditionString() === '') {
+                       return self::$communitySyncClientUrl;
+               } else {
+                       return self::$enterpiseSyncClientUrl;
+               }
+       }
+
        public static function getName() {
                if (OC_Util::getEditionString() === '') {
                        return self::$communityName;
index 9bbc66c9b7fcf644f61713b9cfa596a84b701ff4..d6c84b5bbc3fdbeb6ab7f31af9d86105a39536f1 100644 (file)
@@ -51,7 +51,7 @@ array_unshift($languages, $userLang);
 
 //links to clients
 $clients = array(
-       'desktop' => OC_Config::getValue('customclient_desktop', 'http://owncloud.org/sync-clients/'),
+       'desktop' => OC_Config::getValue('customclient_desktop', OC_Defaults::getSyncClientUrl()),
        'android' => OC_Config::getValue('customclient_android', 'https://play.google.com/store/apps/details?id=com.owncloud.android'),
        'ios'     => OC_Config::getValue('customclient_ios', 'https://itunes.apple.com/us/app/owncloud/id543672169?mt=8')
 );
index 992d75e481fb9b6015882d8c49d27945760713f1..0aba0c746a2bcdbfc8a78f8e729a52c5cae605d8 100644 (file)
@@ -225,11 +225,16 @@ endfor;?>
 
 </fieldset>
 
-
+<?php if (OC_Util::getEditionString() === ''): ?>
 <fieldset class="personalblock">
        <legend><strong><?php p($l->t('Version'));?></strong></legend>
        <strong>ownCloud</strong> <?php p(OC_Util::getVersionString()); ?> <?php p(OC_Util::getEditionString()); ?>
        (<?php print_unescaped(OC_Updater::ShowUpdatingHint()); ?>)<br/>
        <?php print_unescaped($l->t('Developed by the <a href="http://ownCloud.org/contact" target="_blank">ownCloud community</a>, the <a href="https://github.com/owncloud" target="_blank">source code</a> is licensed under the <a href="http://www.gnu.org/licenses/agpl-3.0.html" target="_blank"><abbr title="Affero General Public License">AGPL</abbr></a>.')); ?>
 </fieldset>
+<?php else: ?>
+<fieldset class="personalblock credits-footer">
+    <p>© 2013 <a href="<?php p(OC_Defaults::getBaseUrl()); ?>" target="_blank"><?php p(OC_Defaults::getEntity()); ?></a> – <?php p(OC_Defaults::getSlogan()); ?></p>
+</fieldset>
+<?php endif; ?>
 
index 4a046973307f5227e19a254a5de0ee5e4d87b338..161a482b9152115967a90f5c5fe3cab6e0e528dc 100644 (file)
@@ -106,12 +106,15 @@ if($_['passwordChangeSupported']) {
        print_unescaped($form);
 };?>
 
-
+<?php if (OC_Util::getEditionString() === ''): ?>
 <fieldset class="personalblock">
        <legend><strong><?php p($l->t('Version'));?></strong></legend>
        <strong>ownCloud</strong> <?php p(OC_Util::getVersionString()); ?>
        <?php p(OC_Util::getEditionString()); ?> <br />
        <?php print_unescaped($l->t('Developed by the <a href="http://ownCloud.org/contact" target="_blank">ownCloud community</a>, the <a href="https://github.com/owncloud" target="_blank">source code</a> is licensed under the <a href="http://www.gnu.org/licenses/agpl-3.0.html" target="_blank"><abbr title="Affero General Public License">AGPL</abbr></a>.')); ?>
 </fieldset>
-
-
+<?php else: ?>
+<fieldset class="personalblock credits-footer">
+    <p>© 2013 <a href="<?php p(OC_Defaults::getBaseUrl()); ?>" target="_blank"><?php p(OC_Defaults::getEntity()); ?></a> – <?php p(OC_Defaults::getSlogan()); ?></p>
+</fieldset>
+<?php endif; ?>