[Mpuls-commits] r3144 - in base/trunk: . mpulsweb/templates/casemanagement
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Tue Jul 6 13:16:41 CEST 2010
Author: bh
Date: 2010-07-06 13:16:40 +0200 (Tue, 06 Jul 2010)
New Revision: 3144
Modified:
base/trunk/ChangeLog
base/trunk/mpulsweb/templates/casemanagement/caselist.mako
Log:
* mpulsweb/templates/casemanagement/caselist.mako (fields): Format
the values using the new format_object function. This makes sure
that shorten is always called with a string and that date objects
are formatted properly.
Modified: base/trunk/ChangeLog
===================================================================
--- base/trunk/ChangeLog 2010-07-06 11:15:00 UTC (rev 3143)
+++ base/trunk/ChangeLog 2010-07-06 11:16:40 UTC (rev 3144)
@@ -1,5 +1,12 @@
2010-07-06 Bernhard Herzog <bh at intevation.de>
+ * mpulsweb/templates/casemanagement/caselist.mako (fields): Format
+ the values using the new format_object function. This makes sure
+ that shorten is always called with a string and that date objects
+ are formatted properly.
+
+2010-07-06 Bernhard Herzog <bh at intevation.de>
+
* mpulsweb/lib/helpers.py (format_object): New. Generic object
formatter for use in templates where the type of the object to
render is may vary.
Modified: base/trunk/mpulsweb/templates/casemanagement/caselist.mako
===================================================================
--- base/trunk/mpulsweb/templates/casemanagement/caselist.mako 2010-07-06 11:15:00 UTC (rev 3143)
+++ base/trunk/mpulsweb/templates/casemanagement/caselist.mako 2010-07-06 11:16:40 UTC (rev 3144)
@@ -25,7 +25,7 @@
fs = d.overview_style
print f
field = (fn,f,fs, all_roles,
- lambda case, f=f: h.shorten(case.get_value(f), 15))
+ lambda case, f=f: h.shorten(h.format_object(case.get_value(f)), 15))
fields.append(field)
# Extend fields with default fields in overview
More information about the Mpuls-commits
mailing list