summaryrefslogtreecommitdiff
path: root/misc/ruby-transaction-simple
diff options
context:
space:
mode:
authorabs <abs>2008-07-15 09:15:42 +0000
committerabs <abs>2008-07-15 09:15:42 +0000
commit906f8fb3f14dd0d0f93d4b7eea2e74fbd864356a (patch)
treec9bab4119659435643a6ab4a7a4e82e2bf9aa3f2 /misc/ruby-transaction-simple
parentefbb322db0d472914129b0f75ce14e70b1f14e9f (diff)
downloadpkgsrc-906f8fb3f14dd0d0f93d4b7eea2e74fbd864356a.tar.gz
Added www/p5-Catalyst-Component-ACCEPT_CONTEXT version 0.05
Models and Views don't usually have access to the request object, since they probably don't really need it. Sometimes, however, having the request context available outside of Controllers makes your application cleaner. If that's the case, just use this module as a base class: package MyApp::Model::Foobar; use base qw|Catalyst::Component::ACCEPT_CONTEXT Catalyst::Model|; Then, you'll be able to get the current request object from within your model: sub do_something { my $self = shift; print "The current URL is ". $self->context->req->uri->as_string; }
Diffstat (limited to 'misc/ruby-transaction-simple')
0 files changed, 0 insertions, 0 deletions