web/views/forms.py
changeset 2046 8fce2d25853c
parent 2045 bf0643d4ef36
child 2048 5e4d1433b90b
--- a/web/views/forms.py	Thu Jun 04 10:54:13 2009 +0200
+++ b/web/views/forms.py	Fri Jun 05 09:13:49 2009 +0200
@@ -37,6 +37,7 @@
     cwtarget = None
     redirect_path = None
     set_error_url = True
+    set_dom_id = True
     copy_nav_params = False
     form_buttons = None # form buttons (button widgets instances)
     form_renderer_id = 'default'
@@ -53,6 +54,8 @@
                 setattr(self, key, val)
         if self.set_error_url:
             self.form_add_hidden('__errorurl', self.session_key())
+        if self.set_dom_id:
+            self.form_add_hidden('__domid', self.domid)
         if self.copy_nav_params:
             for param in NAV_FORM_PARAMETERS:
                 if not param in kwargs:
@@ -62,7 +65,6 @@
         if submitmsg is not None:
             self.form_add_hidden('__message', submitmsg)
         self.context = None
-        self.form_add_hidden('__domid', self.domid)
         if 'domid' in kwargs:# session key changed
             self.restore_previous_post(self.session_key())