summaryrefslogtreecommitdiff
path: root/share/www/script
diff options
context:
space:
mode:
Diffstat (limited to 'share/www/script')
-rw-r--r--share/www/script/jquery.couch.js15
1 files changed, 13 insertions, 2 deletions
diff --git a/share/www/script/jquery.couch.js b/share/www/script/jquery.couch.js
index 4c42211c..4923dafe 100644
--- a/share/www/script/jquery.couch.js
+++ b/share/www/script/jquery.couch.js
@@ -231,8 +231,19 @@
);
},
allDocs: function(options) {
- ajax(
- {url: this.uri + "_all_docs" + encodeOptions(options)},
+ var type = "GET";
+ var data = null;
+ if (options["keys"]) {
+ type = "POST";
+ var keys = options["keys"];
+ delete options["keys"];
+ data = toJSON({ "keys": keys });
+ }
+ ajax({
+ type: type,
+ data: data,
+ url: this.uri + "_all_docs" + encodeOptions(options)
+ },
options,
"An error occurred retrieving a list of all documents"
);