web/views/plots.py
changeset 5940 0e3ae19b181a
parent 5424 8ecbcbff9777
child 6582 8eb7883b4223
--- a/web/views/plots.py	Thu Jul 08 12:54:28 2010 +0200
+++ b/web/views/plots.py	Thu Jul 08 13:33:40 2010 +0200
@@ -23,10 +23,9 @@
 from logilab.common.date import datetime2ticks
 from logilab.mtconverter import xml_escape
 
-from cubicweb.utils import UStringIO
+from cubicweb.utils import UStringIO, json_dumps
 from cubicweb.appobject import objectify_selector
 from cubicweb.selectors import multi_columns_rset
-from cubicweb.web import dumps
 from cubicweb.web.views import baseviews
 
 @objectify_selector
@@ -107,7 +106,7 @@
         #     cf. function onPlotHover in cubicweb.flot.js
         if self.timemode:
             plot = [(datetime2ticks(x), y, datetime2ticks(x)) for x, y in plot]
-        return dumps(plot)
+        return json_dumps(plot)
 
     def _render(self, req, width=500, height=400):
         if req.ie_browser():