oops, mainform default to True stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Wed, 10 Jun 2009 08:21:38 +0200
branchstable
changeset 2080 3ea388b5b9d8
parent 2079 aff0950c54c4
child 2085 9e279029d7a0
child 2089 b1070848726b
oops, mainform default to True
web/views/forms.py
--- a/web/views/forms.py	Wed Jun 10 08:21:27 2009 +0200
+++ b/web/views/forms.py	Wed Jun 10 08:21:38 2009 +0200
@@ -267,7 +267,7 @@
             self.edited_entity = self.complete_entity(self.row or 0, self.col or 0)
         self.form_add_hidden('__type', eidparam=True)
         self.form_add_hidden('eid')
-        if kwargs.get('mainform'):
+        if kwargs.get('mainform', True): # mainform default to true in parent
             self.form_add_hidden(u'__maineid', self.edited_entity.eid)
             # If we need to directly attach the new object to another one
             if self.req.list_form_param('__linkto'):