[Mpuls-commits] r5784 - base/branches/2.1.0/mpulsweb/controllers
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Mon Jan 23 17:19:04 CET 2012
Author: torsten
Date: 2012-01-23 17:19:03 +0100 (Mon, 23 Jan 2012)
New Revision: 5784
Modified:
base/branches/2.1.0/mpulsweb/controllers/case.py
Log:
Issue2484: Load fresh created case if it is created. This triggers some extra
querys on the database but ensures that the case is correctly initialised
(session, navigation). Fixes error in meta-sync dialog which depends on a
correctly loaded case after creation. Loading overhead will not be creatical
here as case creating is not done so often.
Modified: base/branches/2.1.0/mpulsweb/controllers/case.py
===================================================================
--- base/branches/2.1.0/mpulsweb/controllers/case.py 2012-01-23 16:14:47 UTC (rev 5783)
+++ base/branches/2.1.0/mpulsweb/controllers/case.py 2012-01-23 16:19:03 UTC (rev 5784)
@@ -560,8 +560,12 @@
# 3. Do we want to sign the statement?
if form_result.get('statement_signed'):
statement.sign()
- return case
+ # Reload case to load navigation and set session correct. Loading
+ # overhead here is not nice but not critical as creating new cases
+ # should not happen so often
+ return self._loadCase(case.id)
+
@checkRole('cm')
def new(self):
session_case = SessionCase()
More information about the Mpuls-commits
mailing list