Last active
April 11, 2018 10:08
-
-
Save Opencontent/1baef60379a080872f0d068a2b93b8a9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var cleanFilterValue = function(values){ | |
if(!$.isArray(values)){ | |
values = [values]; | |
} | |
var data = $.map(values, function(str){ | |
str = $.trim(str); | |
str = str.replace(/'/g, "\\'"); | |
//str = str.replace("(","\\("); //solo ocopendata >= 2.13 interpreta l'escape delle parentesi | |
//str = str.replace(")","\\)"); //solo ocopendata >= 2.13 interpreta l'escape delle parentesi | |
return str; | |
}); | |
return data; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment