Commit | Line | Data |
---|---|---|
a5bd5d88 | 1 | package MyApp::Schema::Result::Cd; |
d88ecca6 | 2 | |
3 | use warnings; | |
4 | use strict; | |
5 | ||
6 | use base qw/DBIx::Class::Core/; | |
7 | ||
0c337847 | 8 | __PACKAGE__->table('cd'); |
d88ecca6 | 9 | |
113e8d16 | 10 | __PACKAGE__->add_columns(qw/ cdid artist title year /); |
d88ecca6 | 11 | |
0c337847 | 12 | __PACKAGE__->set_primary_key('cdid'); |
d88ecca6 | 13 | |
a5bd5d88 | 14 | __PACKAGE__->belongs_to('artist' => 'MyApp::Schema::Result::Artist'); |
15 | __PACKAGE__->has_many('tracks' => 'MyApp::Schema::Result::Track'); | |
0c337847 | 16 | |
17 | 1; |