| 1 | package Bracket::Schema::Result::Region; | ||
| 2 | |||
| 3 | # Created by DBIx::Class::Schema::Loader | ||
| 4 | # DO NOT MODIFY THE FIRST PART OF THIS FILE | ||
| 5 | |||
| 6 | 4 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | 4 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | |||
| 9 | 4 | ▶ | use base 'DBIx::Class::Core'; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 10 | |||
| 11 | |||
| 12 | =head1 NAME | ||
| 13 | |||
| 14 | Bracket::Schema::Result::Region | ||
| 15 | |||
| 16 | =cut | ||
| 17 | |||
| 18 | 4 | __PACKAGE__->table("region"); | |
| 19 | |||
| 20 | =head1 ACCESSORS | ||
| 21 | |||
| 22 | =head2 id | ||
| 23 | |||
| 24 | data_type: INT | ||
| 25 | default_value: undef | ||
| 26 | is_nullable: 0 | ||
| 27 | size: 11 | ||
| 28 | |||
| 29 | =head2 name | ||
| 30 | |||
| 31 | data_type: VARCHAR | ||
| 32 | default_value: undef | ||
| 33 | is_nullable: 0 | ||
| 34 | size: 16 | ||
| 35 | |||
| 36 | =cut | ||
| 37 | |||
| 38 | 4 | __PACKAGE__->add_columns( | |
| 39 | "id", | ||
| 40 | { data_type => "INT", default_value => undef, is_nullable => 0, size => 11 }, | ||
| 41 | "name", | ||
| 42 | { | ||
| 43 | data_type => "VARCHAR", | ||
| 44 | default_value => undef, | ||
| 45 | is_nullable => 0, | ||
| 46 | size => 16, | ||
| 47 | }, | ||
| 48 | ); | ||
| 49 | 4 | __PACKAGE__->set_primary_key("id"); | |
| 50 | 4 | __PACKAGE__->add_unique_constraint("name", ["name"]); | |
| 51 | |||
| 52 | =head1 RELATIONS | ||
| 53 | |||
| 54 | =head2 region_scores | ||
| 55 | |||
| 56 | Type: has_many | ||
| 57 | |||
| 58 | Related object: L<Bracket::Schema::Result::RegionScore> | ||
| 59 | |||
| 60 | =cut | ||
| 61 | |||
| 62 | 4 | __PACKAGE__->has_many( | |
| 63 | "region_scores", | ||
| 64 | "Bracket::Schema::Result::RegionScore", | ||
| 65 | { "foreign.region" => "self.id" }, | ||
| 66 | ); | ||
| 67 | |||
| 68 | =head2 teams | ||
| 69 | |||
| 70 | Type: has_many | ||
| 71 | |||
| 72 | Related object: L<Bracket::Schema::Result::Team> | ||
| 73 | |||
| 74 | =cut | ||
| 75 | |||
| 76 | 4 | __PACKAGE__->has_many( | |
| 77 | "teams", | ||
| 78 | "Bracket::Schema::Result::Team", | ||
| 79 | { "foreign.region" => "self.id" }, | ||
| 80 | ); | ||
| 81 | |||
| 82 | |||
| 83 | # Created by DBIx::Class::Schema::Loader v0.05003 @ 2010-03-02 09:36:49 | ||
| 84 | # DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZvJypnGpz1chQKLdGt/Gyg | ||
| 85 | |||
| 86 | |||
| 87 | # You can replace this text with custom content, and it will be preserved on regeneration | ||
| 88 | 4 | 1; | |