0 Replies Latest reply on Dec 28, 2012 10:45 AM by 904010

    JSF event not raised in Portlet

    904010
      I have created 2 jsf portlets testFacesA and testFacesB

      testfacesA.jsp has commandbutton which invokes bean method as follows,
      <h:commandButton id="id1" action="#{Mybean.mymethod}" value="Click" />
      
      public String mymethod() {
                return "showResults";
           }
      And in faces-config.xml , I have the following,
       <navigation-rule>
            <from-view-id>/testfacesA.jsp</from-view-id>  
            <navigation-case> 
            <from-outcome>showResults</from-outcome> 
            <to-view-id>/testfacesB.jsp</to-view-id>
             </navigation-case>
           </navigation-rule>
      
      testFacesA.portlet
      ==================
      
      <netuix:portlet definitionLabel="testfacesA" title="Testfacesa">
              <netuix:titlebar/>
              <netuix:content>
                  <netuix:facesContent contentUri="/testfacesA.faces">
                      <netuix:facesEvents>
                          <netuix:facesEvent action="new value" eventName="showResults"/>
                      </netuix:facesEvents>
                  </netuix:facesContent>
              </netuix:content>
          </netuix:portlet>
      
      testFacesB.portlet
      ==================
      
       <netuix:portlet definitionLabel="testfacesB" title="Testfacesb">
              <netuix:handleFacesEvent eventLabel="handleFacesEvent1" eventName="showResults"
                  fromSelfInstanceOnly="false" onlyIfDisplayed="false" sourceDefinitionWildcard="any">
                  <netuix:invokeFacesAction action="/testfacesC.faces"/>
              </netuix:handleFacesEvent>
              <netuix:titlebar/>
              <netuix:content>
                  <netuix:facesContent contentUri="/testfacesB.faces"/>
              </netuix:content>
          </netuix:portlet>
      As you can see, I am trying to invoke /testfacesC.jsp in testFacesB portlet on clicking the command button.
      But its not invoking it and still stays in its content url (i.e testfacesB.jsp)

      Isnt the event been invoked and listened properly?