diff options
Diffstat (limited to 'js/dojo-1.6/dojox/data/JsonQueryRestStore.js')
| -rw-r--r-- | js/dojo-1.6/dojox/data/JsonQueryRestStore.js | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/js/dojo-1.6/dojox/data/JsonQueryRestStore.js b/js/dojo-1.6/dojox/data/JsonQueryRestStore.js new file mode 100644 index 0000000..c4f96b0 --- /dev/null +++ b/js/dojo-1.6/dojox/data/JsonQueryRestStore.js @@ -0,0 +1,28 @@ +/*
+ Copyright (c) 2004-2011, The Dojo Foundation All Rights Reserved.
+ Available via Academic Free License >= 2.1 OR the modified BSD license.
+ see: http://dojotoolkit.org/license for details
+*/
+
+
+if(!dojo._hasResource["dojox.data.JsonQueryRestStore"]){ //_hasResource checks added by build. Do not use _hasResource directly in your code.
+dojo._hasResource["dojox.data.JsonQueryRestStore"] = true;
+dojo.provide("dojox.data.JsonQueryRestStore");
+dojo.require("dojox.data.JsonRestStore");
+dojo.require("dojox.data.util.JsonQuery");
+
+
+
+dojo.requireIf(!!dojox.data.ClientFilter,"dojox.json.query"); // this is so we can perform queries locally
+
+// this is an extension of JsonRestStore to convert object attribute queries to
+// JSONQuery/JSONPath syntax to be sent to the server. This also enables
+// JSONQuery/JSONPath queries to be performed locally if dojox.data.ClientFilter
+// has been loaded
+dojo.declare("dojox.data.JsonQueryRestStore",[dojox.data.JsonRestStore,dojox.data.util.JsonQuery],{
+ matchesQuery: function(item,request){
+ return item.__id && (item.__id.indexOf("#") == -1) && this.inherited(arguments);
+ }
+});
+
+}
|
