diff options
author | groditi <groditi@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7> | 2009-07-08 22:54:19 +0000 |
---|---|---|
committer | groditi <groditi@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7> | 2009-07-08 22:54:19 +0000 |
commit | 7b5e71adcc00ae151a7908c2cddcd7323408efc7 (patch) | |
tree | 4d12552e007c79cb83eb728f2e435548272a3caf /lib/ComponentUI | |
parent | 65b88951ac01b54d83a9d2c5b27c276e31b839fd (diff) | |
download | reaction-7b5e71adcc00ae151a7908c2cddcd7323408efc7.tar.gz reaction-7b5e71adcc00ae151a7908c2cddcd7323408efc7.zip |
use more MooseX::Types and support actionattribute in Action vp to explicitly provide the URI to post to
Diffstat (limited to 'lib/ComponentUI')
-rw-r--r-- | lib/ComponentUI/Controller/TestModel/Bar.pm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/ComponentUI/Controller/TestModel/Bar.pm b/lib/ComponentUI/Controller/TestModel/Bar.pm index 4b592c0..4859b7d 100644 --- a/lib/ComponentUI/Controller/TestModel/Bar.pm +++ b/lib/ComponentUI/Controller/TestModel/Bar.pm @@ -23,4 +23,13 @@ sub get_collection { return $collection->where({}, { prefetch => 'foo' }); } +sub create :Chained('base') { + my $self = shift; + my ($c) = @_; + my $action_vp = $self->next::method(@_); + my $self_uri = $c->uri_for($self->action_for('create')); + $action_vp->action($self_uri); + return $action_vp; +} + 1; |