struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Graham" <dgraham1...@hotmail.com>
Subject Re: Validator validates too early (was RE: Validator won't validate single required field)
Date Fri, 24 Jan 2003 22:32:55 GMT
That was a poor suggestion and I highly doubt any Struts committer would 
give you the same advice ;-).

The naming convention in the example app wasn't intuitive for me so I 
usually do:

GetAccountFormAction maps to getAccountForm.do
SaveAccountFormAction maps to saveAccountForm.do

If I'm not dealing with a form (like your situation) I'll use something 
like:

GetAccountIndexPageAction => index.do
or
ViewAccountsAction => viewAccounts.do

There's no "right" way, just the way that makes sense for you.

David






>From: Wendy Smoak <Wendy.Smoak@asu.edu>
>Reply-To: "Struts Users Mailing List" <struts-user@jakarta.apache.org>
>To: 'Struts Users Mailing List' <struts-user@jakarta.apache.org>
>Subject: Validator validates too early (was RE: Validator won't validate 
>single required field)
>Date: Fri, 24 Jan 2003 15:06:09 -0700
>
> > You wouldn't want to hit the JSP first anyways ;-).
>
>It was suggested by another person here and I just wanted to rule it out in
>case it was your next suggestion. :)
>
> > I believe both of your
> > thoughts will work but I would try the separate action mapping idea 
>first.
>
>I did, and it works, but... BLECH!  I have to duplicate every single action
>mapping?!  And what am I supposed to call them?  someAction.do is so clean,
>and now I have to have someActionFirstTime.do?  Or perhaps I keep the first
>one with the clean name and call the others someAction2?
>
>I'm examining the struts-example with JSP's under WEB-INF, and I think the
>difference is my use of LookupDispatchAction vs. separate Actions for each
>thing: edit/save/create.
>
>This particular form isn't a CRUD form, it's a "Select the person you want
>to view read-only info on", so I can't quite make the createSomething,
>editSomething, updateSomething pattern fit.
>
>And it kind of defeats the purpose of LookupDispatchAction to have to map 
>it
>several times.
>
>I'm still pondering what to do about this.  I'm currently going with
>someAction.do and someActionNV.do (for No Validation).  Ideas appreciated!
>
>--
>Wendy Smoak
>Applications Systems Analyst, Sr.
>Arizona State University PA Information Resources Management


_________________________________________________________________
The new MSN 8: advanced junk mail protection and 2 months FREE*  
http://join.msn.com/?page=features/junkmail


--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message