web/views/plots.py
changeset 2009 b1e2b9e4c809
parent 1991 8a9d8f1ee100
child 2161 200481e7b156
--- a/web/views/plots.py	Fri May 29 19:31:32 2009 +0200
+++ b/web/views/plots.py	Fri May 29 19:34:00 2009 +0200
@@ -15,7 +15,7 @@
 from logilab.common import flatten
 from logilab.mtconverter import html_escape
 
-from cubicweb.utils import make_uid, UStringIO
+from cubicweb.utils import make_uid, UStringIO, datetime2ticks
 from cubicweb.vregistry import objectify_selector
 from cubicweb.web.views import baseviews
 
@@ -60,9 +60,6 @@
         filtered.append( (x, y) )
     return sorted(filtered)
 
-def datetime2ticks(date):
-    return time.mktime(date.timetuple()) * 1000
-
 class PlotWidget(object):
     # XXX refactor with cubicweb.web.views.htmlwidgets.HtmlWidget
     def _initialize_stream(self, w=None):