[Mpuls-commits] r4548 - base/trunk/mpulsweb/lib

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Tue Feb 1 12:17:24 CET 2011


Author: torsten
Date: 2011-02-01 12:17:24 +0100 (Tue, 01 Feb 2011)
New Revision: 4548

Modified:
   base/trunk/mpulsweb/lib/renderer.py
Log:
* mpulsweb/lib/renderer.py
	(ViewRenderer._renderNumeric.uformat_numeric): Issue1712: Fixed
	handling of numeric values if the are None


Modified: base/trunk/mpulsweb/lib/renderer.py
===================================================================
--- base/trunk/mpulsweb/lib/renderer.py	2011-02-01 09:14:32 UTC (rev 4547)
+++ base/trunk/mpulsweb/lib/renderer.py	2011-02-01 11:17:24 UTC (rev 4548)
@@ -605,7 +605,9 @@
         def uformat_numeric(value):
             if value == decimal.Decimal(-9999999):
                 return "unbekannt"
-            return format_number(value)
+            if value is not None:
+                value = format_number(float(str(value)))
+            return value
 
         meta = self._getMeta(node)
         out = []



More information about the Mpuls-commits mailing list