Version 2.008001
[catagits/Catalyst-Controller-DBIC-API.git] / t / lib / RestTest / Controller / API / REST / BoundArtist.pm
CommitLineData
d2739840 1package RestTest::Controller::API::REST::BoundArtist;
2use Moose;
3BEGIN { extends 'RestTest::Controller::API::REST::Artist'; }
4
5use namespace::autoclean;
6
7__PACKAGE__->config
8 ( action => { setup => { PathPart => 'bound_artist', Chained => '/api/rest/rest_base' } },
9 class => 'RestTestDB::Artist',
10 create_requires => ['name'],
11 create_allows => ['name'],
12 update_allows => ['name']
13 );
14
15# Arbitrary limit
16override list_munge_parameters => sub
17{
18 my ( $self, $c) = @_;
19 # Return the first one, regardless of arguments
20 $c->req->search_parameters->[0]->{'me.artistid'} = 1;
21};
22
231;