diff options
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/pokeviewer/pokemon.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/app/models/pokeviewer/pokemon.rb b/app/models/pokeviewer/pokemon.rb index 1410d37..1e3bfc8 100644 --- a/app/models/pokeviewer/pokemon.rb +++ b/app/models/pokeviewer/pokemon.rb | |||
@@ -14,6 +14,9 @@ module Pokeviewer | |||
14 | validates :ot_number, presence: true, | 14 | validates :ot_number, presence: true, |
15 | numericality: { greater_than_or_equal_to: 0, only_integer: true } | 15 | numericality: { greater_than_or_equal_to: 0, only_integer: true } |
16 | 16 | ||
17 | validates :ot_gender, presence: true | ||
18 | enumerize :ot_gender, in: [:female, :male] | ||
19 | |||
17 | validates :met_level, presence: true, | 20 | validates :met_level, presence: true, |
18 | numericality: { greater_than_or_equal_to: 1, only_integer: true }, | 21 | numericality: { greater_than_or_equal_to: 1, only_integer: true }, |
19 | if: Proc.new { |a| a.met_type == :normal } | 22 | if: Proc.new { |a| a.met_type == :normal } |