|
Revision 356, 1.3 KB
(checked in by eevee, 2 years ago)
|
|
Removed the only use of the evchains.base column. Mostly in preparation for the eventual database cleanup, but also so I can close #20 with a clean conscience.
|
| Line | |
|---|
| 1 | package Vee::Schema::EvChains; |
|---|
| 2 | |
|---|
| 3 | use strict; |
|---|
| 4 | use warnings; |
|---|
| 5 | use base 'DBIx::Class'; |
|---|
| 6 | |
|---|
| 7 | # NOTE FOR WHEN THIS IS REFACTORED: |
|---|
| 8 | # I *believe* that base is not actually used anywhere except in pokemon_list, |
|---|
| 9 | # but the IDEA is that it is essentially the Pokemon with the LOWEST NATIONAL |
|---|
| 10 | # DEX NUMBER, thus making it the ORIGINAL FORM of the Pokemon. |
|---|
| 11 | # My SOLE EXCEPTION to this is Manaphy, which is the base of its chain, but |
|---|
| 12 | # only because that's not a real chain anyway. |
|---|
| 13 | # NOTE AGAIN: |
|---|
| 14 | # Nevermind! base is now unused. Delete to your heart's content. |
|---|
| 15 | |
|---|
| 16 | =head1 NAME |
|---|
| 17 | |
|---|
| 18 | Vee::Schema::EvChains - DBIC class for the C<evchains> table |
|---|
| 19 | |
|---|
| 20 | =cut |
|---|
| 21 | |
|---|
| 22 | __PACKAGE__->load_components('Core'); |
|---|
| 23 | __PACKAGE__->table('evchains'); |
|---|
| 24 | __PACKAGE__->add_columns(qw/ |
|---|
| 25 | id |
|---|
| 26 | base |
|---|
| 27 | growth |
|---|
| 28 | chain |
|---|
| 29 | steps |
|---|
| 30 | |
|---|
| 31 | babygs |
|---|
| 32 | babyc |
|---|
| 33 | babyrusa |
|---|
| 34 | |
|---|
| 35 | baby_item |
|---|
| 36 | /); |
|---|
| 37 | __PACKAGE__->set_primary_key('id'); |
|---|
| 38 | |
|---|
| 39 | __PACKAGE__->has_many(pokemon => 'Vee::Schema::Pokemon', 'evid'); |
|---|
| 40 | # TODO: delete the _pokemon suffix |
|---|
| 41 | __PACKAGE__->belongs_to(base_pokemon => 'Vee::Schema::Pokemon', 'base'); |
|---|
| 42 | |
|---|
| 43 | =head1 SEE ALSO |
|---|
| 44 | |
|---|
| 45 | L<Vee::Schema>, L<DBIx::Class> |
|---|
| 46 | |
|---|
| 47 | =head1 AUTHOR |
|---|
| 48 | |
|---|
| 49 | Maintainer: Alex "Eevee" Munroe (C<veekun@veekun.com>) |
|---|
| 50 | |
|---|
| 51 | See the included F<AUTHORS> file for a full list of contributers. |
|---|
| 52 | |
|---|
| 53 | =head1 LICENSE |
|---|
| 54 | |
|---|
| 55 | See the included F<LICENSE> file. |
|---|
| 56 | |
|---|
| 57 | =cut |
|---|
| 58 | |
|---|
| 59 | 1; |
|---|