DynaView @URLMapping Issue

Splash Forums PrettyFaces Users DynaView @URLMapping Issue

Tagged: 

This topic contains 3 replies, has 2 voices, and was last updated by  Lincoln Baxter III 6 years, 4 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #17929

    nacray
    Participant

    Hi,

    I’ve trying to find a solution for my problem for a while now and am hoping to find help here.

    I am trying to use different views for the same URLMapping id, depending on a different Bean like so:

    <


    Bean with Annotation


    >

    @URLMapping(id = “test”, pattern = “/test/#{ param1 : thisBean.param}/”, viewId = “#{otherBean.path}”)

    public class TestBean {}

    <


    Bean containing the Path’s


    >

    public class OtherBean {

    private String path;

    public String getPath(){

    return “test.xhtml”;

    }


    When linking to pretty:test the navigation case cannot be resolved – debugging shows OtherBean is not called at all, #{otherBean.path} is simply interpreted as a String.

    I am using PrettyFaces 3.2.1 & Mojarra 2.1.0, trying the PrettyFaces 3.3.0-SNAPSHOT did not help either.

    Is my concept wrong or am I doing something really stupid?

    Thanks,

    Nacray

    #20941

    DynaView is not supported for JSF Navigation or Outbound URL-rewriting at this time. We are working on an implementation to address some technical limitations, but until then, we recommend using separate URL-mappings for each view.

    Sorry :(

    Hopefully we will address this in the next release.

    #20942

    nacray
    Participant

    Hi Lincoln,

    thanks for your reply! I was hoping for a stupid mistake on my account, but oh well..

    DynaView via URLMapping would be splendid for implementing a straight forward switch for mobile/desktop views depending on the requesting device.

    Thanks again from Germany,

    Nacray

    #20943

    Hi,

    I have enhanced the dynaview feature and this should now work (but your method will be called every time JSF needs to resolve the DynaView)

    Please try the latest 3.3.0-SNAPSHOT and tell me if you have any success:

    https://github.com/ocpsoft/prettyfaces/wiki/Snapshots

    Thanks,

    Lincoln

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

Comments are closed.