Browse files

Sub-guide pages

  • Loading branch information...
1 parent 487336e commit 17f99625447168a941fd3a9dbd9ea4b97017327b @jshirley jshirley committed Mar 27, 2010
Showing with 7 additions and 3 deletions.
  1. +0 −2 designs/plain/root/index.tt
  2. +7 −1 lib/StyleGuide/Controller/Root.pm
View
2 designs/plain/root/index.tt
@@ -1,2 +0,0 @@
-<h1>Plain!</h1>
-This is the plain theme.
View
8 lib/StyleGuide/Controller/Root.pm
@@ -40,7 +40,13 @@ sub index : Chained('setup') PathPart('') Args(0) {
my ( $self, $c ) = @_;
}
-sub guide : Chained('setup') Args(0) { }
+sub guide : Chained('setup') Args {
+ my ( $self, $c, $layout ) = @_;
+
+ if ( $c->path_to("root/guide", "$layout.tt") ) {
+ $c->stash->{template} = "guide/$layout.tt";
+ }
+}
sub switch : Chained('guide') Args(0) {
my ( $self, $c ) = @_;

0 comments on commit 17f9962

Please sign in to comment.