Class: Rapidfire::Questions::Select
- Inherits:
-
Rapidfire::Question
- Object
- ActiveRecord::Base
- Rapidfire::Question
- Rapidfire::Questions::Select
- Defined in:
- app/models/rapidfire/questions/select.rb
Direct Known Subclasses
Instance Method Summary collapse
Methods inherited from Rapidfire::Question
Instance Method Details
#options ⇒ Object
6 7 8 |
# File 'app/models/rapidfire/questions/select.rb', line 6 def .split(/\r?\n/) end |
#validate_answer(answer) ⇒ Object
10 11 12 13 14 15 16 |
# File 'app/models/rapidfire/questions/select.rb', line 10 def validate_answer(answer) super(answer) if rules[:presence] == "1" || answer.answer_text.present? answer.validates_inclusion_of :answer_text, :in => end end |