[Checkins] SVN: z3ext.layoutform/trunk/ do not show status message for subform

Nikolay Kim fafhrd91 at gmail.com
Tue Jun 23 03:39:22 EDT 2009


Log message for revision 101244:
  do not show status message for subform

Changed:
  U   z3ext.layoutform/trunk/CHANGES.txt
  U   z3ext.layoutform/trunk/src/z3ext/layoutform/subform.py

-=-
Modified: z3ext.layoutform/trunk/CHANGES.txt
===================================================================
--- z3ext.layoutform/trunk/CHANGES.txt	2009-06-23 07:20:56 UTC (rev 101243)
+++ z3ext.layoutform/trunk/CHANGES.txt	2009-06-23 07:39:21 UTC (rev 101244)
@@ -2,6 +2,12 @@
 CHANGES
 =======
 
+1.5.1 (Unreleased)
+------------------
+
+- Do not show status message for subform
+
+
 1.5.0 (2009-06-21)
 ------------------
 

Modified: z3ext.layoutform/trunk/src/z3ext/layoutform/subform.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/subform.py	2009-06-23 07:20:56 UTC (rev 101243)
+++ z3ext.layoutform/trunk/src/z3ext/layoutform/subform.py	2009-06-23 07:39:21 UTC (rev 101244)
@@ -22,7 +22,6 @@
 
 from z3c.form import subform, button
 from z3c.form.interfaces import ISubForm, IActionHandler
-from z3ext.statusmessage.interfaces import IStatusMessage
 
 from utils import applyChanges
 from form import PageletBaseForm
@@ -47,17 +46,16 @@
     @button.handler(ISaveAction)
     def handleApply(self, action):
         data, errors = self.extractData()
-        if errors:
-            IStatusMessage(self.request).add(
-                (self.formErrorsMessage,) + errors, 'formError')
-        else:
+
+        if not errors:
             changes = self.applyChanges(data)
             if changes:
                 descriptions = []
                 for interface, names in changes.items():
                     descriptions.append(Attributes(interface, *names))
 
-                event.notify(ObjectModifiedEvent(self.getContent(), *descriptions))
+                event.notify(
+                    ObjectModifiedEvent(self.getContent(), *descriptions))
 
     def executeActions(self, form):
         request = self.request



More information about the Checkins mailing list