redirect in post_delete

11 views
Skip to first unread message

Andronikos

unread,
Aug 1, 2011, 2:56:40 PM8/1/11
to turbo...@googlegroups.com
Hi,

When using the TG2.1 RestController and the post_delete interface,
it seems we can't redirect. post_delete insists on just returning to the
current url.

Has anyone else encountered this issue and is there workaround ?

Many Thanks,
Andronikos

Michael Pedersen

unread,
Aug 8, 2011, 9:40:25 PM8/8/11
to turbo...@googlegroups.com
Well, should it be changeable from the RestController? The normal behavior, after deleting, would be such a redirect to the current URL.

I suppose options would be to submit a patch and test case making the behavior optional, or subclassing RestController to make something new that works the way you wish it to.

Aside from that, based on what you've provided, I have to think things are working as they should.

--
You received this message because you are subscribed to the Google Groups "TurboGears" group.
To view this discussion on the web visit https://groups.google.com/d/msg/turbogears/-/xPg3KG8quRsJ.
To post to this group, send email to turbo...@googlegroups.com.
To unsubscribe from this group, send email to turbogears+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/turbogears?hl=en.



--
Michael J. Pedersen
My IM IDs: Jabber/pede...@icelus.tzo.com, AIM/pedermj022171
          Yahoo/pedermj2002, MSN/pederm...@hotmail.com
My LinkedIn Profile: http://www.linkedin.com/in/michaeljpedersen
Twitter: pedersentg

Andronikos

unread,
Aug 10, 2011, 7:37:25 AM8/10/11
to turbo...@googlegroups.com
I guess there are 2 things here,

- Not being able to redirect within a controller method, regardless of the method being post_delete or any other method. I would consider that a bug and I'm happy to provide a test case

- Redirecting to the current url after a delete - what happens in delete when the current url is the resource url ? If this is something permissible by REST, then it should be supported by the API I think.

Thanks for your efforts,
Andronikos

Reply all
Reply to author
Forward
0 new messages