Actually, that's an interesting point. In general, I don't do crawlable
apps, so it's not an issue.

Keep the list out of your main form.  In the list, generate a column that
contains a form (one for each row) with the context set to the id of the
item to be deleted. Submit button now triggers your delete.

Same approach - different tool.



> -----Original Message-----
> From: Imants Firsts [mailto:[EMAIL PROTECTED]
> Sent: Sunday, April 06, 2008 6:25 PM
> To: Tapestry users
> Subject: RE: Mixin rendering a component
> 
> I consider ActionLinks wrong from the architectural
> perspective. You really should not send GET requests
> which deletes entities. Any crawler that crawls such a
> page would be devastating.
> 
> Quoting Jonathan Barker <[EMAIL PROTECTED]>:
> > Would it be acceptable to keep the list outside of
> the form, and use
> > ActionLinks with the id's of the items to be deleted?
> >
> > You could then have a conditional on your list
> component for whether or
> > not
> > the column with the ActionLink is displayed.
> >
> > Jonathan
> >
> >
> >
> > > -----Original Message-----
> > > From: Imants Firsts [mailto:[EMAIL PROTECTED]
> > > Sent: Sunday, April 06, 2008 4:30 PM
> > > To: Tapestry users
> > > Subject: Re: Mixin rendering a component
> > >
> > > I have an entity with one-to-many relationship to other
> > > entity - i.e. this entity contains a field of type
> > > List<Entity2>.
> > >
> > > I have a component which displays this list of objects.
> > > For normal screen I just use this component. But for
> > > edit screen for the main entity I would like to add
> > > some functionality to my list component - i.e. add a
> > > Delete button for each item, which would submit the
> > > enclosing form.
> > >
> > > I wanted to use Mixin, since I can't extend template
> > > and override some part of it like I can do with
> java class.
> > >
> > > I think the solution could be to for my edit component
> > > to extend the view component and completely override
> > > it's template, by duplicating it and adding the Delete
> > > buttons.
> > >
> > > Quoting Josh Canfield <[EMAIL PROTECTED]>:
> > > > I don't see any way to render a component from a
> > > mixin. I'm not sure
> > > > of a use case where you'd want to do that with a
> > > mixin. Can you tell
> > > > us what you are trying to do? Then maybe someone can
> > > offer another
> > > > solution.
> > > >
> > > > Josh
> > > >
> > > > On Fri, Apr 4, 2008 at 3:22 PM, Imants Firsts
> > > <[EMAIL PROTECTED]> wrote:
> > > > > Anyone has any idea? Maybe some other solution?
> > > > >
> > > > >
> > > > > Quoting Imants Firsts <[EMAIL PROTECTED]>:
> > > > > > Can mixin render a component, for example
> > > TextField? I
> > > > > > know that that it does not support templates
> and that
> > > > > > it can render the <input> tag directly.
> > > > > > But I would like the mixin to add a component to
> > > form,
> > > > > > so that it can be processed when the form is
> > > submitted.
> > > > > > Is something like that possible with mixins?
> > > > > >
> > > > > > Imants
> > > > >
> > > > >
> > > > >
> > >
> ---------------------------------------------------------------------
> > > > > To unsubscribe, e-mail:
> > > [EMAIL PROTECTED]
> > > > > For additional commands, e-mail:
> > > [EMAIL PROTECTED]
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > --
> > > > TheDailyTube.com. Sign up and get the best new videos
> > > on the internet
> > > > delivered fresh to your inbox.
> > > >
> > > >
> > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail:
> > > [EMAIL PROTECTED]
> > > > For additional commands, e-mail:
> > > [EMAIL PROTECTED]
> > >
> > >
> > >
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > > For additional commands, e-mail:
> [EMAIL PROTECTED]
> >
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to