8 Replies Latest reply on Jan 10, 2008 7:34 AM by Pete Muir

    [seam 2.0.0 CR3] redirect tag and "illegal navigation" messa

    Laurent Parcet Newbie

      Hy all.

      I work with seam 2.0.0 CR 3.

      I don't understand the "illegal navigation" message.

      I have a simple pageflow definition

       <start-page name="displayActivity" view-id="/SaisieActivite.xhtml" no-conversation-view-id="/index.xhtml">
       <transition to="realAsk" name="demandeConges"></transition>
       <transition name="directHoli" to="askHoliday"></transition>
       <page name="askHoliday" view-id="/Holiday.xhtml" no-conversation-view-id="/index.xhtml">
       <transition to="displayActivity" name="retourConges">
       <page name="listHoliday" view-id="/HolidayList.xhtml" no-conversation-view-id="/index.xhtml">
       <transition to="displayActivity" name="retourListeConges">
       <decision name="realAsk" expression="#{saisieActiviteList.charac}">
       <transition to="askHoliday" name="true"></transition>
       <transition name="false" to="listHoliday"></transition>

      and a simple page.xml
      <pages xmlns="http://jboss.com/products/seam/pages"
       xsi:schemaLocation="http://jboss.com/products/seam/pages http://jboss.com/products/seam/pages-2.0.xsd"
       <page view-id="/login.xhtml">
       <navigation from-action="#{identity.login}">
       <rule if="#{identity.loggedIn}">
       <redirect view-id="/SaisieActivite.xhtml"/>
       <page view-id="/SaisieActivite.xhtml" login-required="true">
       <begin-conversation join="true" pageflow="monPageflow"/>
       <page view-id="*">
       <navigation from-action="#{identity.logout}">
       <redirect view-id="/login.xhtml"></redirect>

      In the default menu.xhtml layout, there's a logout button, define as
      <s:link view="/login.xhtml" action="#{identity.logout}" value="Logout" rendered="#{identity.loggedIn}"/>

      The problem is if i put redirect tag in my pageflow, when i click on the logout button, i have an illegal navigation message on my page and i'm not logged out, but if there's no redirect tag in the pageflow, there's no problem to logout.

      Does anyone can explain where is the problem or where is my mistake?

      the problem is the same even i put no-conversation-view-id="/index.xhtml" or not.

      Does the logout navigation have to be describe in the pageflow also?
      And does the redirect tag absolutly required in the pageflow as it describe in the documentation page 107 § 7.2.3?