Hi,
> FYI, you should not use tr:setActionListener if you are on JSF 1.2,
I'm on JSF 1.2 and tr:setActionListener works well.
If I shouldn't use it, how can I get the row object of a parent table inside
a subtable?
Must I step through the component hierarchy?
--
Kind regards,
Mathias
> ignore this comment if you are still on 1.1.
>
> -Andrew
>
> On Tue, Apr 15, 2008 at 4:47 PM, Andrew Robinson
> <[EMAIL PROTECTED]> wrote:
> > Response inline
> >
> >
> > > > Use action instead of actionListener? Actions are
> always fired last.
> > >
> > > Yes, I know. But if I use actions, PPR won't work. The
> whole page is
> > > refreshed, regardless of the action outcome. But I'd
> like to use PPR.
> >
> > Returning null is the correct way to ensure that the navigation
> > handler does not change the current view root. I have used it with
> > Trinidad without issues, so I know it works. If the action
> is non-null
> > it should only navigate if there is a match. Do you have
> any "catch"
> > all navigation rules (where the outcome or action are not
> specified)?
> >
> >
> > > I found a solution by myself. Instead of declaring the
> actionListener as a
> > > commandLink parameter, I'v implemented ActionListener
> in the backing bean
> > > and used f:actionListener after tr:setActionListener.
> Now the execution
> > > order is correct.
> > >
> > > <tr:commandLink text="Neu" partialSubmit="true"
> immediate="true">
> > > <tr:setActionListener from="${entity}"
> to="#{pageFlowScope.finding}"
> > > />
> > > <f:actionListener binding="#{backingBean}" />
> > > </tr:commandLink>
> > >
> > > IMHO: setActionListener should be executed before any
> UIComponent
> > > actionListener. Shall I open a JIRA?
> >
> > No, the action listeners should be invoked in the order
> that they are
> > added to a component. A setActionListener should not get
> preferential
> > treatment. If you need listeners to be invoked in a specific order,
> > you need to make sure they are added in that order. And
> even then, the
> > JavaDoc of UIComponent does not guarantee that the
> listeners will be
> > returned in any specific order:
> >
> http://java.sun.com/javaee/javaserverfaces/1.2/docs/api/javax/
> faces/component/UIComponent.html#getFacesListeners(java.lang.Class)
> >
> > Maybe the spec. says something?
> >
> >
> >
> >
> > >
> > > --
> > > Kind regards,
> > > Mathias
> > >
> > >
> > >
> > > >
> > > > On Tue, Apr 15, 2008 at 3:51 PM, Mathias Walter
> > > > <[EMAIL PROTECTED]> wrote:
> > > > > Hi,
> > > > >
> > > > > is it possible to use partialSubmit without an
> > > > actionListener and only with
> > > > > an action on a tr:commandLink? I tried it, but the whole
> > > > page is refreshed
> > > > > not only the relevant part.
> > > > >
> > > > > I'd like to use actionListener, but unfortunatelly a
> > > > tr:setActionListener
> > > > > will be executed after actionListener. In such case, it's
> > > > impossibel to set
> > > > > a pageFlowScope variable with setActionListener.
> > > > >
> > > > > Example:
> > > > >
> > > > > <tr:commandLink
> actionListener="#{backingBean.add}" text="Neu"
> > > > > partialSubmit="true" immediate="true">
> > > > > <tr:setActionListener from="${entity}"
> > > > to="#{pageFlowScope.data}" />
> > > > > </tr:commandLink>
> > > > >
> > > > > This does not work, because backingBean.add is
> fired before the
> > > > > setActionListener.
> > > > >
> > > > > --
> > > > > Kind regards,
> > > > > Mathias
> > > > >
> > > > >
> > >
> > >
> >