osem-fcy/app/models/answer.rb

7 lines
137 B
Ruby
Raw Normal View History

2014-02-09 18:05:57 +02:00
class Answer < ActiveRecord::Base
has_many :qanswers
2014-07-21 14:49:05 +02:00
has_many :questions, through: :qanswers
2014-02-09 18:05:57 +02:00
2014-07-21 14:49:05 +02:00
validates :title, presence: true
2014-02-09 18:05:57 +02:00
end