[Catalyst-commits] r7513 -
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD
zby at dev.catalyst.perl.org
zby at dev.catalyst.perl.org
Mon Mar 17 21:24:18 GMT 2008
Author: zby
Date: 2008-03-17 21:24:17 +0000 (Mon, 17 Mar 2008)
New Revision: 7513
Modified:
CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
Log:
we need to pass moniker to the model_adapter
Modified: CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm
===================================================================
--- CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2008-03-17 20:04:58 UTC (rev 7512)
+++ CatalystX-CRUD/CatalystX-CRUD/trunk/lib/CatalystX/CRUD/Controller.pm 2008-03-17 21:24:17 UTC (rev 7513)
@@ -30,6 +30,7 @@
default_template => 'path/to/foo/edit.tt',
model_name => 'Foo',
model_adapter => 'FooAdapter', # optional
+ moniker => 'SomeTable', # optional
primary_key => 'id',
view_on_single_result => 0,
page_size => 50,
@@ -353,7 +354,7 @@
Catalyst::Utils->ensure_class_loaded(
$self->config->{model_adapter} );
$self->model_adapter( $self->config->{model_adapter}
- ->new( { model_name => $self->config->{model_name} } ) );
+ ->new( { model_name => $self->config->{model_name}, moniker => $self->config->{moniker} } ) );
}
return $self;
}
More information about the Catalyst-commits
mailing list