javaserverfaces-spec-public
  1. javaserverfaces-spec-public
  2. JAVASERVERFACES_SPEC_PUBLIC-1176

Separate implicit bean navigation from action method via additional outcome attribute

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Trivial Trivial
    • Resolution: Won't Fix
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Lifecycle
    • Labels:
      None

      Description

      The submit/command components: 'commandButton' and 'commandLink' use implicit navigation via their 'action' attribute and the returned String in the bean method that is invoked and referenced from the 'action' attribute.

      Why is the navigation outcome handled in the called method of the bean and not within the the view?
      Should the view not be as much separated from the logic as possible, especially if reusing code.

      Adding the 'outcome' attribute of the 'button' and 'link' components to the related command components 'commandButton' and 'commandLink' would resolve this issue.

      If the command component is invoked by the user the method of its 'action' attribute is called and navigates to the target defined in its 'outcome' attribute.

      <h:commandButon action="#

      {bean.method()}

      " outcome="/index.xhtml"/>

      Currently I used a workaround by adding my own outcome via an 'f:param' to my command, since for the few cases where I used bean-navigation the logic had to be reusable and not be bound to a specific view or application.

        Activity

        Hide
        Manfred Riem added a comment -

        Thank you for suggesting a new feature.

        Note that feature requests that change existing behavior or add to it
        need to be filed at the JAVASERVERFACES_SPEC_PUBLIC issue tracker.

        Can you file the issue there? Thank you!

        Show
        Manfred Riem added a comment - Thank you for suggesting a new feature. Note that feature requests that change existing behavior or add to it need to be filed at the JAVASERVERFACES_SPEC_PUBLIC issue tracker. Can you file the issue there? Thank you!
        Hide
        djmj added a comment -

        I got an email that it was moved automatically to public issue tracker.

        Is the closed status because of the wrong issue tracker?

        So should it not be reopened, or is the issue itself invalid?

        Show
        djmj added a comment - I got an email that it was moved automatically to public issue tracker. Is the closed status because of the wrong issue tracker? So should it not be reopened, or is the issue itself invalid?
        Hide
        Ed Burns added a comment -

        Re-open.

        Show
        Ed Burns added a comment - Re-open.
        Hide
        Ed Burns added a comment -

        Set priority to baseline ahead of JSF 2.3 triage. Priorities will be assigned accurately after this exercise.

        Show
        Ed Burns added a comment - Set priority to baseline ahead of JSF 2.3 triage. Priorities will be assigned accurately after this exercise.
        Hide
        Ed Burns added a comment -

        I hate to have to close this as WontFix after sitting on it for so long. However, the change you suggest is fundamentally incompatible with the design of JSF. If you feel strongly about it, please wait for the JSF 2.3 expert group to start discussions and bring it up on the users@javaserverfaces-spec-public mailing list. You can follow @jsf_spec on twitter for a notification for when the discussions start.

        Show
        Ed Burns added a comment - I hate to have to close this as WontFix after sitting on it for so long. However, the change you suggest is fundamentally incompatible with the design of JSF. If you feel strongly about it, please wait for the JSF 2.3 expert group to start discussions and bring it up on the users@javaserverfaces-spec-public mailing list. You can follow @jsf_spec on twitter for a notification for when the discussions start.
        Hide
        djmj added a comment -

        Thanks for working on it. If i do not forget it i will bring it up.

        Show
        djmj added a comment - Thanks for working on it. If i do not forget it i will bring it up.

          People

          • Assignee:
            Unassigned
            Reporter:
            djmj
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: