[Grok-dev] Re: Re: viewlets, pagelets and friends
Luis De la Parra
lparrab at gmx.net
Sun Aug 12 18:44:45 EDT 2007
Hi Darryl,
What would you think of changing this:
Darryl Cousins wrote:
[...]
> class Index(mars.view.PageletView):
> grok.name('index.html')
> grok.context(zope.app.folder.interfaces.IFolder)
> grok.require(path.to.mypermissions.View)
>
> class IndexTemplate(mars.template.TemplateFactory):
> grok.context(Index)
> grok.template('templates/index.pt')
>
to this:
class Index(mars.view.PageletView):
grok.name('index.html')
grok.context(zope.app.folder.interfaces.IFolder)
grok.require(path.to.mypermissions.View)
grok.template('templates/index.pt') # <<
or maybe
class Index(mars.view.PageletView):
grok.name('index.html')
grok.context(zope.app.folder.interfaces.IFolder)
grok.require(path.to.mypermissions.View)
grok.template('templates/index.pt') # <<"Content"-template
grok.layout('templates/page.pt') # <<"Layout"-template
?
cheers. luis
More information about the Grok-dev
mailing list