https://github.com/gotcha/archetypes.pfgexender
Extend archetypes schemas TTW with fields created in a PloneFormGen form
https://github.com/gotcha/archetypes.pfgexender
Last synced: 8 months ago
JSON representation
Extend archetypes schemas TTW with fields created in a PloneFormGen form
- Host: GitHub
- URL: https://github.com/gotcha/archetypes.pfgexender
- Owner: gotcha
- Created: 2011-11-16T10:57:42.000Z (almost 14 years ago)
- Default Branch: master
- Last Pushed: 2011-11-21T13:42:19.000Z (almost 14 years ago)
- Last Synced: 2025-01-19T17:13:34.983Z (10 months ago)
- Language: Python
- Homepage:
- Size: 147 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.txt
Awesome Lists containing this project
README
Introduction
============
This package provides infrastructure to extend Archetypes content types with
set of fields defined in PloneFormGen forms.
It is the result of the collaboration of a ``archetypes.schemaextender``, a
CMF Factory Type information (FTI) and a CMF tool that holds the PloneFormGen
forms.
When a form is added in the ``portal_pfgextender`` tool, it is marked as a
``IPFGExtenderForm`` and registered (by id) as a named utility.
The FTI holds a ``pfgform_id`` property that refers to one of the forms in the
tool. When the FTI creates a content instance, it sets the
``archetypes.pfgextender.interfaces.IPFGExtensible`` interface and stores the
``pfgform_id`` on the instance.
The ``archetypes.pfgextender.extender.Extender`` is registered for
``IPFGExtensible``. It queries the ``pfgform_id`` on the instance.
It looks up the corresponding form utility. It computes the additional
fields for the schema by turning PloneFormGen fields to Archetypes fields.