It turns out the length of the chaining is a variable in this equation.
In my Test Controller...
This gives "good" behavior:
sub base : Chained('/') PathPart('test') CaptureArgs(0) {}
sub another : Chained('base') PathPart('') CaptureArgs(0) {}
sub index : Chained('another') PathPart('') Args(0)
Hi Aristotle,
On 02/10/2015 02:39 AM, Aristotle Pagaltzis wrote:
Hi Trevor,
* Trevor Leffler [2015-02-07 00:00]:
Requests for non-extant paths fall through to Root->default(), which
gives the (undesired) default root view. I tried giving my top-level
controllers their own default() methods, b
Hi Trevor,
* Trevor Leffler [2015-02-07 00:00]:
> Requests for non-extant paths fall through to Root->default(), which
> gives the (undesired) default root view. I tried giving my top-level
> controllers their own default() methods, but as others have found [1],
> 'default() : Path' has precedenc
On 2/9/2015 1:59 AM, Dmitry L. wrote:
I'd rather split one application into several (admin app, survey app,
etc) and "join" its via middleware.
But you can try this:
In MyApp::Admin:
sub default : Path('admin') {
# or
# sub default : Chained(base) PathPart('') Path {
my ( $self, $c ) = @_;
On 9 February 2015 at 10:59, Dmitry L. wrote:
> I'd rather split one application into several (admin app, survey app,
> etc) and "join" its via middleware.
I wrote a blog article a few months ago:
http://blogs.perl.org/users/davewood/2014/08/splitting-a-catalyst-app-and-recombining-it-with-plackb
I'd rather split one application into several (admin app, survey app,
etc) and "join" its via middleware.
But you can try this:
In MyApp::Admin:
sub default : Path('admin') {
# or
# sub default : Chained(base) PathPart('') Path {
my ( $self, $c ) = @_;
$c->response->body( 'Page not found
Some of my top-level controllers represent different, er... "major
pieces" of my application. They have, among other things, different
default views, which are mainly just for configuring different page
wrappers. These controllers have this action pattern:
package MyApp::Admin;
sub base : Ch