You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Vinicius Carvalho <ja...@gmail.com> on 2006/08/08 05:26:06 UTC
Bypassing validation
Hello there! I was wondering if it is possible to bypass validation
for some listeners? I have a form with multiple listeners. I'd like to
have validation for some of them and others not. Is this possible?
Regards
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Bypassing validation
Posted by Vinicius Carvalho <ja...@gmail.com>.
Well, I had a real simple scenario, it's a master-detail page. I have
a form where user inputs new data, and I have three submit buttons:
New -> Sets the object to a new instance and goes back to the page
Save -> Saves the object on a db
Delete selection -> Removes objects selected in a table component that
lies below the input form
The only one that needs validation is the Save. The delete for
example, its used to get all the check boxes that were marked in order
to remove them, the user then, does not need to input any data, so
validation should be skipped.
Is it possible to avoid the validation? I didn't quite understand you
last post, hence I'm describing the scenario. Is there a jsf like
immediate trick?
Regards
On 8/8/06, Jesse Kuhnert <jk...@gmail.com> wrote:
> Validation doesn't really have any direct correlation to methods currently.
> (I don't think) Your listener method invocations are viewed as side effects
> of the components that contain them. (Like Submit or Form )
>
> If you really had to do it you might be able to figure something out via a
> combination of @Submit using parameters and a custom ValidationDelegate.
>
> I've also added a new "extension" point in tapestry 4.1 that allows you to
> add additional behaviour to components with contributed
> http://tapestry.apache.org/tapestry4.1/tapestry-framework/apidocs/org/apache/tapestry/services/ComponentRenderWorker.html
>
> classes.
>
> I didn't really create them for this purpose, but it might be able to do
> what you want.
>
> On 8/7/06, Vinicius Carvalho <ja...@gmail.com> wrote:
> >
> > Hello there! I was wondering if it is possible to bypass validation
> > for some listeners? I have a form with multiple listeners. I'd like to
> > have validation for some of them and others not. Is this possible?
> >
> > Regards
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> > For additional commands, e-mail: users-help@tapestry.apache.org
> >
> >
>
>
> --
> Jesse Kuhnert
> Tacos/Tapestry, team member/developer
>
> Open source based consulting work centered around
> dojo/tapestry/tacos/hivemind.
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: Bypassing validation
Posted by Jesse Kuhnert <jk...@gmail.com>.
Validation doesn't really have any direct correlation to methods currently.
(I don't think) Your listener method invocations are viewed as side effects
of the components that contain them. (Like Submit or Form )
If you really had to do it you might be able to figure something out via a
combination of @Submit using parameters and a custom ValidationDelegate.
I've also added a new "extension" point in tapestry 4.1 that allows you to
add additional behaviour to components with contributed
http://tapestry.apache.org/tapestry4.1/tapestry-framework/apidocs/org/apache/tapestry/services/ComponentRenderWorker.html
classes.
I didn't really create them for this purpose, but it might be able to do
what you want.
On 8/7/06, Vinicius Carvalho <ja...@gmail.com> wrote:
>
> Hello there! I was wondering if it is possible to bypass validation
> for some listeners? I have a form with multiple listeners. I'd like to
> have validation for some of them and others not. Is this possible?
>
> Regards
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>
--
Jesse Kuhnert
Tacos/Tapestry, team member/developer
Open source based consulting work centered around
dojo/tapestry/tacos/hivemind.