[CPS-users] How to sort items in sections, portlets, etc.?

curios-one curios-one at lycos.it
Thu Apr 13 13:36:04 CEST 2006


I'll never end to thank you for the helpful suggestions.
I'm new to the world of Python/Zope/CPS and I'm trying to learn by examples, looking at the CPS code.
CPS is really a great product :))
Thanks again,
C.

> Jean-Marc Orliaguet wrote:
>
> Hi, the best thing to do is to copy and paste code from 
> widget_portlet_navigation (navigation portlet) as you've started doing, 
> then remove all references to datastructures (ds options/datastructure 
> and other parameters that come the portlet's own schema). Then create a 
> custom portlet with the page template.
> 
> Since custom portlets have no parameters, all parameters available in 
> the navigation portlet will have to be hardcoded in the page template 
> instead. However the page template can also get information from the 
> current section, which is what it does in the code I sent.
> 
> then pass the information to:
> 
> items python: context.getFolderContents(....);
> 
> I think it's called 'sort_on'
> 
> that should do the trick.
> 
> the schema / layout that you should modify is the one of the "Section" 
> type (there is no need to change the portlet's schema / layout)
> 
> regards
> /JM

Lycos Mail: casella da 300 MB gratis per te con sicurezza antispam e antivirus -  http://mail.lycos.it


More information about the cps-users mailing list
More information about CPS: CPS project - CVS - API

Hosting: Nuxeo: Zope service provider


This list archive provided by Nuxeo, the leaders of open source ECM. Check out the Nuxeo 5 open source, standards-based ECM project.