X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst%2FTraitFor%2FModel%2FDBIC%2FSchema%2FSchemaProxy.pm;fp=lib%2FCatalyst%2FTraitFor%2FModel%2FDBIC%2FSchema%2FSchemaProxy.pm;h=490671ac3fd2146e4906c6d208352bd5790fe55c;hb=81c30dcf4b206e920c84d182edd2088f4663e8a4;hp=bba6279da40779d82e87127e30525f3e385e0312;hpb=566a0bcace1f933a42a84e4b92782d78911acbba;p=catagits%2FCatalyst-Model-DBIC-Schema.git diff --git a/lib/Catalyst/TraitFor/Model/DBIC/Schema/SchemaProxy.pm b/lib/Catalyst/TraitFor/Model/DBIC/Schema/SchemaProxy.pm index bba6279..490671a 100644 --- a/lib/Catalyst/TraitFor/Model/DBIC/Schema/SchemaProxy.pm +++ b/lib/Catalyst/TraitFor/Model/DBIC/Schema/SchemaProxy.pm @@ -72,8 +72,16 @@ Or, if you prefer L: use MooseX::ClassAttribute; extends 'DBIx::Class::ResultSet'; + sub BUILDARGS { $_[2] } # important + class_has rs_config_key1 => (is => 'rw', default => 'default_value'); + ... + + __PACKAGE__->meta->make_immutable; + + 1; + In your catalyst config, use the generated Model name as the config key, e.g.: