DUHART Olivier wrote:
>
> Hello,
>
>  
>
> I ‘ve found a problem with an action I added to my nuxeo plugin : a 
> one click possibilty to change the current theme. For this the action
>
> Set the nxthemes.theme cookie with the wanted theme/page value. But it 
> appeared that when the cookie is set it is then impossible
>
> To display the dashboard page (and to open popup link too) . I guessed 
> that it is because they use their own layout page so the layout page
>
> Cookie value must collid with it and prevents the dashboard to display 
> properly (and so for popup link). But I don’t really understand
>
> Why nuxeo server (EP 5.1.4) can’t choose the proper layout page.  Is 
> there anything else that I missed ?
>
>  
>
> Thanks in advance,
>
>  
>
> Olivier
>
>   

Hi, the negotiation order is:

- URL parameter
- cookie
- view id <-> theme/page association
- local themes
- default theme

see in 
nuxeo-platform-webapp-core/src/main/resources/OSGI-INF/theme-contrib.xml

    <negotiation object="theme" strategy="nuxeo5">
      
<scheme>org.nuxeo.theme.jsf.negotiation.theme.RequestParameter</scheme>
      <scheme>org.nuxeo.theme.jsf.negotiation.theme.CookieValue</scheme>
      <scheme>org.nuxeo.theme.jsf.negotiation.theme.ViewId</scheme>
      <!-- local theme (specific to nuxeo5) -->
      <scheme>org.nuxeo.ecm.webapp.theme.negotiation.LocalTheme</scheme>
      <scheme>org.nuxeo.theme.jsf.negotiation.theme.DefaultTheme</scheme>
    </negotiation>


you could add your own negotiation plugin and have it override the view 
id information except for the dashboard view.


see also the following parameters, these can be changed:

      <negotiation>
        <strategy>nuxeo5</strategy>
        <default-engine>default</default-engine>
        <default-theme>default/default</default-theme>
        <default-perspective>default</default-perspective>
      </negotiation>


/JM

_______________________________________________
ECM mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm

Reply via email to