You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Steven Wisener <sw...@gmail.com> on 2005/07/25 16:35:51 UTC
Null model for a PackageSelection component?
Using Tapestry 3.0.3, I'm trying to access the model property of a
PackageSelection component in a script specification, but the
PackageSelection is always returning null for its model. If I add a
couple of OGNL debug statements to my page:
Component is: <span jwcid="@Insert" value="ognl:components.select" /><br />
Model is: <span jwcid="@Insert" value="ognl:components.select.model" /><br />
I get:
Component is: org.apache.tapestry.form.PropertySelection$Enhance_50@d37bd8[MyPage/select]
Model is:
So the component is correct, but it's returning null for its model.
The component does render correctly, with all of the proper model
values. Anyone have any ideas about why the model is null when
accessed through the OGNL expression?
Thanks in advance,
--Steven
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
Re: Null model for a PackageSelection component?
Posted by Steven Wisener <sw...@gmail.com>.
Okay, I think I've figured it out. Since model is an "in" parameter,
it is only valid during the render of the component. Looks like I'll
have to access the model through an exposed property of the page
rather than trying to access it through the component in my script
file.
--Steven
On 7/25/05, Steven Wisener <sw...@gmail.com> wrote:
> Using Tapestry 3.0.3, I'm trying to access the model property of a
> PackageSelection component in a script specification, but the
> PackageSelection is always returning null for its model. If I add a
> couple of OGNL debug statements to my page:
>
> Component is: <span jwcid="@Insert" value="ognl:components.select" /><br />
> Model is: <span jwcid="@Insert" value="ognl:components.select.model" /><br />
>
> I get:
>
> Component is: org.apache.tapestry.form.PropertySelection$Enhance_50@d37bd8[MyPage/select]
> Model is:
>
> So the component is correct, but it's returning null for its model.
> The component does render correctly, with all of the proper model
> values. Anyone have any ideas about why the model is null when
> accessed through the OGNL expression?
>
> Thanks in advance,
>
> --Steven
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org