Hmm.. When I wanted to accomplish similiar thing I used Form.validate() and Form.markComponentsInvalid instead of default form processing. The result was that the values were stored in FormComponents' invalidInput properties. Nevertheless, this really isn't the cleanest approach and seems quite hacky.
I really like the idea of getFormState and setFormState.

-Matej

Igor Vaynberg wrote:
Lol, sleep on it :) good night.
-Igor



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:wicket-develop-
[EMAIL PROTECTED] On Behalf Of Eelco Hillenius
Sent: Friday, September 09, 2005 1:32 PM
To: wicket-develop@lists.sourceforge.net
Subject: Re: [Wicket-develop] More button talk.

Ugh. I have my of my indecisive days. Too many arguments. I'm going to
bed now, read some more in my never shrinking stack of Philosophy
books. Sometimes it's easier to read that stuff than to make
long-lasting API choices.

Eelco


On 9/9/05, Igor Vaynberg <[EMAIL PROTECTED]> wrote:

This approach works in your case, but I don't think it belongs in a

general

framework. What if you have a date field or an integer field on your

form -

your approach only works if you have string inputs.

I had to do the same thing not long ago with a wizard's back button, I
wanted to capture the state of the form but not validate it when the

back

button is pressed, and later restore it when the page was needed again.

A

better solution is not to bind to a model (which is by def typesafe) but

to

keep a map of arguments and init the form components off that map. How

can

you bind "abc" to a date field?

I think a proper solution would be to build the support for the above
properly by giving the user an ability to capture and restore form state

off

http request parameters submitted.

Something like Map<String,String> getFormState() and
setFormState(Map<String,String>) where String-String are the http

request

param pairs.

-Igor



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:wicket-

develop-

[EMAIL PROTECTED] On Behalf Of Phil Kulak
Sent: Friday, September 09, 2005 1:02 PM
To: wicket-develop@lists.sourceforge.net
Subject: Re: [Wicket-develop] More button talk.

It's handy to do binding without validation when you want the user to
be able to leave a form to an intercept page before they are done
working with the form. My exact case is a form that contains a
user-selected photo. The best way to allow a user to select a photo is
to take them to another page so they can browse thumbnails, upload new
images, whatever, but it's not expected for them to loose the
information they've already entered or to be required to complete the
entire form before selected a certain piece.

