Re: Validating a PropertySelection

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: Validating a PropertySelection

Srinivasan Ranganathan
The built-in PropertySelection doesn't allow the selection to be
validated. Have a look at
http://equalitylearning.org/Tassel/app?service=direct/1/Browse/viewComponent&sp=SsrirangValidPropertySelect

- Srini

On 5/12/05, Random Tapestry User <[hidden email]> wrote:

> Hi all,
>
> I have a PropertySelection component that defines a US state selector.
> The first option in the selector is "--Select One--" with a code of "00"
> for it.
> I want to be able to use a validator that hooks into all the subsystems
> like "ValidField" does, so it will display the error message, and mark
> up the field label appropriately for errors.
>
> I can't understand how to do this.
> I tried adding a validator to the component, like this, but to no avail...
> Any help ?
>
> <component id="inputState" type="PropertySelection">
>     <binding name="displayName"
> expression="page.global.getL10N('state',page.locale)" />
>     <binding name="value" expression="page.stateCode" />
>     <binding name="model" expression="page.stateChoicesModel" />
>     <binding name="validator"
> expression="page.beans.singleSelectValidator"/>
> </component>
>
> Thanks all,
> tappapp
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Validating a PropertySelection

Random Tapestry User
Srinivasan,

Thank you. Saw that component some time ago, but status is marked as
"Complete, but quirky". As this will be in a very important application
and function, I cannot afford "quirky".
Unless I see something different, looks like it's up to me.

Thank you,
tappapp

Srinivasan Ranganathan wrote:

>The built-in PropertySelection doesn't allow the selection to be
>validated. Have a look at
>http://equalitylearning.org/Tassel/app?service=direct/1/Browse/viewComponent&sp=SsrirangValidPropertySelect
>
>- Srini
>
>On 5/12/05, Random Tapestry User <[hidden email]> wrote:
>  
>
>>Hi all,
>>
>>I have a PropertySelection component that defines a US state selector.
>>The first option in the selector is "--Select One--" with a code of "00"
>>for it.
>>I want to be able to use a validator that hooks into all the subsystems
>>like "ValidField" does, so it will display the error message, and mark
>>up the field label appropriately for errors.
>>
>>I can't understand how to do this.
>>I tried adding a validator to the component, like this, but to no avail...
>>Any help ?
>>
>><component id="inputState" type="PropertySelection">
>>    <binding name="displayName"
>>expression="page.global.getL10N('state',page.locale)" />
>>    <binding name="value" expression="page.stateCode" />
>>    <binding name="model" expression="page.stateChoicesModel" />
>>    <binding name="validator"
>>expression="page.beans.singleSelectValidator"/>
>></component>
>>
>>Thanks all,
>>tappapp
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: [hidden email]
>>For additional commands, e-mail: [hidden email]
>>
>>
>>    
>>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [hidden email]
>For additional commands, e-mail: [hidden email]
>
>
>  
>

Reply | Threaded
Open this post in threaded view
|

Re: Validating a PropertySelection

pferraro
FYI, Tapestry 4.0 will include both:
* an IPropertySelectionModel decorator for adding an initial label row
to your model (exists as of alpha-1).
* a "required" parameter

In the meantime, you can obtain the desired behavior in 3.0 by combining
the LabeledPropertySelectionModel class from the 4.0 codebase (it is
fully compatible with 3.0) with either the ValidPropertySelect component
from Tassel (if your comfortable) or by creating a custom
PropertySelection component that includes a "required" property (it
should be fairly trivial to do so).

Paul

Random Tapestry User wrote:

> Srinivasan,
>
> Thank you. Saw that component some time ago, but status is marked as
> "Complete, but quirky". As this will be in a very important
> application and function, I cannot afford "quirky".
> Unless I see something different, looks like it's up to me.
>
> Thank you,
> tappapp
>
> Srinivasan Ranganathan wrote:
>
>> The built-in PropertySelection doesn't allow the selection to be
>> validated. Have a look at
>> http://equalitylearning.org/Tassel/app?service=direct/1/Browse/viewComponent&sp=SsrirangValidPropertySelect 
>>
>>
>> - Srini
>>
>> On 5/12/05, Random Tapestry User <[hidden email]> wrote:
>>  
>>
>>> Hi all,
>>>
>>> I have a PropertySelection component that defines a US state selector.
>>> The first option in the selector is "--Select One--" with a code of
>>> "00"
>>> for it.
>>> I want to be able to use a validator that hooks into all the subsystems
>>> like "ValidField" does, so it will display the error message, and mark
>>> up the field label appropriately for errors.
>>>
>>> I can't understand how to do this.
>>> I tried adding a validator to the component, like this, but to no
>>> avail...
>>> Any help ?
>>>
>>> <component id="inputState" type="PropertySelection">
>>>    <binding name="displayName"
>>> expression="page.global.getL10N('state',page.locale)" />
>>>    <binding name="value" expression="page.stateCode" />
>>>    <binding name="model" expression="page.stateChoicesModel" />
>>>    <binding name="validator"
>>> expression="page.beans.singleSelectValidator"/>
>>> </component>
>>>
>>> Thanks all,
>>> tappapp
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: [hidden email]
>>> For additional commands, e-mail: [hidden email]
>>>
>>>
>>>  
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>
>>  
>>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Validating a PropertySelection

