0 Replies Latest reply on Dec 13, 2008 12:56 AM by Sverker Abrahamsson

    Portlet with @DataModel and @Unwrap (or some other way of serving different lists to portlet instances)

    Sverker Abrahamsson Newbie

      I'm developing portlets which are to be implemented with Seam. However, as each portlet can exsist in several instances on one page there are some challenges.


      For example, I want to iterate over a list. I use h:dataTable which works fine. However, since I want to use s:link with a parameter to the action of which is the current item in the iteration I need to have the list exposed as a DataModel (according to user guide section 33.1.2).


      I thought the pattern with manager component described in section 4.8 was exactly what I needed, but when I do that the component which expose the DataModel doesn't even get loaded (as the DataModel has the same name as the manager component)


      I think I've tried all different variants, like using  but I just can't get @DataModel and @Unwrap to work together. If I use the normal DataModel/Factory pattern it works but then I don't have suffient control to make it work with several portlet instances.


      What would be the correct pattern to use to solve this problem. Is it possible to solve with Seam?