And yes, I could just make photo selection a new page (which I will do
if this patch doesn't go through), but this seems more elegant to me.
Making every little step a new page in a wizard reeks of webapp to me,
and I like to try to get more of a desktop experiance.

Sure it's not something you going to run into every day, but if you
do, it's really nice to be able to control form behavior at this
level.

On 9/9/05, Eelco Hillenius <[EMAIL PROTECTED]> wrote:

You have a point of course. In this case, the Button's API is really
small though, and it has  these methods documented very well.

If you are -1 on this change, we could have a vote. So far, there
haven't been many reactions on this.

Eelco


On 9/9/05, Igor Vaynberg <[EMAIL PROTECTED]> wrote:

Yes, but validation and updating is not tied together. You can

still

call

the validation function by itself and it wont update the model. I

think

having two functions is too complex of a tradeoff for a usecase

that

no one

can come up with. Sometimes you have to go with simple vs

flexible.

Just my

two cents.
-Igor



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:wicket-

develop-

[EMAIL PROTECTED] On Behalf Of Eelco Hillenius
Sent: Friday, September 09, 2005 12:36 PM
To: wicket-develop@lists.sourceforge.net
Subject: Re: [Wicket-develop] More button talk.

Probably not, but there have been people that expressed they

would

like to have the option. I can't think of a really usefull case
myself. Though validating without updating is usefull.

Eelco


On 9/9/05, Igor Vaynberg <[EMAIL PROTECTED]> wrote:

Does it make sense to have update on and validation off? What

about type

conversion errors?

-Igor



-----Original Message-----
From: [EMAIL PROTECTED]

[mailto:wicket-

develop-

[EMAIL PROTECTED] On Behalf Of Eelco Hillenius
Sent: Friday, September 09, 2005 12:10 PM
To: wicket-develop@lists.sourceforge.net
Subject: Re: [Wicket-develop] More button talk.

What about triggerFormUpdate and triggerFormValidate ?

Eelco

On 9/9/05, Phil Kulak <[EMAIL PROTECTED]> wrote:

I'm not attached to that term. It's just another case of

using

what

other frameworks use, I guess. But you're right, we are

only

talking

about binding in one direction, so it may be wise to

change

it. I

like

"updateForm".

On 9/9/05, Eelco Hillenius <[EMAIL PROTECTED]>

wrote:

Checking it out now. One thing: the property is now

called

binding. I

think it could have a better name. I find binding

confusing

as the

binding is allways done for reading, and it doesn't make

clear

that

the thing you want to turn on or off is actually whether

the

form

model(s) are updated or not.

What about updateForm or applyInput or something?

Eelco


On 9/9/05, Phil Kulak <[EMAIL PROTECTED]> wrote:

Does anyone have a second to check this out? I would

just

like

to

know

if it's something that's going to be applied so I can

either

continue

to use it, or find some other way to do what I need.

Thanks!

On 9/7/05, Phil Kulak <[EMAIL PROTECTED]> wrote:

I just submitted the patch. I was able to make
setDefaultFormProcessing(boolean) a virtual field

that

just

sets

isBinding(boolean) and isValidating(boolean) at the

same

time.

One

problem I ran into though, was that the javadoc

didn't

actually

reflect how the processing actually occured. The

comments

suggested

that the form's onSubmit() was always called after

the

button,

but

that's not the case. I went ahead and duplicated

what

actually

happens

rather then what was commented and modified the

comment.

So,

long

story short, the processing should be exactly the

same

and the

API

didn't change, but now you can exactly specify if

binding or

validation happens.

On 9/6/05, Ralf Ebert <[EMAIL PROTECTED]> wrote:

Hi,

not sure about this. I would like to have a enum

like

thing

with

NOTHING, VALIDATION_ONLY and

VALIDATION_AND_UPDATE. I

also

like

the

way in which it is done right now, so I get

validation

and

model

updating automatically and if I don't want that, I

have to

call

the

methods myself.
I also think a (convenient) way is needed to

submit a

form

and

losing

no form data without validation and without model

updating.

This

is

needed for example if there is a file upload

button

within a

form.

You need to submit the form for uploading the file

but

that

doesn't

mean you want to update the model as well in every

case.

Regards,
Ralf


--------------------------------------------------

----

-

SF.Net email is Sponsored by the Better Software

Conference

&

EXPO

September 19-22, 2005 * San Francisco, CA *

Development

Lifecycle Practices

Agile & Plan-Driven Development * Managing

Projects &

Teams

*

Testing & QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net


https://lists.sourceforge.net/lists/listinfo/wicket-

develop


------------------------------------------------------

-

SF.Net email is Sponsored by the Better Software

Conference &

EXPO

September 19-22, 2005 * San Francisco, CA *

Development

Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects &

Teams *

Testing & QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-

develop


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software

Conference

& EXPO

September 19-22, 2005 * San Francisco, CA * Development

Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects &

Teams

*

Testing

& QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-

develop


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software

Conference &

EXPO

September 19-22, 2005 * San Francisco, CA * Development

Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects &

Teams *

Testing &

QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-

develop


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference

&

EXPO

September 19-22, 2005 * San Francisco, CA * Development

Lifecycle

Practices
Agile & Plan-Driven Development * Managing Projects & Teams

*

Testing

& QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop






-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference &

EXPO

September 19-22, 2005 * San Francisco, CA * Development

Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects & Teams *

Testing &

QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference &

EXPO

September 19-22, 2005 * San Francisco, CA * Development

Lifecycle

Practices
Agile & Plan-Driven Development * Managing Projects & Teams *

Testing & QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop






-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects & Teams *

Testing

& QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects & Teams *

Testing &

QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle
Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing

& QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop






-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle

Practices

Agile & Plan-Driven Development * Managing Projects & Teams * Testing &

QA

Security * Process Improvement & Measurement *

http://www.sqe.com/bsce5sf

_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle
Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop







-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop




-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to