[Grok-dev] Grok patterns for content types
optilude at gmx.net
Sun Jul 13 18:47:50 EDT 2008
I'm interested in experimenting with Grok-like patterns in Zope 2 and
Plone. In particular, I want to try to make it possible to build a
content type from a schema interface, a class for the persistent object,
a default view, and edit form and an add form.
What is the current "canonical" pattern for this in Grok? I have skimmed
some of the documentation, but I'd quite like to see an example or have
it spelled out, just so that I don't end up making incorrect assumptions.
How does Grok deal with add- and edit- forms? Is there a standard way to
do "configure-and-create" add forms without having to duplicate an edit
Finally, I'm curious about how Grok implements the logic that says a
view defined in the same module as a content type/model class defaults
to being a view for that content type, and a template with the same name
as the view ends up being the template for that view.
Is there some standard support for this in martian or grokcore.component?
Author of `Professional Plone Development`, a book for developers who
want to work with Plone. See http://martinaspeli.net/plone-book
More information about the Grok-dev