scinote-web/app/models/project_comment.rb

9 lines
210 B
Ruby
Raw Normal View History

class ProjectComment < Comment
2017-06-28 21:21:32 +08:00
belongs_to :project,
foreign_key: :associated_id,
inverse_of: :project_comments,
optional: true
2016-02-12 23:52:43 +08:00
validates :project, presence: true
2016-02-12 23:52:43 +08:00
end