Hi Alex: I'm not sure about DBIC, but Rose::DBx::Garden, which creates its own database objects in like manner to the DBIC Loader, has a feature to insert code into the generated base class:
http://search.cpan.org/~karman/Rose-DBx-Garden-0.15/lib/Rose/DBx/Garden.pm#init_base_code I guess that won't work with DBIC, and I know you said that you're using DBIC. I just mention this for your (and others') future reference. I started out using DBIC also. But I figure as long as I'm automatically generating my database objects, I might as well have the same amount of effort generate my forms and Catalyst files as well. Adam On Mon, Jan 18, 2010 at 01:15:34PM +0300, Alex Povolotsky wrote: > Hello! > > I'm using Catalyst::Model::DBIC::Schema::Loader and autogenerate > Schema/*.pm files. > > I'd like to add some common functionality to some of them, and I'd > greatly prefer adding it in one place to copypasting code. > > How to I change base class for them? Of course that class should inherit > from DBIx::Class. I understand. > > Alex. > > > _______________________________________________ > List: [email protected] > Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst > Searchable archive: http://www.mail-archive.com/[email protected]/ > Dev site: http://dev.catalyst.perl.org/ _______________________________________________ List: [email protected] Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[email protected]/ Dev site: http://dev.catalyst.perl.org/
