Le 10 mai 08 à 22:12, Martin Aspeli a écrit :
Gilles Lenfant wrote:
Hi,
I made a content type that uses an XML bunch. Parsing that XML
bunch makes a tree of volatile subobjects.
Till then this is pretty classical and easy and fast (thanks to
lxml).
To navigate across those subobjects, I could make a portlet and
tweak the URL traversal rules of that content type. But I need to
include the inner subobjects navigation into the standard
navigation portlet.
As the subobjects are far to be 1st class plone objects and not
indexed (and will never be indexed) I'm somehow stuck to achieve
this.
Cloning these subobjects to persitent classical content tree is not
an option for me.
(badly?) Grepping the source code involved in navigation logic
didn't show interfaces and adapters for such situation. Am I
missing something?
The navigation tree algorithm uses a INavtreeStrategy (looked up as
a multi-adapter by the navtree portlet) to make decisions about how
the navigation tree looks. It should be possible to use its
"decorate node" function to add new children that don't actually
exist. You may need to create a simple class that acts as a catalog
brain and stick this under the 'item' key of each node for this to
work.
Martin
Wow, I really need to cleanup my glasses ;)
Many thanks for this valuable enlightenment.
--
Gilles Lenfant
INGENIWEB (TM) - SAS 50000 Euros - RC B 438 725 632
Bureaux de la Colline
1 rue Royal
92210 Saint Cloud
web : www.ingeniweb.com - « les Services Web Ingénieux »
_______________________________________________
Product-Developers mailing list
[email protected]
http://lists.plone.org/mailman/listinfo/product-developers