diff options
author | Robin McCorkell <rmccorkell@owncloud.com> | 2015-08-28 15:52:29 +0100 |
---|---|---|
committer | Robin McCorkell <rmccorkell@owncloud.com> | 2015-08-28 17:21:58 +0100 |
commit | cc88c5f4b84da57c425cbdb7dc8b391b1942b503 (patch) | |
tree | 2a55a4138f7adfd49eefd9277e9f8ba17f747857 /apps/files_external/templates | |
parent | 080fafe63a980f6a485027fd4216864adf764e1e (diff) | |
download | nextcloud-server-cc88c5f4b84da57c425cbdb7dc8b391b1942b503.tar.gz nextcloud-server-cc88c5f4b84da57c425cbdb7dc8b391b1942b503.zip |
Implement more fine-grained external storage permissions model
VisibilityTrait -> PermissionsTrait
PermissionsTrait stores two sets of data, $permissions and
$allowedPermissions (analogous to $visibility and $allowedVisibility of
VisibilityTrait). Each set is a map of user type ('admin' or 'personal')
to permissions (mounting permission, create permission).
The result is that a backend can now be restricted for creation, while
still allowing it to be mounted. This is useful for deprecating backends
or auth mechanisms, preventing new storages being created, while still
allowing existing storages to be mounted.
Diffstat (limited to 'apps/files_external/templates')
-rw-r--r-- | apps/files_external/templates/settings.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_external/templates/settings.php b/apps/files_external/templates/settings.php index 5b79edf6cf7..63a3a19de2f 100644 --- a/apps/files_external/templates/settings.php +++ b/apps/files_external/templates/settings.php @@ -197,7 +197,7 @@ <p id="userMountingBackends"<?php if ($_['allowUserMounting'] != 'yes'): ?> class="hidden"<?php endif; ?>> <?php p($l->t('Allow users to mount the following external storage')); ?><br /> <?php $i = 0; foreach ($_['userBackends'] as $backend): ?> - <input type="checkbox" id="allowUserMountingBackends<?php p($i); ?>" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isVisibleFor(BackendService::VISIBILITY_PERSONAL)) print_unescaped(' checked="checked"'); ?> /> + <input type="checkbox" id="allowUserMountingBackends<?php p($i); ?>" name="allowUserMountingBackends[]" value="<?php p($backend->getIdentifier()); ?>" <?php if ($backend->isPermitted(BackendService::USER_PERSONAL, BackendService::PERMISSION_MOUNT)) print_unescaped(' checked="checked"'); ?> /> <label for="allowUserMountingBackends<?php p($i); ?>"><?php p($backend->getText()); ?></label> <br /> <?php $i++; ?> <?php endforeach; ?> |