-
1. Re: Seam-gen generating entities incorrect?
gavin.king Feb 18, 2008 2:25 PM (in response to boevink.boevinkp.xs4all.nl)This is exactly how it is supposed to work. It's using post-then-redirect. The post submits the forum, validates the text input, etc. (Which is why it validated the email address.) Then, the redirect includes the search parameters in the URL, so that the results page can be bookmarked.
You will see a lot of use of post-then-redirect in Seam examples and other good web applications that support bookmarking.
-
2. Re: Seam-gen generating entities incorrect?
boevink.boevinkp.xs4all.nl Feb 18, 2008 2:40 PM (in response to boevink.boevinkp.xs4all.nl)
Gavin King wrote on Feb 18, 2008 02:25 PM:
This is exactly how it is supposed to work. It's using post-then-redirect. The post submits the forum, validates the text input, etc. (Which is why it validated the email address.) Then, the redirect includes the search parameters in the URL, so that the results page can be bookmarked.
You will see a lot of use of post-then-redirect in Seam examples and other good web applications that support bookmarking.
Thanks for your reply.
I came to this conclusion since I'm struggling with the validation part and at first look I thought this second redirect caused my problems.....How and where is the text input validated on a post submit?
Since the email address is a search field, I don't want it to be validated!
I thought I had to explicitly use the validate or validateAll tag to fire hibernate validation.
Since I'm not using these tags I assumed that no validation should be triggered. -
3. Re: Seam-gen generating entities incorrect?
gavin.king Feb 18, 2008 3:49 PM (in response to boevink.boevinkp.xs4all.nl)
Since the email address is a search field, I don't want it to be validated! I thought I had to explicitly use the validate or validateAll tag to fire hibernate validation.The Hibernate Validator annotations are ignored during a JSF form submission unless you have an <s:validate/> or <s:validateAll/> in the form that is being submitted.
-
4. Re: Seam-gen generating entities incorrect?
boevink.boevinkp.xs4all.nl Feb 18, 2008 3:55 PM (in response to boevink.boevinkp.xs4all.nl)
Gavin King wrote on Feb 18, 2008 03:49 PM:
Since the email address is a search field, I don't want it to be validated! I thought I had to explicitly use the validate or validateAll tag to fire hibernate validation.
The Hibernate Validator annotations are ignored during a JSF form submission unless you have an <s:validate/> or <s:validateAll/> in the form that is being submitted.
I hoped so, but that does not work....
I'm using the seam-gen generated views. And have no <s:validate/> or <s:validateAll/> in my form.
My template does not have such a tag neither does my decoration template (display.xhtml).I'm using:
- jboss-seam-2.0.1.GA
- jboss-4.2.2.GA
- jdk1.5
-
5. Re: Seam-gen generating entities incorrect?
boevink.boevinkp.xs4all.nl Feb 20, 2008 8:37 AM (in response to boevink.boevinkp.xs4all.nl)Turned out to be an issue with pages.xml and page parameters:
JBSEAM-1587