use Apache::MVC;
use base 'Apache::MVC';
sub handler { Apache::MVC::handler("BeerDB", @_) }
-use Class::DBI::Loader::Relationship;
BeerDB->set_database("dbi:mysql:beerdb");
BeerDB->config->{template_root} = "/opt/beer";
BeerDB->config->{uri_base} = "http://neo.trinity-house.org.uk/beerdb/";
-BeerDB::Brewery->columns(Stringify => qw/name/);
-
-BeerDB->config->{loader}->relationship( "a brewery produces beers" );
-BeerDB->config->{loader}->relationship( "a pub has beers on handpumps");
+use Class::DBI::Loader::Relationship;
+BeerDB->config->{loader}->relationship($_) for (
+ "a brewery produces beers",
+ "a beer has a style",
+ "a pub has beers on handpumps");
1;