[Checkins] SVN: z3ext.layoutform/tags/1.2.4/ release tag
Nikolay Kim
fafhrd at datacom.kz
Mon Oct 20 04:39:35 EDT 2008
Log message for revision 92393:
release tag
Changed:
A z3ext.layoutform/tags/1.2.4/
D z3ext.layoutform/tags/1.2.4/CHANGES.txt
A z3ext.layoutform/tags/1.2.4/CHANGES.txt
D z3ext.layoutform/tags/1.2.4/buildout.cfg
A z3ext.layoutform/tags/1.2.4/buildout.cfg
A z3ext.layoutform/tags/1.2.4/scripts/
D z3ext.layoutform/tags/1.2.4/setup.py
A z3ext.layoutform/tags/1.2.4/setup.py
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formdisplay.pt
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspacedisp.pt
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/widgetDisplay.pt
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py
D z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py
A z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/locales/
-=-
Copied: z3ext.layoutform/tags/1.2.4 (from rev 92278, z3ext.layoutform/trunk)
Deleted: z3ext.layoutform/tags/1.2.4/CHANGES.txt
===================================================================
--- z3ext.layoutform/trunk/CHANGES.txt 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/CHANGES.txt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,82 +0,0 @@
-=======
-CHANGES
-=======
-
-1.2.3 (2008-10-14)
-------------------
-
-- Groups support restored
-
-- Use IPageletType for views
-
-
-1.2.2 (2008-10-08)
-------------------
-
-- Added extra views for form
-
-
-1.2.1 (2008-10-08)
-------------------
-
-- Show all form errors
-
-
-1.2.0 (2008-10-06)
-------------------
-
-- Added default css styles
-
-- Removed z3c packages dependencies
-
-- Use pagelets instead of macros
-
-
-1.1.2 (2008-09-26)
-------------------
-
-- Added group support
-
-- Return added object in createAndAdd method
-
-
-1.1.1 (2008-08-05)
-------------------
-
-- Fixed wrong `for` in label tag
-
-
-1.1.0 (2008-07-22)
-------------------
-
-- Remove cancel button from edit form
-
-
-1.0.1 (2008-06-02)
-------------------
-
-- Redirect to nextURL after success 'apply'
-
-
-1.0.0 (2008-05-13)
-------------------
-
-- Use `includeDependencies` instead `autoinclude`
-
-
-0.2.0 (2008-??-??)
-------------------
-
-- Use z3c.autoinclude
-
-
-0.1.1 (2008-01-22)
-------------------
-
-- Fixed missing import in add.py
-
-
-0.1 (2008-01-19)
-----------------
-
-- Initial release
Copied: z3ext.layoutform/tags/1.2.4/CHANGES.txt (from rev 92391, z3ext.layoutform/trunk/CHANGES.txt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/CHANGES.txt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/CHANGES.txt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,90 @@
+=======
+CHANGES
+=======
+
+1.2.4 (2008-10-20)
+------------------
+
+- Added support of display form
+
+- Added tranlsations: nl, ru
+
+
+1.2.3 (2008-10-14)
+------------------
+
+- Groups support restored
+
+- Use IPageletType for views
+
+
+1.2.2 (2008-10-08)
+------------------
+
+- Added extra views for form
+
+
+1.2.1 (2008-10-08)
+------------------
+
+- Show all form errors
+
+
+1.2.0 (2008-10-06)
+------------------
+
+- Added default css styles
+
+- Removed z3c packages dependencies
+
+- Use pagelets instead of macros
+
+
+1.1.2 (2008-09-26)
+------------------
+
+- Added group support
+
+- Return added object in createAndAdd method
+
+
+1.1.1 (2008-08-05)
+------------------
+
+- Fixed wrong `for` in label tag
+
+
+1.1.0 (2008-07-22)
+------------------
+
+- Remove cancel button from edit form
+
+
+1.0.1 (2008-06-02)
+------------------
+
+- Redirect to nextURL after success 'apply'
+
+
+1.0.0 (2008-05-13)
+------------------
+
+- Use `includeDependencies` instead `autoinclude`
+
+
+0.2.0 (2008-??-??)
+------------------
+
+- Use z3c.autoinclude
+
+
+0.1.1 (2008-01-22)
+------------------
+
+- Fixed missing import in add.py
+
+
+0.1 (2008-01-19)
+----------------
+
+- Initial release
Deleted: z3ext.layoutform/tags/1.2.4/buildout.cfg
===================================================================
--- z3ext.layoutform/trunk/buildout.cfg 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/buildout.cfg 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,18 +0,0 @@
-[buildout]
-develop = .
-parts = test coverage-test coverage-report
-
-[test]
-recipe = zc.recipe.testrunner
-eggs = z3ext.layoutform [test]
-
-[coverage-test]
-recipe = zc.recipe.testrunner
-eggs = z3ext.layoutform [test]
-defaults = ['--coverage', '../../coverage']
-
-[coverage-report]
-recipe = zc.recipe.egg
-eggs = z3c.coverage
-scripts = coverage=coverage-report
-arguments = ('coverage', 'coverage/report')
Copied: z3ext.layoutform/tags/1.2.4/buildout.cfg (from rev 92391, z3ext.layoutform/trunk/buildout.cfg)
===================================================================
--- z3ext.layoutform/tags/1.2.4/buildout.cfg (rev 0)
+++ z3ext.layoutform/tags/1.2.4/buildout.cfg 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,56 @@
+[buildout]
+develop = .
+parts = test coverage-test coverage-report i18n i18nall i18ncheck i18ndude
+
+[test]
+recipe = zc.recipe.testrunner
+eggs = z3ext.layoutform [test]
+
+[coverage-test]
+recipe = zc.recipe.testrunner
+eggs = z3ext.layoutform [test]
+defaults = ['--coverage', '../../coverage']
+
+[coverage-report]
+recipe = zc.recipe.egg
+eggs = z3c.coverage
+scripts = coverage=coverage-report
+arguments = ('coverage', 'coverage/report')
+
+
+[i18n]
+recipe = z3c.recipe.i18n:i18n
+packages = z3ext.layoutform
+domain = z3ext.layoutform
+output = ${buildout:directory}/src/z3ext/layoutform/locales
+eggs = z3ext.layoutform [test]
+zcml =
+ <configure i18n_domain="zope"
+ xmlns:zcml="http://namespaces.zope.org/zcml"
+ xmlns:browser="http://namespaces.zope.org/browser">
+ <include package="zope.component" file="meta.zcml" />
+ <include package="zope.app.component" file="meta.zcml" />
+ <include package="zope.app.security" file="meta.zcml" />
+ <include package="zope.app.pagetemplate" file="meta.zcml" />
+ <include package="zope.app.security" />
+ <include package="zope.app.zcmlfiles" />
+ <include package="zope.app.authentication" />
+
+ <include package="z3c.autoinclude" file="meta.zcml" />
+ <include package="z3ext.layoutform" />
+ </configure>
+
+[i18nall]
+recipe = buildout_script
+template_dir = ${buildout:directory}/scripts/
+template = i18nall.in
+
+[i18ncheck]
+recipe = buildout_script
+template_dir = ${buildout:directory}/scripts/
+template = i18ncheck.in
+
+[i18ndude]
+unzip = true
+recipe = zc.recipe.egg
+eggs = i18ndude
Copied: z3ext.layoutform/tags/1.2.4/scripts (from rev 92391, z3ext.layoutform/trunk/scripts)
Deleted: z3ext.layoutform/tags/1.2.4/setup.py
===================================================================
--- z3ext.layoutform/trunk/setup.py 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/setup.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,72 +0,0 @@
-##############################################################################
-#
-# Copyright (c) 2007 Zope Corporation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-"""Setup for z3ext.layoutform package
-
-$Id$
-"""
-import sys, os
-from setuptools import setup, find_packages
-
-def read(*rnames):
- return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
-
-version='1.2.3dev'
-
-
-setup(name='z3ext.layoutform',
- version=version,
- description="UI Skin for z3c.form based on z3ext.layout",
- long_description=(
- 'Detailed Documentation\n' +
- '======================\n'
- + '\n\n' +
- read('CHANGES.txt')
- ),
- classifiers=[
- 'Development Status :: 5 - Production/Stable',
- 'Environment :: Web Environment',
- 'Intended Audience :: Developers',
- 'License :: OSI Approved :: Zope Public License',
- 'Programming Language :: Python',
- 'Natural Language :: English',
- 'Operating System :: OS Independent',
- 'Topic :: Internet :: WWW/HTTP',
- 'Framework :: Zope3'],
- author='Nikolay Kim',
- author_email='fafhrd91 at gmail.com',
- url='http://z3ext.net/',
- license='ZPL 2.1',
- packages=find_packages('src'),
- package_dir = {'':'src'},
- namespace_packages=['z3ext'],
- install_requires = ['setuptools',
- 'zope.publisher',
- 'zope.component',
- 'zope.pagetemplate',
- 'zope.app.pagetemplate',
- 'zope.i18nmessageid',
- 'z3c.form',
- 'z3c.autoinclude',
- 'z3ext.layout>=1.5.1',
- 'z3ext.resource>=1.2.0',
- 'z3ext.resourcepackage>=1.2.0',
- 'z3ext.statusmessage',
- ],
- extras_require = dict(test=['zope.app.testing',
- 'zope.testing',
- 'zope.testbrowser',
- ]),
- include_package_data = True,
- zip_safe = False
- )
Copied: z3ext.layoutform/tags/1.2.4/setup.py (from rev 92391, z3ext.layoutform/trunk/setup.py)
===================================================================
--- z3ext.layoutform/tags/1.2.4/setup.py (rev 0)
+++ z3ext.layoutform/tags/1.2.4/setup.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,73 @@
+##############################################################################
+#
+# Copyright (c) 2007 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""Setup for z3ext.layoutform package
+
+$Id$
+"""
+import sys, os
+from setuptools import setup, find_packages
+
+def read(*rnames):
+ return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
+
+version='1.2.4'
+
+
+setup(name='z3ext.layoutform',
+ version=version,
+ description="UI Skin for z3c.form based on z3ext.layout",
+ long_description=(
+ 'Detailed Documentation\n' +
+ '======================\n'
+ + '\n\n' +
+ read('CHANGES.txt')
+ ),
+ classifiers=[
+ 'Development Status :: 5 - Production/Stable',
+ 'Environment :: Web Environment',
+ 'Intended Audience :: Developers',
+ 'License :: OSI Approved :: Zope Public License',
+ 'Programming Language :: Python',
+ 'Natural Language :: English',
+ 'Operating System :: OS Independent',
+ 'Topic :: Internet :: WWW/HTTP',
+ 'Framework :: Zope3'],
+ author='Nikolay Kim',
+ author_email='fafhrd91 at gmail.com',
+ url='http://z3ext.net/',
+ license='ZPL 2.1',
+ packages=find_packages('src'),
+ package_dir = {'':'src'},
+ namespace_packages=['z3ext'],
+ install_requires = ['setuptools',
+ 'zope.publisher',
+ 'zope.component',
+ 'zope.pagetemplate',
+ 'zope.app.pagetemplate',
+ 'zope.i18n',
+ 'zope.i18nmessageid',
+ 'z3c.form',
+ 'z3c.autoinclude',
+ 'z3ext.layout>=1.5.1',
+ 'z3ext.resource>=1.2.0',
+ 'z3ext.resourcepackage>=1.2.0',
+ 'z3ext.statusmessage',
+ ],
+ extras_require = dict(test=['zope.app.testing',
+ 'zope.testing',
+ 'zope.testbrowser',
+ ]),
+ include_package_data = True,
+ zip_safe = False
+ )
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/__init__.py 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,8 +0,0 @@
-# This file is necessary to make this directory a package.
-
-from z3c.form import button
-
-from field import Fields
-from form import PageletForm
-from add import PageletAddForm
-from edit import PageletEditForm
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/__init__.py)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/__init__.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,9 @@
+# This file is necessary to make this directory a package.
+
+from z3c.form import button
+
+from field import Fields
+from form import PageletForm
+from form import PageletDisplayForm
+from add import PageletAddForm
+from edit import PageletEditForm
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/browser/configure.zcml 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,211 +0,0 @@
-<configure
- xmlns="http://namespaces.zope.org/zope"
- xmlns:z3ext="http://namespaces.zope.org/z3ext">
-
- <!-- buttons -->
- <adapter
- provides="z3c.form.interfaces.IButtonAction"
- factory=".buttons.ButtonAction" />
-
- <adapter
- provides="z3c.form.interfaces.IButtonAction"
- factory=".buttons.AddButtonAction" />
-
- <adapter
- provides="z3c.form.interfaces.IButtonAction"
- factory=".buttons.SaveButtonAction" />
-
- <adapter
- provides="z3c.form.interfaces.IButtonAction"
- factory=".buttons.CancelButtonAction" />
-
- <!-- TextArea widget -->
- <class class=".textarea.TextAreaWidget">
- <require
- permission="zope.Public"
- interface="z3c.form.interfaces.ITextAreaWidget" />
- </class>
-
- <adapter
- for="zope.schema.interfaces.IText
- ..interfaces.ILayoutFormLayer"
- factory=".textarea.TextAreaFieldWidget" />
-
- <!-- templates -->
- <z3ext:pagelet
- template="form.pt"
- for="..interfaces.IPageletForm"
- layer="..interfaces.ILayoutFormLayer"
- provides="..interfaces.IPageletFormView"
- permission="zope.Public" />
-
- <z3ext:pagelet
- template="formadd.pt"
- for="..interfaces.IPageletAddForm"
- layer="..interfaces.ILayoutFormLayer"
- provides="..interfaces.IPageletFormView"
- permission="zope.Public" />
-
- <z3ext:pagelet
- template="formedit.pt"
- for="..interfaces.IPageletEditForm"
- layer="..interfaces.ILayoutFormLayer"
- provides="..interfaces.IPageletFormView"
- permission="zope.Public" />
-
- <z3ext:pagelet
- template="subform.pt"
- for="z3c.form.interfaces.ISubForm"
- layer="..interfaces.ILayoutFormLayer"
- provides="..interfaces.IPageletFormView"
- permission="zope.Public" />
-
- <z3ext:pagelet
- template="formgroup.pt"
- for="z3c.form.group.Group"
- layer="..interfaces.ILayoutFormLayer"
- provides="..interfaces.IPageletFormView"
- permission="zope.Public" />
-
- <!-- Error View -->
- <z3ext:pagelet
- for="z3c.form.interfaces.IErrorViewSnippet"
- template="error.pt"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- form view -->
- <interface
- name="layoutform.form"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IForm" />
-
- <z3ext:pagelet
- for="z3c.form.interfaces.IForm"
- template="formview.pt"
- provides="z3ext.layoutform.browser.interfaces.IForm"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- viewspace view -->
- <interface
- name="layoutform.viewspace"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IViewspace" />
-
- <z3ext:pagelet
- for="..interfaces.IPageletForm"
- template="formviewspace.pt"
- provides="z3ext.layoutform.browser.interfaces.IViewspace"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- form buttons -->
- <interface
- name="layoutform.buttons"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IFormButtons" />
-
- <z3ext:pagelet
- for="..interfaces.IPageletForm"
- template="formbuttons.pt"
- provides="z3ext.layoutform.browser.interfaces.IFormButtons"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- widget view -->
- <interface
- name="layoutform.widget"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IWidget" />
-
- <z3ext:pagelet
- for="z3c.form.interfaces.IWidget"
- template="widget.pt"
- provides="z3ext.layoutform.browser.interfaces.IWidget"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- group view -->
- <interface
- name="layoutform.group"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IGroup" />
-
- <z3ext:pagelet
- for="z3c.form.interfaces.IGroup"
- template="formgroup.pt"
- provides="z3ext.layoutform.browser.interfaces.IGroup"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- groups view -->
- <interface
- name="layoutform.groups"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IFormGroups" />
-
- <z3ext:pagelet
- for="..interfaces.IPageletForm"
- template="formgroups.pt"
- provides="z3ext.layoutform.browser.interfaces.IFormGroups"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- add form buttons -->
- <z3ext:pagelet
- for="..interfaces.IPageletAddForm"
- template="formaddbuttons.pt"
- provides="z3ext.layoutform.browser.interfaces.IFormButtons"
- layer="..interfaces.ILayoutFormLayer"
- permission="zope.Public" />
-
- <!-- extra form views -->
- <interface
- name="layoutform.formInfo"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IExtraFormInfo" />
-
- <interface
- name="layoutform.viewspaceInfo"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IExtraViewspaceInfo" />
-
- <interface
- name="layoutform.widgetBefore"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IExtraBeforeWidget" />
-
- <interface
- name="layoutform.widgetAfter"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IExtraAfterWidget" />
-
- <interface
- name="layoutform.buttonsInfo"
- type="z3ext.layout.interfaces.IPageletType"
- interface="z3ext.layoutform.browser.interfaces.IExtraFormButtonsInfo" />
-
- <!-- status message -->
- <adapter factory=".message.Message" />
-
- <!-- styles -->
- <z3ext:resourceinclude
- name="z3ext-layoutform.css"
- library="z3ext"
- type="stylesheet"
- file="styles.css" filetype="zrt" />
-
- <z3ext:resource
- file="required.gif"
- name="z3ext-layoutform-required.gif" />
-
- <z3ext:resource
- file="linkOpaque.gif"
- name="z3ext-layoutform-linkOpaque.gif" />
-
- <z3ext:resource
- file="linkTransparent.gif"
- name="z3ext-layoutform-linkTransparent.gif" />
-
-</configure>
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/configure.zcml)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/configure.zcml 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,243 @@
+<configure
+ xmlns="http://namespaces.zope.org/zope"
+ xmlns:z3ext="http://namespaces.zope.org/z3ext">
+
+ <!-- buttons -->
+ <adapter
+ provides="z3c.form.interfaces.IButtonAction"
+ factory=".buttons.ButtonAction" />
+
+ <adapter
+ provides="z3c.form.interfaces.IButtonAction"
+ factory=".buttons.AddButtonAction" />
+
+ <adapter
+ provides="z3c.form.interfaces.IButtonAction"
+ factory=".buttons.SaveButtonAction" />
+
+ <adapter
+ provides="z3c.form.interfaces.IButtonAction"
+ factory=".buttons.CancelButtonAction" />
+
+ <!-- TextArea widget -->
+ <class class=".textarea.TextAreaWidget">
+ <require
+ permission="zope.Public"
+ interface="z3c.form.interfaces.ITextAreaWidget" />
+ </class>
+
+ <adapter
+ for="zope.schema.interfaces.IText
+ ..interfaces.ILayoutFormLayer"
+ factory=".textarea.TextAreaFieldWidget" />
+
+ <!-- templates -->
+ <z3ext:pagelet
+ template="form.pt"
+ for="..interfaces.IPageletForm"
+ layer="..interfaces.ILayoutFormLayer"
+ provides="..interfaces.IPageletFormView"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ template="formadd.pt"
+ for="..interfaces.IPageletAddForm"
+ layer="..interfaces.ILayoutFormLayer"
+ provides="..interfaces.IPageletFormView"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ template="formedit.pt"
+ for="..interfaces.IPageletEditForm"
+ layer="..interfaces.ILayoutFormLayer"
+ provides="..interfaces.IPageletFormView"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ template="subform.pt"
+ for="z3c.form.interfaces.ISubForm"
+ layer="..interfaces.ILayoutFormLayer"
+ provides="..interfaces.IPageletFormView"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ template="formgroup.pt"
+ for="z3c.form.group.Group"
+ layer="..interfaces.ILayoutFormLayer"
+ provides="..interfaces.IPageletFormView"
+ permission="zope.Public" />
+
+ <!-- Error View -->
+ <z3ext:pagelet
+ for="z3c.form.interfaces.IErrorViewSnippet"
+ template="error.pt"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- form view -->
+ <interface
+ name="layoutform.form"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IForm" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletForm"
+ template="formview.pt"
+ provides="z3ext.layoutform.browser.interfaces.IForm"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletDisplayForm"
+ template="formdisplay.pt"
+ provides="z3ext.layoutform.browser.interfaces.IForm"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- viewspace view -->
+ <interface
+ name="layoutform.viewspace"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IViewspace" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletForm"
+ template="formviewspace.pt"
+ provides="z3ext.layoutform.browser.interfaces.IViewspace"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletDisplayForm"
+ template="formviewspacedisp.pt"
+ provides="z3ext.layoutform.browser.interfaces.IViewspace"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- form buttons -->
+ <interface
+ name="layoutform.buttons"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IFormButtons" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletForm"
+ template="formbuttons.pt"
+ provides="z3ext.layoutform.browser.interfaces.IFormButtons"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- widget view -->
+ <interface
+ name="layoutform.widget"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IWidget" />
+
+ <z3ext:pagelet
+ for="z3c.form.interfaces.IWidget"
+ template="widget.pt"
+ provides="z3ext.layoutform.browser.interfaces.IWidget"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- display widget view -->
+ <interface
+ name="layoutform.widgetDisplay"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IWidgetDisplay" />
+
+ <z3ext:pagelet
+ for="z3c.form.interfaces.IWidget"
+ template="widgetDisplay.pt"
+ provides="z3ext.layoutform.browser.interfaces.IWidgetDisplay"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- group view -->
+ <interface
+ name="layoutform.group"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IGroup" />
+
+ <z3ext:pagelet
+ for="z3c.form.interfaces.IGroup"
+ template="formgroup.pt"
+ provides="z3ext.layoutform.browser.interfaces.IGroup"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- groups view -->
+ <interface
+ name="layoutform.groups"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IFormGroups" />
+
+ <z3ext:pagelet
+ for="..interfaces.IPageletForm"
+ template="formgroups.pt"
+ provides="z3ext.layoutform.browser.interfaces.IFormGroups"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- add form buttons -->
+ <z3ext:pagelet
+ for="..interfaces.IPageletAddForm"
+ template="formaddbuttons.pt"
+ provides="z3ext.layoutform.browser.interfaces.IFormButtons"
+ layer="..interfaces.ILayoutFormLayer"
+ permission="zope.Public" />
+
+ <!-- extra form views -->
+ <interface
+ name="layoutform.formInfo"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IExtraFormInfo" />
+
+ <interface
+ name="layoutform.formGroups"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IFormGroups" />
+
+ <interface
+ name="layoutform.viewspaceInfo"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IExtraViewspaceInfo" />
+
+ <interface
+ name="layoutform.widgetBefore"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IExtraBeforeWidget" />
+
+ <interface
+ name="layoutform.widgetAfter"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IExtraAfterWidget" />
+
+ <interface
+ name="layoutform.buttonsInfo"
+ type="z3ext.layout.interfaces.IPageletType"
+ interface="z3ext.layoutform.browser.interfaces.IExtraFormButtonsInfo" />
+
+ <!-- status message -->
+ <adapter factory=".message.Message" />
+
+ <!-- styles -->
+ <z3ext:resourceinclude
+ name="z3ext-layoutform.css"
+ library="z3ext"
+ type="stylesheet"
+ file="styles.css" filetype="zrt" />
+
+ <z3ext:resource
+ file="required.gif"
+ name="z3ext-layoutform-required.gif" />
+
+ <z3ext:resource
+ file="linkOpaque.gif"
+ name="z3ext-layoutform-linkOpaque.gif" />
+
+ <z3ext:resource
+ file="linkTransparent.gif"
+ name="z3ext-layoutform-linkTransparent.gif" />
+
+</configure>
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formdisplay.pt (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formdisplay.pt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formdisplay.pt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formdisplay.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,2 @@
+<tal:block tal:content="structure context/@@pagelet/layoutform.formInfo|nothing" />
+<tal:block tal:content="structure context/@@pagelet/layoutform.viewspace" />
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formgroups.pt 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,3 +0,0 @@
-<tal:block
- tal:repeat="group context/groups"
- tal:content="structure group/@@pagelet/layoutform.group" />
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formgroups.pt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formgroups.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,3 @@
+<tal:block
+ tal:repeat="group context/groups"
+ tal:content="structure group/@@pagelet/layoutform.group|nothing" />
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formviewspace.pt 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,18 +0,0 @@
-<h1 tal:condition="context/label|nothing"
- tal:content="context/label|nothing">Do something</h1>
-<div class="z-form-description"
- tal:condition="context/description|nothing"
- tal:content="context/description|nothing"></div>
-
-<tal:block tal:content="structure
- context/@@pagelet/layoutform.viewspaceInfo|nothing" />
-
-<div class="z-form-fieldset" tal:condition="context/widgets">
- <tal:block tal:repeat="widget context/widgets/values"
- tal:content="structure
- widget/@@pagelet/z3ext.layoutform.browser.interfaces.IWidget" />
-</div>
-
-<tal:block tal:condition="context/groups|nothing"
- tal:content="structure
- context/@@pagelet/z3ext.layoutform.browser.interfaces.IFormGroups|nothing" />
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formviewspace.pt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspace.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,16 @@
+<h1 tal:condition="context/label|nothing"
+ tal:content="context/label|nothing">Do something</h1>
+<div class="z-form-description"
+ tal:condition="context/description|nothing"
+ tal:content="context/description|nothing"></div>
+
+<tal:block tal:content="structure
+ context/@@pagelet/layoutform.viewspaceInfo|nothing" />
+
+<div class="z-form-fieldset" tal:condition="context/widgets">
+ <tal:block tal:repeat="widget context/widgets/values"
+ tal:content="structure widget/@@pagelet/layoutform.widget" />
+</div>
+
+<tal:block tal:condition="context/groups|nothing"
+ tal:content="structure context/@@pagelet/layoutform.formGroups|nothing" />
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspacedisp.pt (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/formviewspacedisp.pt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspacedisp.pt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/formviewspacedisp.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,16 @@
+<h1 tal:condition="context/label|nothing"
+ tal:content="context/label|nothing">Do something</h1>
+<div class="z-form-description"
+ tal:condition="context/description|nothing"
+ tal:content="context/description|nothing"></div>
+
+<tal:block tal:content="structure
+ context/@@pagelet/layoutform.viewspaceInfo|nothing" />
+
+<div class="z-form-fieldset" tal:condition="context/widgets">
+ <tal:block tal:repeat="widget context/widgets/values"
+ tal:content="structure widget/@@pagelet/layoutform.widgetDisplay" />
+</div>
+
+<tal:block tal:condition="context/groups|nothing"
+ tal:content="structure context/@@pagelet/layoutform.formGroups|nothing" />
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/browser/interfaces.py 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,62 +0,0 @@
-##############################################################################
-#
-# Copyright (c) 2008 Zope Corporation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-"""
-
-$Id: 2007-12-12 12:27:02Z fafhrd $
-"""
-from zope import interface
-
-
-class IForm(interface.Interface):
- """ form view """
-
-
-class IExtraFormInfo(interface.Interface):
- """ extra form information """
-
-
-class IViewspace(interface.Interface):
- """ form viewspace """
-
-
-class IExtraViewspaceInfo(interface.Interface):
- """ extra widget information """
-
-
-class IWidget(interface.Interface):
- """ widget view """
-
-
-class IExtraBeforeWidget(interface.Interface):
- """ extra widget information """
-
-
-class IExtraAfterWidget(interface.Interface):
- """ extra widget information """
-
-
-class IGroup(interface.Interface):
- """ group """
-
-
-class IFormGroups(interface.Interface):
- """ form groups """
-
-
-class IFormButtons(interface.Interface):
- """ form buttons """
-
-
-class IExtraFormButtonsInfo(interface.Interface):
- """ extra buttons information """
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/interfaces.py)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/interfaces.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,66 @@
+##############################################################################
+#
+# Copyright (c) 2008 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""
+
+$Id: 2007-12-12 12:27:02Z fafhrd $
+"""
+from zope import interface
+
+
+class IForm(interface.Interface):
+ """ form view """
+
+
+class IExtraFormInfo(interface.Interface):
+ """ extra form information """
+
+
+class IViewspace(interface.Interface):
+ """ form viewspace """
+
+
+class IExtraViewspaceInfo(interface.Interface):
+ """ extra widget information """
+
+
+class IWidget(interface.Interface):
+ """ widget view """
+
+
+class IWidgetDisplay(interface.Interface):
+ """ dispaly widget view """
+
+
+class IExtraBeforeWidget(interface.Interface):
+ """ extra widget information """
+
+
+class IExtraAfterWidget(interface.Interface):
+ """ extra widget information """
+
+
+class IGroup(interface.Interface):
+ """ group """
+
+
+class IFormGroups(interface.Interface):
+ """ form groups """
+
+
+class IFormButtons(interface.Interface):
+ """ form buttons """
+
+
+class IExtraFormButtonsInfo(interface.Interface):
+ """ extra buttons information """
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/widgetDisplay.pt (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/browser/widgetDisplay.pt)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/widgetDisplay.pt (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/browser/widgetDisplay.pt 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,8 @@
+<div class="z-form-field">
+ <label tal:attributes="for context/id;
+ title context/field/description"
+ tal:content="context/label">The Label</label>
+ <div tal:content="structure context/render">
+ <input type="text" style="width:100%" />
+ </div>
+</div>
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/configure.zcml 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,19 +0,0 @@
-<configure
- xmlns="http://namespaces.zope.org/zope"
- xmlns:z3c="http://namespaces.zope.org/z3c">
-
- <includeDependencies package="z3ext.layoutform" />
-
- <!-- form error status message -->
- <utility
- name="formError"
- provides="z3ext.statusmessage.interfaces.IMessageFactory"
- component=".error.FormErrorStatusMessage" />
-
- <class class=".error.FormErrorStatusMessage">
- <allow interface=".interfaces.IFormErrorStatusMessage" />
- </class>
-
- <include package=".browser" />
-
-</configure>
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/configure.zcml)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/configure.zcml 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,23 @@
+<configure
+ xmlns="http://namespaces.zope.org/zope"
+ xmlns:z3c="http://namespaces.zope.org/z3c"
+ xmlns:i18n="http://namespaces.zope.org/i18n">
+
+ <includeDependencies package="z3ext.layoutform" />
+
+ <!-- form error status message -->
+ <utility
+ name="formError"
+ provides="z3ext.statusmessage.interfaces.IMessageFactory"
+ component=".error.FormErrorStatusMessage" />
+
+ <class class=".error.FormErrorStatusMessage">
+ <allow interface=".interfaces.IFormErrorStatusMessage" />
+ </class>
+
+ <include package=".browser" />
+
+ <!-- translations -->
+ <i18n:registerTranslations directory="locales"/>
+
+</configure>
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/form.py 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,45 +0,0 @@
-##############################################################################
-#
-# Copyright (c) 2007 Zope Foundation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-"""Support for Layout Templates
-
-$Id$
-"""
-from zope import interface
-from zope.component import getMultiAdapter, queryMultiAdapter
-from zope.pagetemplate.interfaces import IPageTemplate
-
-from z3c.form import form
-from z3ext.layout.interfaces import IPagelet
-from z3ext.layout.pagelet import BrowserPagelet
-
-from interfaces import IPageletForm, IPageletFormView
-
-
-class PageletForm(form.Form, BrowserPagelet):
- interface.implements(IPageletForm)
-
- __call__ = BrowserPagelet.__call__
-
- def render(self):
- # render content template
- if self.template is None:
- view = queryMultiAdapter((self, self.request), IPageletFormView)
- if view is not None:
- view.update()
- return view.render()
-
- template = getMultiAdapter((self, self.request), IPageTemplate)
- return template(self)
-
- return self.template()
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/form.py)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/form.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,52 @@
+##############################################################################
+#
+# Copyright (c) 2007 Zope Foundation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+"""Support for Layout Templates
+
+$Id$
+"""
+from zope import interface
+from zope.component import getMultiAdapter, queryMultiAdapter
+from zope.pagetemplate.interfaces import IPageTemplate
+
+from z3c.form import form
+from z3ext.layout.interfaces import IPagelet
+from z3ext.layout.pagelet import BrowserPagelet
+
+from interfaces import IPageletForm, IPageletDisplayForm, IPageletFormView
+
+
+class PageletForm(form.Form, BrowserPagelet):
+ interface.implements(IPageletForm)
+
+ __call__ = BrowserPagelet.__call__
+
+ def render(self):
+ # render content template
+ if self.template is None:
+ view = queryMultiAdapter((self, self.request), IPageletFormView)
+ if view is not None:
+ view.update()
+ return view.render()
+
+ template = getMultiAdapter((self, self.request), IPageTemplate)
+ return template(self)
+
+ return self.template()
+
+
+class PageletDisplayForm(form.DisplayForm, PageletForm):
+ interface.implements(IPageletDisplayForm)
+
+ render = PageletForm.render
+ __call__ = PageletForm.__call__
Deleted: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py
===================================================================
--- z3ext.layoutform/trunk/src/z3ext/layoutform/interfaces.py 2008-10-16 07:52:43 UTC (rev 92278)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -1,78 +0,0 @@
-##############################################################################
-#
-# Copyright (c) 2008 Zope Corporation and Contributors.
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-##############################################################################
-""" z3ext.layoutform interfaces
-
-$Id$
-"""
-from zope import interface
-from zope.i18nmessageid import MessageFactory
-from z3c.form.interfaces import IFormLayer
-from z3ext.layout.interfaces import IPagelet
-from z3ext.statusmessage.interfaces import IMessage
-
-_ = MessageFactory('z3ext')
-
-
-class ILayoutFormLayer(IFormLayer):
- """ browser layer """
-
-
-class IPageletFormView(IPagelet):
- """ pagelet form view """
-
-
-class IPageletForm(IPagelet):
- """Form mixin for pagelet implementation."""
-
- label = interface.Attribute('Form label')
-
- description = interface.Attribute('Form label')
-
-
-class IPageletAddForm(IPageletForm):
- """Add form mixin for pagelet implementation."""
-
- formCancelMessage = interface.Attribute('Form cancel message')
-
- def nextURL():
- """ as next url use newly created content url """
-
- def cancelURL():
- """ cancel url """
-
- def nameAllowed():
- """Return whether names can be input by the user."""
-
-
-class IPageletEditForm(IPageletForm):
- """Edit form mixin for pagelet implementation."""
-
- def nextURL():
- """ as next url use newly created content url """
-
-
-class IAddButton(interface.Interface):
- """ add button """
-
-
-class ISaveButton(interface.Interface):
- """ save button """
-
-
-class ICancelButton(interface.Interface):
- """ cancel button """
-
-
-class IFormErrorStatusMessage(IMessage):
- """ form error status message """
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/interfaces.py)
===================================================================
--- z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py (rev 0)
+++ z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/interfaces.py 2008-10-20 08:39:35 UTC (rev 92393)
@@ -0,0 +1,82 @@
+##############################################################################
+#
+# Copyright (c) 2008 Zope Corporation and Contributors.
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL). A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+##############################################################################
+""" z3ext.layoutform interfaces
+
+$Id$
+"""
+from zope import interface
+from zope.i18nmessageid import MessageFactory
+from z3c.form.interfaces import IFormLayer
+from z3ext.layout.interfaces import IPagelet
+from z3ext.statusmessage.interfaces import IMessage
+
+_ = MessageFactory('z3ext')
+
+
+class ILayoutFormLayer(IFormLayer):
+ """ browser layer """
+
+
+class IPageletFormView(IPagelet):
+ """ pagelet form view """
+
+
+class IPageletForm(IPagelet):
+ """Form mixin for pagelet implementation."""
+
+ label = interface.Attribute('Form label')
+
+ description = interface.Attribute('Form label')
+
+
+class IPageletAddForm(IPageletForm):
+ """Add form mixin for pagelet implementation."""
+
+ formCancelMessage = interface.Attribute('Form cancel message')
+
+ def nextURL():
+ """ as next url use newly created content url """
+
+ def cancelURL():
+ """ cancel url """
+
+ def nameAllowed():
+ """Return whether names can be input by the user."""
+
+
+class IPageletDisplayForm(IPagelet):
+ """ Display form mixin """
+
+
+class IPageletEditForm(IPageletForm):
+ """Edit form mixin for pagelet implementation."""
+
+ def nextURL():
+ """ as next url use newly created content url """
+
+
+class IAddButton(interface.Interface):
+ """ add button """
+
+
+class ISaveButton(interface.Interface):
+ """ save button """
+
+
+class ICancelButton(interface.Interface):
+ """ cancel button """
+
+
+class IFormErrorStatusMessage(IMessage):
+ """ form error status message """
Copied: z3ext.layoutform/tags/1.2.4/src/z3ext/layoutform/locales (from rev 92391, z3ext.layoutform/trunk/src/z3ext/layoutform/locales)
More information about the Checkins
mailing list