changeset 18:060797795a4d

work on json return values
author casties
date Wed, 18 Aug 2010 11:54:18 +0200
parents ed997e639cfd
children 78e70dfa7ad6 67ca17753cd5
files RestDbInterface.py
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/RestDbInterface.py	Tue Aug 17 11:16:16 2010 +0200
+++ b/RestDbInterface.py	Wed Aug 18 11:54:18 2010 +0200
@@ -10,6 +10,7 @@
 import logging
 import re
 import psycopg2
+import json
 
 from zope.interface import implements
 from zope.publisher.interfaces import IPublishTraverse
@@ -214,7 +215,8 @@
 
             logging.debug("put with schema=%s table=%s file=%s"%(schema,tablename,file))
             ret = self.createTableFromXML(schema, tablename, file)
-            
+            # set content type to json(?)
+            json.dump(ret, RESPONSE)
             
         else:
             # 400 Bad Request