Srinivasan Ranganathan
In reply to this post by Random Tapestry User
We've been using it in production for nearly a year and haven't faced
any issues so far if that means anything. I have updated the status to
Complete.

On 5/12/05, Random Tapestry User <[hidden email]> wrote:

> Srinivasan,
>
> Thank you. Saw that component some time ago, but status is marked as
> "Complete, but quirky". As this will be in a very important application
> and function, I cannot afford "quirky".
> Unless I see something different, looks like it's up to me.
>
> Thank you,
> tappapp
>
> Srinivasan Ranganathan wrote:
>
> >The built-in PropertySelection doesn't allow the selection to be
> >validated. Have a look at
> >http://equalitylearning.org/Tassel/app?service=direct/1/Browse/viewComponent&sp=SsrirangValidPropertySelect
> >
> >- Srini
> >
> >On 5/12/05, Random Tapestry User <[hidden email]> wrote:
> >
> >
> >>Hi all,
> >>
> >>I have a PropertySelection component that defines a US state selector.
> >>The first option in the selector is "--Select One--" with a code of "00"
> >>for it.
> >>I want to be able to use a validator that hooks into all the subsystems
> >>like "ValidField" does, so it will display the error message, and mark
> >>up the field label appropriately for errors.
> >>
> >>I can't understand how to do this.
> >>I tried adding a validator to the component, like this, but to no avail...
> >>Any help ?
> >>
> >><component id="inputState" type="PropertySelection">
> >>    <binding name="displayName"
> >>expression="page.global.getL10N('state',page.locale)" />
> >>    <binding name="value" expression="page.stateCode" />
> >>    <binding name="model" expression="page.stateChoicesModel" />
> >>    <binding name="validator"
> >>expression="page.beans.singleSelectValidator"/>
> >></component>
> >>
> >>Thanks all,
> >>tappapp
> >>
> >>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: [hidden email]
> >>For additional commands, e-mail: [hidden email]
> >>
> >>
> >>
> >>
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [hidden email]
> >For additional commands, e-mail: [hidden email]
> >
> >
> >
> >
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

RE: Validating a PropertySelection

richard.hensley
In reply to this post by Srinivasan Ranganathan
We actually use a derivative of the "Complete, but quirky" version of the
ValidSelect. Quirky means examine it make sure the quirks are acceptable.
The only quirk I could find is that it requires a specific Validator. So, we
made a validator that was application specific and moved on.

-----Original Message-----
From: Random Tapestry User [mailto:[hidden email]]
Sent: Wednesday, May 11, 2005 7:37 PM
To: Tapestry users
Subject: Re: Validating a PropertySelection

Srinivasan,

Thank you. Saw that component some time ago, but status is marked as
"Complete, but quirky". As this will be in a very important application
and function, I cannot afford "quirky".
Unless I see something different, looks like it's up to me.

Thank you,
tappapp

Srinivasan Ranganathan wrote:

>The built-in PropertySelection doesn't allow the selection to be
>validated. Have a look at
>http://equalitylearning.org/Tassel/app?service=direct/1/Browse/viewComp
onent&sp=SsrirangValidPropertySelect

>
>- Srini
>
>On 5/12/05, Random Tapestry User <[hidden email]> wrote:
>  
>
>>Hi all,
>>
>>I have a PropertySelection component that defines a US state selector.
>>The first option in the selector is "--Select One--" with a code of
"00"
>>for it.
>>I want to be able to use a validator that hooks into all the
subsystems
>>like "ValidField" does, so it will display the error message, and mark
>>up the field label appropriately for errors.
>>
>>I can't understand how to do this.
>>I tried adding a validator to the component, like this, but to no
avail...

>>Any help ?
>>
>><component id="inputState" type="PropertySelection">
>>    <binding name="displayName"
>>expression="page.global.getL10N('state',page.locale)" />
>>    <binding name="value" expression="page.stateCode" />
>>    <binding name="model" expression="page.stateChoicesModel" />
>>    <binding name="validator"
>>expression="page.beans.singleSelectValidator"/>
>></component>
>>
>>Thanks all,
>>tappapp
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: [hidden email]
>>For additional commands, e-mail: [hidden email]
>>
>>
>>    
>>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: [hidden email]
>For additional commands, e-mail: [hidden email]
>
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]