From 68e18398fdd054066eb550f71a788e41188c04f4 Mon Sep 17 00:00:00 2001 From: Sanj Date: Sun, 19 Feb 2012 17:39:07 +0530 Subject: [PATCH] convert Decimal instance to str before JSON serialization --- chaloBEST/mumbai/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chaloBEST/mumbai/models.py b/chaloBEST/mumbai/models.py index 72e2e41..a896524 100644 --- a/chaloBEST/mumbai/models.py +++ b/chaloBEST/mumbai/models.py @@ -164,7 +164,7 @@ class Route(models.Model): 'code': self.code, 'alias': self.alias, 'slug': self.slug, - 'distance': self.distance + 'distance': str(self.distance) } class RouteDetail(models.Model):