Re: [Catalyst] PathPart help

2007-11-17 Thread Matt S Trout
On Fri, Nov 16, 2007 at 01:50:03PM -0500, Jason Kohles wrote: On Nov 16, 2007, at 11:11 AM, Christopher H. Laco wrote: Interesting twist. Reminds me of the RHOX stuff.. users/id/id users/name/name etc. Damnit. Now you have me thinking again. That setup is a great reason to keep REST

Re: [Catalyst] PathPart help

2007-11-16 Thread Matt S Trout
On Thu, Nov 15, 2007 at 11:47:34AM -0800, Les Fletcher wrote: I have question about setting up PathPart's and Chaining. I am trying to set something that has the following look: /namespace/ = This lists out a list of objects /namespace/id = displays detail information about the object with

Re: [Catalyst] PathPart help

2007-11-16 Thread Jonas Alves
On 11/16/07, Jason Kohles [EMAIL PROTECTED] wrote: On Nov 16, 2007, at 11:11 AM, Christopher H. Laco wrote: sub has_user : Chained('id|name|email') NoPathPart CaptureArgs(0) { } sub edit : Chained('has_user') PathPart('edit') Args(0) { } That NoPathPart you already have with an empty

[Catalyst] PathPart help

2007-11-15 Thread Les Fletcher
I have question about setting up PathPart's and Chaining. I am trying to set something that has the following look: /namespace/ = This lists out a list of objects /namespace/id = displays detail information about the object with the numeric id=id /namespace/id/edit = brings up a form to edit

Re: [Catalyst] PathPart help

2007-11-15 Thread Ashley Pond V
That is really cool and answers something I've wanted to do for a long time (let the user define the URI to customize a package). I have a question. Using the PathPrefix seems to work as advertised but it does not replace the default path. So, in a test I just did,

Re: [Catalyst] PathPart help

2007-11-15 Thread Christopher H. Laco
Ashley Pond V wrote: That is really cool and answers something I've wanted to do for a long time (let the user define the URI to customize a package). I have a question. Using the PathPrefix seems to work as advertised but it does not replace the default path. So, in a test I just did,

Re: [Catalyst] PathPart help

2007-11-15 Thread Christopher H. Laco
Les Fletcher wrote: I have question about setting up PathPart's and Chaining. I am trying to set something that has the following look: /namespace/ = This lists out a list of objects /namespace/id = displays detail information about the object with the numeric id=id /namespace/id/edit =

Re: [Catalyst] PathPart help

2007-11-15 Thread Les Fletcher
I am using __PACKAGE__-config-{ namespace } = 'foo'; sub obj_setup : PathPart('') CaptureArgs(1) {} sub create_setup : PathPart('') CaptureArgs(0) {} sub view : PathPart('') Chained('obj_setup') Args(0) {} sub edit : PathPart('') Chained('obj_setup') Args(0) {} sub create : PathPart('create')