You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Renzo Tomaselli <re...@tecnotp.it> on 2007/06/13 21:12:43 UTC

[Trinidad] PPR scope and external fields

Hi, I would appreciate a bit of enlightening about the overall handling 
of form fields when PPR enters this game.
Assume we have a form containing a PPR component (say a tr: table) and a 
hidden field H external to this component, although within the form.
I noticed (from debugging) than whenever a PPR operation is on its way 
(say a table paging), the hidden field is set to the involved bean 
property (updating model),  retrieved from the bean (render view) but 
its client DOM value is not refreshed - I guess because it is out of 
involved PPR component.
Indeed next PPR operation will send again the same value to the bean, 
forgetting about what's returned.
Is that correct or should it behave in a different way ?

-- Renzo



Re: [Trinidad] PPR scope and external fields

Posted by Adam Winer <aw...@gmail.com>.
The only fields that are refreshed are those that are part of the
PPR target, exactly.  Arbitrary components can be added
to PPR with RequestContext.addPartialTarget(), so you could
(for instance) have a PhaseListener that made sure that
certain bits of content did get replaced.  There's some skankier
hacks for getting bits of DOM that aren't a full component
to be rendered.

-- Adam


On 6/13/07, Renzo Tomaselli <re...@tecnotp.it> wrote:
> Hi, I would appreciate a bit of enlightening about the overall handling
> of form fields when PPR enters this game.
> Assume we have a form containing a PPR component (say a tr: table) and a
> hidden field H external to this component, although within the form.
> I noticed (from debugging) than whenever a PPR operation is on its way
> (say a table paging), the hidden field is set to the involved bean
> property (updating model),  retrieved from the bean (render view) but
> its client DOM value is not refreshed - I guess because it is out of
> involved PPR component.
> Indeed next PPR operation will send again the same value to the bean,
> forgetting about what's returned.
> Is that correct or should it behave in a different way ?
>
> -- Renzo
>
>
>