Hello,
I'm trying to switch the theme page with a new action, just like user_dashboard
does.
I created a theme spinoza:
<negotiation>
<strategy>nuxeo5</strategy>
<default-engine>default</default-engine>
<default-theme>spinoza/default</default-theme>
<default-perspective>default</default-perspective>
</negotiation>
and a page named espace_perso in it:
<view id="/espace_perso.xhtml">
<theme>spinoza/espace_perso</theme>
</view>
I registered the navigation case:
<extension target="faces-config#NAVIGATION">
<navigation-case>
<from-outcome>espace_perso</from-outcome>
<to-view-id>/espace_perso.xhtml</to-view-id>
<redirect />
</navigation-case>
</extension>
I registered the action in the ActionService:
<action id="espace_perso" link="espace_perso"
enabled="true" label="spinoza.label.menu.priv.fold"
icon="/img/button/SPINOZA-Bandeau-btn-DossierPerso.jpg" order="0">
<category>SPINOZA_BANDEAU_MENU</category>
</action>
And in my xhtml template, I display it like the dashboard:
<h:form>
<nxu:methodResult name="actions"
value="#{webActions.getActionsList('SPINOZA_BANDEAU_MENU')}">
<nxu:dataList var="action" value="#{actions}">
<nxh:commandLink action="#{action.getLink()}">
<h:graphicImage value="#{action.icon}" />
</nxh:commandLink>
</nxu:dataList>
</nxu:methodResult>
</h:form>
I also created a espace_perso.xhtml file in Nuxeo.war, that is basically a copy
of user_dashboard.xhtml.
But for some reason, when I click on the action, the server does not redirect
me and I get to browse /nuxeo/view_documents.faces
The weird thing is that if I replace in the action definition
link="espace_perso" with link="/espace_perso", I get redirected to
/nuxeo/nxdoc/default/xxxxxx//espace_perso, which leads to a 404, but is the
expected behaviour. That means it is the "espace_perso" url that creates a
problem.
Did I forget something in declaring my action or theme ?
What is the difference between what I did and the user_dashboard stuff ?
Thanks for your help
Sylvain
_______________________________________________
ECM mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm