Rusty,
The validation error report page appears when the _sourcePage
parameter/attribute is not included in the request. Basically,
when a validation error is thrown/recognized by stripes,
getContext().getSourcePageResolution() is called to redirect the error
messages to the calling page. if you use <s:form> , the _sourcePage
parameter is is inlcuded. If you use <s:link>, you can add the _sourcePage
parameter by setting the addSourcePage to the link tag. eg <s:link
addSourcePage="true"/>. I hope that helps.
Thanks,
Osagie Uwaifo
On Tue, Oct 6, 2009 at 4:02 PM, <[email protected]
> wrote:
> Send Stripes-users mailing list submissions to
> [email protected]
>
> To subscribe or unsubscribe via the World Wide Web, visit
> https://lists.sourceforge.net/lists/listinfo/stripes-users
> or, via email, send a message with subject or body 'help' to
> [email protected]
>
> You can reach the person managing the list at
> [email protected]
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Stripes-users digest..."
>
>
> Today's Topics:
>
> 1. Correct Pattern for CRUD when ID field is complex (Danny C)
> 2. Re: Correct Pattern for CRUD when ID field is complex (Danny C)
> 3. Re: Stripersist entity scan (Tom Coleman)
> 4. Re: Stripersist entity scan (Aaron Porter)
> 5. cause of "Stripes validation error report" page appearing?
> (Rusty Wright)
> 6. Re: Multiple URL bindings per action (Ray Vanderborght)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 5 Oct 2009 10:16:51 -0700 (PDT)
> From: Danny C <[email protected]>
> Subject: [Stripes-users] Correct Pattern for CRUD when ID field is
> complex
> To: [email protected]
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=us-ascii
>
>
> Team,
>
> I'm sure this has been solved before - repeatedly, but I can't seem to find
> what I'm looking for.
>
> I'm using Stripes 1.5 with Apache Cayenne 3.0M6.
>
> Creation of new object is a snap, I can simply pass the object to Stripes
> and it does a perfect job populating the fields so that Cayenne can
> persist.
> My issue is with Updating existing data.
>
> I'm attempting (unless there is a better pattern) to reuse the same Bean
> with a different event for "modify". The link is generated with an:
> <s:link beanclass="fooBean" event="modify"><s:param name="user.pkId"
> value="${fooId}"/></s:link>
> The end results looks correct.
>
> My first question is: When and Where should I "populate/inflate" the object
> to be edited? I think I've simply confused myself by reading a little too
> much and mixing patterns of others...
>
> I've tried using inflating the object using a @Before annotation:
> @Before(stages = { LifecycleStage.BindingAndValidation })
> public void fillData()
> {
> // time to inflate the object for the user
> }
> BUT -- at that stage (err - I think) I don't seem to have the anything from
> the request? I would expect (and be wrong) that my user object would be
> empty EXCEPT for the pkId attribute. The entire object is empty...
> Interesting enough if I get the parameter from the request directly it
> works, but this seems so hacky:
>
> int thisPkId = getUser().getPkId(); // does not work!
> String strUid = getContext().getRequest().getParameter("user.pkId"); //
> this
> works...
>
> So - let me cut to the chase..
>
> What is "A" recommend pattern to inflate an object based on a parameter
> passed in? If I attempt to re-load the object before I call "update" I
> overwrite the request params...
>
> Thanks all!
>
>
> The "ID" parameter in Cayenne is
> --
> View this message in context:
> http://www.nabble.com/Correct-Pattern-for-CRUD-when-ID-field-is-complex-tp25754729p25754729.html
> Sent from the stripes-users mailing list archive at Nabble.com.
>
>
>
>
> ------------------------------
>
> Message: 2
> Date: Mon, 5 Oct 2009 10:20:36 -0700 (PDT)
> From: Danny C <[email protected]>
> Subject: Re: [Stripes-users] Correct Pattern for CRUD when ID field is
> complex
> To: [email protected]
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=us-ascii
>
>
>
>
> Danny C wrote:
> >
> > The "ID" parameter in Cayenne is
> >
>
> I seem to have cut myself off.
>
> Related, but somewhat independent. The "Id" field in Cayenne is not a
> primitive object, so I can't figure out how to use it effectively as one.
> :)
>
> Ideally, I would inflate objects by passing in the id to the modify form.
> Right now I have a sister variable which Cayenne doesnt know about (called
> pkId) which I'm using. It works, but also seem hackish.
>
> Thoughts?
> --
> View this message in context:
> http://www.nabble.com/Correct-Pattern-for-CRUD-when-ID-field-is-complex-tp25754729p25754732.html
> Sent from the stripes-users mailing list archive at Nabble.com.
>
>
>
>
> ------------------------------
>
> Message: 3
> Date: Tue, 6 Oct 2009 13:56:19 -0400
> From: Tom Coleman <[email protected]>
> Subject: Re: [Stripes-users] Stripersist entity scan
> To: Stripes Users List <[email protected]>
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=US-ASCII; format=flowed
>
>
> On Sep 18, 2009, at 4:34 PM, Aaron Porter wrote:
>
> > I'd be more than happy to update Stripersist with your changes.
>
>
> Did you get around to updating the Stripersist code?
>
> If so, I'm guessing I'll have to grab it using CVS or Subversion?
>
> Thanks!
>
>
>
>
> ------------------------------
>
> Message: 4
> Date: Tue, 06 Oct 2009 12:23:04 -0700
> From: Aaron Porter <[email protected]>
> Subject: Re: [Stripes-users] Stripersist entity scan
> To: Stripes Users List <[email protected]>
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Tom,
> I didn't get the updates from Allen so I haven't checked them in yet.
> I'll be happy to let you know when they're in.
>
> Aaron
>
> Tom Coleman wrote:
> > On Sep 18, 2009, at 4:34 PM, Aaron Porter wrote:
> >
> >
> >> I'd be more than happy to update Stripersist with your changes.
> >>
> >
> >
> > Did you get around to updating the Stripersist code?
> >
> > If so, I'm guessing I'll have to grab it using CVS or Subversion?
> >
> > Thanks!
> >
> >
> >
> ------------------------------------------------------------------------------
> > Come build with us! The BlackBerry® Developer Conference in SF, CA
> > is the only developer event you need to attend this year. Jumpstart your
> > developing skills, take BlackBerry mobile applications to market and stay
> > ahead of the curve. Join us from November 9-12, 2009. Register
> now!
> > http://p.sf.net/sfu/devconf
> > _______________________________________________
> > Stripes-users mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/stripes-users
> >
> >
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
> Message: 5
> Date: Tue, 06 Oct 2009 13:12:24 -0700
> From: Rusty Wright <[email protected]>
> Subject: [Stripes-users] cause of "Stripes validation error report"
> page appearing?
> To: Stripes Users List <[email protected]>
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> What makes this page display? Sometimes I get it, other times I get the
> expected page with the validation error on the page in the correct place.
>
> (I'm porting a sample stripes app to Google App Engine.)
>
>
> Stripes validation error report
>
> Here's how it is. Someone (quite possibly the Stripes Dispatcher) needed to
> get the source page resolution. But no source page was supplied in the
> request, and unless you override ActionBeanContext.getSourcePageResolution()
> you're going to need that value. When you use a tag a hidden field called
> '_sourcePage' is included. If you write your own forms or links that could
> generate validation errors, you must include a value for this parameter.
> This can be done by calling request.getServletPath().
>
> Validation errors
>
> Please fix the following errors:
> Desired Date Am Pm is a required field
>
>
>
> ------------------------------
>
> Message: 6
> Date: Tue, 6 Oct 2009 13:34:23 -0700
> From: Ray Vanderborght <[email protected]>
> Subject: Re: [Stripes-users] Multiple URL bindings per action
> To: Stripes Users List <[email protected]>
> Message-ID:
> <[email protected]>
> Content-Type: text/plain; charset="iso-8859-1"
>
> +1. I've had to subclass actions before to do this and it feels hacky.
> Multiple bindings would be a nice feature.
>
> On Mon, Oct 5, 2009 at 7:42 AM, Nathan Maves <[email protected]>
> wrote:
>
> > I figured that we could have a "default" option on the bindings. If one
> > was not defined as that it would just be the first binding in the group
> of
> > bindings.
> > The way I got around my original problem was to extend my original class
> > and give it a binding.
> >
> >
> > On Sun, Oct 4, 2009 at 11:26 PM, Levi Hoogenberg <
> [email protected]
> > > wrote:
> >
> >> There are a couple of Stripes classes that assume a one on one
> >> relationship between action beans and URL bindings. One example is the
> URL
> >> binding factory. This is a design choice that's probably hard to change
> -
> >> one implication of allowing multiple URL bindings per action bean is
> >> ambiguity when creating an URL for an action bean. How would you handle
> this
> >> case?
> >>
> >> On Mon, Oct 5, 2009 at 5:18 AM, Nathan Maves <[email protected]
> >wrote:
> >>
> >>> Any thoughts on implementing this?
> >>> Something like
> >>>
> >>> @UrlBindings({
> >>> @UrlBinding("/one"),
> >>> @UrlBinding("/two")
> >>> })
> >>>
> >>>
> >>>
> ------------------------------------------------------------------------------
> >>> Come build with us! The BlackBerry® Developer Conference in SF, CA
> >>> is the only developer event you need to attend this year. Jumpstart
> your
> >>> developing skills, take BlackBerry mobile applications to market and
> stay
> >>> ahead of the curve. Join us from November 9-12, 2009. Register
> >>> now!
> >>> http://p.sf.net/sfu/devconf
> >>> _______________________________________________
> >>> Stripes-users mailing list
> >>> [email protected]
> >>> https://lists.sourceforge.net/lists/listinfo/stripes-users
> >>>
> >>>
> >>
> >>
> >>
> ------------------------------------------------------------------------------
> >> Come build with us! The BlackBerry® Developer Conference in SF, CA
> >> is the only developer event you need to attend this year. Jumpstart your
> >> developing skills, take BlackBerry mobile applications to market and
> stay
> >> ahead of the curve. Join us from November 9-12, 2009. Register
> >> now!
> >> http://p.sf.net/sfu/devconf
> >> _______________________________________________
> >> Stripes-users mailing list
> >> [email protected]
> >> https://lists.sourceforge.net/lists/listinfo/stripes-users
> >>
> >>
> >
> >
> >
> ------------------------------------------------------------------------------
> > Come build with us! The BlackBerry® Developer Conference in SF, CA
> > is the only developer event you need to attend this year. Jumpstart your
> > developing skills, take BlackBerry mobile applications to market and stay
> > ahead of the curve. Join us from November 9-12, 2009. Register
> now!
> > http://p.sf.net/sfu/devconf
> > _______________________________________________
> > Stripes-users mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/stripes-users
> >
> >
>
>
> --
> http://www.bartendr.com
> -------------- next part --------------
> An HTML attachment was scrubbed...
>
> ------------------------------
>
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
>
> ------------------------------
>
> _______________________________________________
> Stripes-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/stripes-users
>
>
> End of Stripes-users Digest, Vol 41, Issue 5
> ********************************************
>
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Stripes-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-users