diff options
author | Thomas Müller <thomas.mueller@tmit.eu> | 2015-10-02 12:14:36 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2015-10-02 12:14:36 +0200 |
commit | 8944cb539ef565db4bb9f05d225449afa0d20cfb (patch) | |
tree | 7889215757fe4a0e250350c90f8bedaec6035960 /settings | |
parent | ccbdcf0ab33e943e6bac45a2ae3b602ed0593103 (diff) | |
parent | b2dd5cb61655b6ca82e8fd1fb117b42301d28c2b (diff) | |
download | nextcloud-server-8944cb539ef565db4bb9f05d225449afa0d20cfb.tar.gz nextcloud-server-8944cb539ef565db4bb9f05d225449afa0d20cfb.zip |
Merge pull request #19510 from owncloud/json-grouplist-sharing-exclude
save excluded groups in json format
Diffstat (limited to 'settings')
-rw-r--r-- | settings/admin.php | 2 | ||||
-rw-r--r-- | settings/js/admin.js | 6 |
2 files changed, 2 insertions, 6 deletions
diff --git a/settings/admin.php b/settings/admin.php index 31c9b8c1376..ec49b3e823f 100644 --- a/settings/admin.php +++ b/settings/admin.php @@ -87,7 +87,7 @@ $template->assign('shareEnforceExpireDate', $appConfig->getValue('core', 'sharea $excludeGroups = $appConfig->getValue('core', 'shareapi_exclude_groups', 'no') === 'yes' ? true : false; $template->assign('shareExcludeGroups', $excludeGroups); $excludedGroupsList = $appConfig->getValue('core', 'shareapi_exclude_groups_list', ''); -$excludedGroupsList = explode(',', $excludedGroupsList); // FIXME: this should be JSON! +$excludedGroupsList = json_decode($excludedGroupsList); $template->assign('shareExcludedGroupsList', implode('|', $excludedGroupsList)); $template->assign('encryptionEnabled', \OC::$server->getEncryptionManager()->isEnabled()); $backends = \OC::$server->getUserManager()->getBackends(); diff --git a/settings/js/admin.js b/settings/js/admin.js index 7117c7b46cf..9f7133c6571 100644 --- a/settings/js/admin.js +++ b/settings/js/admin.js @@ -23,11 +23,7 @@ $(document).ready(function(){ OC.Settings.setupGroupsSelect($(element)); $(element).change(function(ev) { var groups = ev.val || []; - if (groups.length > 0) { - groups = ev.val.join(','); // FIXME: make this JSON - } else { - groups = ''; - } + groups = JSON.stringify(groups); OC.AppConfig.setValue('core', $(this).attr('name'), groups); }); }); |