settings.js 703 B

123456789101112131415161718192021222324
  1. /**
  2. * Copyright (c) 2011, Robin Appelman <icewind1991@gmail.com>
  3. * This file is licensed under the Affero General Public License version 3 or later.
  4. * See the COPYING-README file.
  5. */
  6. $(document).ready(function(){
  7. $('#encryption_blacklist').multiSelect({
  8. oncheck:blackListChange,
  9. onuncheck:blackListChange,
  10. createText:'...',
  11. });
  12. function blackListChange(){
  13. var blackList=$('#encryption_blacklist').val().join(',');
  14. OC.AppConfig.setValue('files_encryption','type_blacklist',blackList);
  15. }
  16. $('#enbale_encryption').change(function(){
  17. var checked=$('#enbale_encryption').is(':checked');
  18. OC.AppConfig.setValue('files_encryption','enable_encryption',(checked)?'true':'false');
  19. })
  20. })