[Zope3-checkins] CVS: Zope3/src/zope/app/browser/services - view.py:1.7 configure.zcml:1.20

Albertas Agejevas alga@codeworks.lt
Fri, 21 Feb 2003 09:50:05 -0500


Update of /cvs-repository/Zope3/src/zope/app/browser/services
In directory cvs.zope.org:/tmp/cvs-serv25262/app/browser/services

Modified Files:
	view.py configure.zcml 
Log Message:
Added calling the validation of PageConfiguration to its edit form.


=== Zope3/src/zope/app/browser/services/view.py 1.6 => 1.7 ===
--- Zope3/src/zope/app/browser/services/view.py:1.6	Mon Jan 27 21:21:40 2003
+++ Zope3/src/zope/app/browser/services/view.py	Fri Feb 21 09:50:05 2003
@@ -19,7 +19,7 @@
     search page
     browsing page
 
-  ViewConfigrationAdd
+  PageConfigurationView -- calls validation on PageConfiguration.
 
 $Id$
 """
@@ -106,3 +106,10 @@
                  })
 
         return result
+
+class PageConfigurationView:
+
+    def update(self):
+        super(PageConfigurationView, self).update()
+        if "UPDATE_SUBMIT" in self.request:
+            self.context.validate()


=== Zope3/src/zope/app/browser/services/configure.zcml 1.19 => 1.20 ===
--- Zope3/src/zope/app/browser/services/configure.zcml:1.19	Fri Feb  7 10:48:39 2003
+++ Zope3/src/zope/app/browser/services/configure.zcml	Fri Feb 21 09:50:05 2003
@@ -334,6 +334,10 @@
 
 <!-- Views -->
 
+<browser:defaultView
+    for="zope.app.interfaces.services.interfaces.IViewConfiguration"
+    name="edit.html" />
+
 <browser:editform
     schema="zope.app.interfaces.services.interfaces.IViewConfiguration"
     name="edit.html"
@@ -402,6 +406,7 @@
 <browser:editform
     schema="zope.app.interfaces.services.interfaces.IPageConfiguration"
     name="edit.html"
+    class=".view.PageConfigurationView"
     menu="zmi_views"
     label="Change page"
     permission="zope.ManageServices"