1 package TestApp::Controller::Action::Action;
4 use base 'TestApp::Controller::Action';
6 __PACKAGE__->config( actions => { action_action_five => { ActionClass => '+Catalyst::Action::TestBefore' } } );
8 sub action_action_one : Global : ActionClass('TestBefore') {
10 $c->res->header( 'X-Action', $c->stash->{test} );
11 $c->forward('TestApp::View::Dump::Request');
14 sub action_action_two : Global : ActionClass('TestAfter') {
15 my ( $self, $c ) = @_;
16 $c->stash->{after_message} = 'awesome';
17 $c->forward('TestApp::View::Dump::Request');
20 sub action_action_three : Global : ActionClass('+TestApp::Action::TestBefore') {
21 my ( $self, $c ) = @_;
22 $c->forward('TestApp::View::Dump::Request');
25 sub action_action_four : Global : MyAction('TestMyAction') {
26 my ( $self, $c ) = @_;
27 $c->forward('TestApp::View::Dump::Request');
30 sub action_action_five : Global {
31 my ( $self, $c ) = @_;
32 $c->res->header( 'X-Action', $c->stash->{test} );
33 $c->forward('TestApp::View::Dump::Request');
36 sub action_action_six : Global : ActionClass('~TestMyAction') {
37 my ( $self, $c ) = @_;
38 $c->forward('TestApp::View::Dump::Request');