]> source.dussan.org Git - nextcloud-server.git/commitdiff
feature endorse password for share links
authorTimo Benk <benk@b1-systems.de>
Fri, 14 Oct 2016 07:58:24 +0000 (09:58 +0200)
committerBjoern Schiessle <bjoern@schiessle.org>
Mon, 3 Apr 2017 08:58:03 +0000 (10:58 +0200)
works like "enforce password protection", but let the
user optionally remove the password protection after the
password is set.

Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
core/js/shareconfigmodel.js
core/js/sharedialoglinkshareview.js

index 98388cbd508cf6cf4e3c3ec807e3ed86b5e878f3..f16d3d7b148740d815f281d99d268fe6ea27b5d8 100644 (file)
@@ -22,6 +22,7 @@
                defaults: {
                        publicUploadEnabled: false,
                        enforcePasswordForPublicLink: oc_appconfig.core.enforcePasswordForPublicLink,
+                       endorsePasswordForPublicLink: oc_appconfig.core.endorsePasswordForPublicLink,
                        isDefaultExpireDateEnforced: oc_appconfig.core.defaultExpireDateEnforced === true,
                        isDefaultExpireDateEnabled: oc_appconfig.core.defaultExpireDateEnabled === true,
                        isRemoteShareAllowed: oc_appconfig.core.remoteShareAllowed,
index d881b85f70f92e017a1f4c91614b7980ba485685..942d392f081d13173c51966bd4b9a6c9dedb9c8d 100644 (file)
                        }
 
                        if($checkBox.is(':checked')) {
-                               if(this.configModel.get('enforcePasswordForPublicLink') === false) {
+                               if(this.configModel.get('enforcePasswordForPublicLink') === false && this.configModel.get('endorsePasswordForPublicLink') === false) {
                                        $loading.removeClass('hidden');
                                        // this will create it
                                        this.model.saveLinkShare();