Olivier Grisel wrote:
> Hi list,
>
> I would like to build a new navigation portlet for CPS that let us
> choose the roots of the menu and not just the workspaces and sections
> trees. In my case I have 4 roots to display out of 5 potential roots
> (areas with different portal types and workflows that are all
> registered in the portal_trees tool). Thus I would like the new
> portlet to let us choose which root(s) we want to display in the
> portlet and in which order to display them.
>
> The idea would be to store the roots ids in a CPS String List Field of
> the portlets's schema and use a (Method-?) Vocabulary to feed a
> MultiSelect widget to let the user actually choose the roots. However,
> the MultiSelect Widget does not allow to select the order the roots.
> The user would have to change the order with the vocabularies
> management UI which is not very suitable either ...
>
> Anybody has an idea on how to implement such a portlet ?
>
> Best,
>
> Olivier
> __________
Hi!
the current implementation in CPSPortlets (Navigation Portlet) already
takes a 'root_uid' parameter ('sections', 'workspaces', etc.).
If I get it right you want to select the root from a dropdown menu and
let the portlet display the tree under the selected root? then basically
you need to replace the String widget which is currently used to select
the root uid ('root_uid') with another widget that let you choose a
string from a list (a vocabulary for instance).
however the schema field in the navigation portlet used to store the
information is still a String (unless several trees should be displayed
simultaneously ...).
/JM
_______________________________________________
cps-devel mailing list
http://lists.nuxeo.com/mailman/listinfo/cps-devel