Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
The moose likes Struts and the fly likes Struts 2 and modeldriven Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 2 and modeldriven" Watch "Struts 2 and modeldriven" New topic

Struts 2 and modeldriven

Luis Silveira

Joined: Aug 02, 2012
Posts: 4
Hi guys.
I would like to ask you about using modeldriven in struts 2 and excludeMethods to disable validation on a method.
I have a form with text fields from a modeldriven class, and when I am using excludeMethods, like that:

After click on submit button all data from the modeldriven class are lost.
There is some way to save modeldriven data and at same time exclude a method from validation?
Mohana Rao Sv
Ranch Hand

Joined: Aug 01, 2007
Posts: 485

You can use @skipValidation annotation to avoid validation for a particular action.

ocjp 6 — Feeding a person with food is a great thing in this world. Feeding the same person by transferring the knowledge is far more better thing. The reason is the amount of satisfaction which we get through food is of only one minute or two. But the satisfaction which we can get through the knowledge is of life long.
I agree. Here's the link:
subject: Struts 2 and modeldriven
It's not a secret anymore!