web/views/forms.py
branchstable
changeset 2080 3ea388b5b9d8
parent 2050 ce184fdb1e56
child 2089 b1070848726b
--- 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'):