Simon, the docs indicate that it is evaluated. (or perhaps are simply referring to the fact that the action trigger will evaluate it).
I'm not sure if I'd trust ActionlistenerImpl as truth on this one :-) On 2/27/07, Simon Kitching <[EMAIL PROTECTED]> wrote:
Yep, I apologise. The from-action quoted below is indeed valid. This is *not* actually an EL-expression, though; just compared literally with the actionListener property of the command component that was used to generate the outcome. See class ActionListenerImpl: it just stores the value of methodBinding.getExpressionString() before it invokes the methodBinding so that literal string can later be used to select the matching navigation rule using the from-action clause. Still seems weird - particularly when the t:aliasBean concept is factored in! As Mike says, it's probably a feature to avoid. For example it's pretty ugly for a rename of the action method to invalidate a navigation rule... Using from-view-id and from-outcome should be sufficient, and more stable. Regards, Simon Mike Kienenberger wrote: > Ok. I'm apparently wrong (and Simon with me for a change :-) > > http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JSFConfigure7.html > > It is legal, and it is the correct syntax. > > However, I don't understand the usage. from-outcome seems like it's > a "push" to a page. from-action appears to be a "pull" to a page. I > don't see how these can coexist. > > In any case, Mick, I don't think I'd recommend using from-action. > It's certainly not the norm, and I think it's going to double-process > your #{ userBackingBean.prepareForEdit} method, once when you trigger > the action with the button, and again when you navigate to the user > detail page. > > On 2/27/07, Mike Kienenberger <[EMAIL PROTECTED]> wrote: >> By the way, >> >> I don't think this is legal: >> >> <from-action>#{ userBackingBean.prepareForEdit}</from-action> >> >> If it is legal, I doubt that's the correct syntax. >> >> On 2/27/07, Mick Knutson <[EMAIL PROTECTED]> wrote: >> > Got it.... >> > >> > I had this for my faces-config setting: >> > >> > <navigation-rule> >> > >> > <from-view-id>/views/admin/users.xhtml</from-view-id> >> > <navigation-case> >> > <from-action>#{ >> userBackingBean.prepareForEdit}</from-action> >> > <from-outcome>EDIT</from-outcome> >> > >> > <to-view-id>/views/admin/updateUser.xhtml</to-view-id> >> > <redirect/> >> > </navigation-case> >> > </navigation-rule> >> > >> > >> > And you gave me this, so I added this: >> > >> > <navigation-rule> >> > <from-view-id>*</from-view-id> >> > <navigation-case> >> > <from-outcome>EDIT</from-outcome> >> > >> > <to-view-id>/views/admin/updateUser.xhtml</to-view-id> >> > </navigation-case> >> > </navigation-rule> >> > >> > >> > My question now is: does this mean that from any page, and any >> outcome, >> > EDIT will go to >> > <to-view-id>/views/admin/updateUser.xhtml</to-view-id> >> > >> > I just want a user EDIT to go to >> > <to-view-id>/views/admin/updateUser.xhtml</to-view-id>

