[Mpuls-commits] r5447 - base/trunk/mpulsweb/controllers

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Tue Oct 11 13:41:51 CEST 2011


Author: ludwig
Date: 2011-10-11 13:41:49 +0200 (Tue, 11 Oct 2011)
New Revision: 5447

Modified:
   base/trunk/mpulsweb/controllers/formularpage.py
Log:
Issue956: Only update navigation tree, if a repeat group is changed.


Modified: base/trunk/mpulsweb/controllers/formularpage.py
===================================================================
--- base/trunk/mpulsweb/controllers/formularpage.py	2011-10-10 15:28:19 UTC (rev 5446)
+++ base/trunk/mpulsweb/controllers/formularpage.py	2011-10-11 11:41:49 UTC (rev 5447)
@@ -14,7 +14,8 @@
 from mpulsweb.lib.translation import _
 from mpulsweb.lib.security import checkRole
 from mpulsweb.lib.db import  PostgresDBInterface
-from mpulsweb.lib.navigation import  mark_folderopen, get_navigation
+from mpulsweb.lib.navigation import  mark_folderopen, \
+        get_navigation
 
 from mpulsweb.lib.base import BaseController, render, session
 from mpulsweb.lib.helpers import url_for, literal
@@ -167,7 +168,11 @@
             # uncommitted fields data stored in the session.
             pass
         session['uncommited_fields'] = instance_tree.commit()
-        session['navigation.tree'] = get_navigation(case_id)
+        
+        if session['navigation.tree'].getTreeItem(page_id).parent.repeat:
+            session['navigation.tree'] = get_navigation(
+                                         case_id,
+                                         session['navigation.openfolders'])
         session.save()
 
         # How to proceed after saving the data?



More information about the Mpuls-commits mailing list