web/views/basecontrollers.py
branchtls-sprint
changeset 1016 26387b836099
parent 945 912b604f0e42
child 1092 b8fbb95dc0eb
--- a/web/views/basecontrollers.py	Mon Mar 09 12:12:53 2009 +0100
+++ b/web/views/basecontrollers.py	Tue Mar 10 11:35:52 2009 +0100
@@ -13,11 +13,10 @@
 
 import simplejson
 
-from mx.DateTime.Parser import DateFromString
-
 from logilab.common.decorators import cached
 
 from cubicweb import NoSelectableObject, ValidationError, ObjectNotFound, typed_eid
+from cubicweb.utils import strptime
 from cubicweb.selectors import yes, match_user_groups
 from cubicweb.view import STRICT_DOCTYPE, CW_XHTML_EXTENSIONS
 from cubicweb.common.mail import format_mail
@@ -390,7 +389,7 @@
 
     def js_format_date(self, strdate):
         """returns the formatted date for `msgid`"""
-        date = DateFromString(strdate)
+        date = strptime(strdate)
         return self.format_date(date)
 
     def js_external_resource(self, resource):