summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVolkan Gezer <volkangezer@gmail.com>2014-05-29 21:09:56 +0200
committerVolkan Gezer <volkangezer@gmail.com>2014-05-29 21:14:20 +0200
commitc01f196f723dcb3dea6947c821a70d4d80563bbd (patch)
tree49da7f93adadc73659d7e4dc1e6a08f06180675b
parent32a50563d3a93c304d7879212f349e6930d5b5d6 (diff)
downloadnextcloud-server-c01f196f723dcb3dea6947c821a70d4d80563bbd.tar.gz
nextcloud-server-c01f196f723dcb3dea6947c821a70d4d80563bbd.zip
make reshare settings foldable
-rw-r--r--settings/js/admin.js3
-rw-r--r--settings/templates/admin.php18
2 files changed, 11 insertions, 10 deletions
diff --git a/settings/js/admin.js b/settings/js/admin.js
index 249131464a8..9353333b47e 100644
--- a/settings/js/admin.js
+++ b/settings/js/admin.js
@@ -83,6 +83,9 @@ $(document).ready(function(){
$('#allowLinks').change(function() {
$("#publicLinkSettings").toggleClass('hidden', !this.checked);
});
+ $('#allowResharing').change(function() {
+ $("#resharingSettings").toggleClass('hidden', !this.checked);
+ });
$('#security').change(function(){
$.post(OC.filePath('settings','ajax','setsecurity.php'), { enforceHTTPS: $('#forcessl').val() },function(){} );
diff --git a/settings/templates/admin.php b/settings/templates/admin.php
index 9b632391f88..a410447551e 100644
--- a/settings/templates/admin.php
+++ b/settings/templates/admin.php
@@ -248,16 +248,14 @@ if (!$_['internetconnectionworking']) {
value="1" <?php if ($_['allowResharing'] === 'yes') print_unescaped('checked="checked"'); ?> />
<label for="allowResharing"><?php p($l->t('Allow resharing'));?></label><br/>
<em><?php p($l->t('Allow users to share items shared with them again')); ?></em>
- </td>
- </tr>
- <tr>
- <td <?php if ($_['shareAPIEnabled'] === 'no') print_unescaped('class="hidden"');?>>
- <input type="radio" name="shareapi_share_policy" id="sharePolicyGlobal"
- value="global" <?php if ($_['sharePolicy'] === 'global') print_unescaped('checked="checked"'); ?> />
- <label for="sharePolicyGlobal"><?php p($l->t('Allow users to share with anyone')); ?></label><br/>
- <input type="radio" name="shareapi_share_policy" id="sharePolicyGroupsOnly"
- value="groups_only" <?php if ($_['sharePolicy'] === 'groups_only') print_unescaped('checked="checked"'); ?> />
- <label for="sharePolicyGroupsOnly"><?php p($l->t('Allow users to only share with users in their groups'));?></label><br/>
+ <div id="resharingSettings" <?php ($_['allowResharing'] === 'yes') ? print_unescaped('class="indent"') : print_unescaped('class="hidden indent"');?>>
+ <input type="radio" name="shareapi_share_policy" id="sharePolicyGlobal"
+ value="global" <?php if ($_['sharePolicy'] === 'global') print_unescaped('checked="checked"'); ?> />
+ <label for="sharePolicyGlobal"><?php p($l->t('Allow users to share with anyone')); ?></label><br/>
+ <input type="radio" name="shareapi_share_policy" id="sharePolicyGroupsOnly"
+ value="groups_only" <?php if ($_['sharePolicy'] === 'groups_only') print_unescaped('checked="checked"'); ?> />
+ <label for="sharePolicyGroupsOnly"><?php p($l->t('Allow users to only share with users in their groups'));?></label><br/>
+ </div>
</td>
</tr>
<tr>