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 => brings up a form to edit object with numeric
> id=<id>
> /namespace/create => brings up a form to create a new object
> 
> When the Chained actions are printed out everything looks fine, but when
> I goto "/namespace/create" it matches the "/namespace/<id>" view
> action.  Needless to say, there isn't an object with the numeric id of
> "create."
> 
> I would like for Catalyst to try and match the explicit PathPart before
> matching the wild card that is <id>.  Any thoughts on best ways to get
> around this?
> A couple of ways I thought of were:
> 
> I could make the view path be "/namespace/<id>/view," it seems a little
> weird, but would be acceptable if need be.
> 
> I could have an action that matches "/namespace/*" and then forward to
> the create action if "*" is "create" and to the view action other wise,
> but this could limit my ability to further chain from here.
> 
> Catalyst just might not match the paths in a way that is conducive to
> this, but just thought I'd throw this out there.
> 
> Les

http://use.perl.org/~LTjake/journal/31738

-=Chris

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[EMAIL PROTECTED]/
Dev site: http://dev.catalyst.perl.org/

Reply via email to