web/views/json.py
branchstable
changeset 8629 3ae893f9ec84
parent 8601 1a6000ff2080
child 8651 353bbd17a8b6
--- a/web/views/json.py	Thu Dec 20 12:14:14 2012 +0100
+++ b/web/views/json.py	Thu Dec 20 12:15:57 2012 +0100
@@ -23,6 +23,7 @@
 _ = unicode
 
 from cubicweb.utils import json_dumps
+from cubicweb.predicates import any_rset
 from cubicweb.view import EntityView, AnyRsetView
 from cubicweb.web.application import anonymized_request
 from cubicweb.web.views import basecontrollers
@@ -90,6 +91,7 @@
 class JsonRsetView(JsonMixIn, AnyRsetView):
     """dumps raw result set in JSON format"""
     __regid__ = 'jsonexport'
+    __select__ = any_rset() # means rset might be empty or have any shape
     title = _('json-export-view')
 
     def call(self):