format time for comments with python strftime(). no time localization so far.
svn path=/plone.app.discussion/trunk/; revision=27231
This commit is contained in:
parent
0ce270bc66
commit
0d6045682f
@ -74,7 +74,10 @@ class CommentsViewlet(ViewletBase):
|
||||
return '%s/login_form?came_from=%s' % (self.navigation_root_url, url_quote(self.request.get('URL', '')),)
|
||||
|
||||
def format_time(self, time):
|
||||
return self.context.restrictedTraverse('@@plone').toLocalizedTime(time, long_format=True)
|
||||
# Todo: return localized time
|
||||
return time.strftime("%a, %d %b %Y %H:%M")
|
||||
# XXX: Not working, returns None !!!
|
||||
#return self.context.restrictedTraverse('@@plone').toLocalizedTime(time, long_format=True)
|
||||
|
||||
class AddComment(BrowserView):
|
||||
"""Add a comment to a conversation
|
||||
|
Loading…
Reference in New Issue
Block a user