exclude.js 642 B

12345678910111213141516171819202122232425262728293031
  1. /*
  2. Exclude.js
  3. Handle read write of the excluded dirs function
  4. Excluded dirs shd be start with base folder name, for example
  5. for excluding user:/Photo/Manga/, just enter Manga
  6. Required paramters:
  7. set
  8. folders (Required when set=true)
  9. */
  10. includes("imagedb.js");
  11. function GetExcludeFolders(){
  12. return getExcludeFolders();
  13. }
  14. function SetExcludeFolders(folders){
  15. setExcludeFolders(folders);
  16. sendJSONResp(JSON.stringify("OK"));
  17. }
  18. if (typeof(set) == "undefined"){
  19. //Get
  20. var excludeFolders = GetExcludeFolders();
  21. sendJSONResp(excludeFolders);
  22. }else{
  23. //Set
  24. SetExcludeFolders(folders);
  25. }