[Formed-commits] r420 - trunk/formed/formed/plugins/modify

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Mon Nov 8 14:30:04 CET 2010


Author: torsten
Date: 2010-11-08 14:30:02 +0100 (Mon, 08 Nov 2010)
New Revision: 420

Modified:
   trunk/formed/formed/plugins/modify/rules.py
Log:
Added missing change which presumably breaks current revision in svn.
Unfortunately i did not remember what it does exactly. 


Modified: trunk/formed/formed/plugins/modify/rules.py
===================================================================
--- trunk/formed/formed/plugins/modify/rules.py	2010-11-08 10:17:48 UTC (rev 419)
+++ trunk/formed/formed/plugins/modify/rules.py	2010-11-08 13:30:02 UTC (rev 420)
@@ -372,8 +372,10 @@
             if w.getName() in known_fields: continue
             
             flags = w.getFlags()
+            parent = w.getParent()
+            x = var_type.substitute(w.getName())
+
             if flags.find('required') >= 0:
-                x = var_type.substitute(w.getName())
                 if isinstance(w, (data.ChoiceNode, data.RadioNode)):
                     expr = "%s -1 == not" % x
                 else:
@@ -388,7 +390,6 @@
                 rule.setMark("warning:%s" % w.getName())
 
                 # add rules to the tree
-                parent = w.getParent()
                 parent.addChild(rule)
 
             # create additional error rule for datefields



More information about the Formed-commits mailing list