Author: justi9
Date: 2010-09-21 17:23:46 -0400 (Tue, 21 Sep 2010)
New Revision: 4323
Modified:
mgmt/newdata/cumin/python/cumin/widgets.py
Log:
Background calls need the connection set in do_process
Modified: mgmt/newdata/cumin/python/cumin/widgets.py
===================================================================
--- mgmt/newdata/cumin/python/cumin/widgets.py 2010-09-21 21:18:34 UTC (rev 4322)
+++ mgmt/newdata/cumin/python/cumin/widgets.py 2010-09-21 21:23:46 UTC (rev 4323)
@@ -1340,19 +1340,20 @@
self.add_attribute(self.user)
def service(self, session):
- conn = self.app.database.get_connection()
- session.cursor = conn.cursor()
-
try:
return super(CuminPage, self).service(session)
except PageRedirect:
raise
except:
+ conn = self.app.database.get_connection()
conn.rollback()
raise
def do_process(self, session):
+ conn = self.app.database.get_connection()
+ session.cursor = conn.cursor()
+
if not self.authorized(session):
page = self.app.login_page
Show replies by date