app/models/knowledge_base/sectionables/gallery.rb in knowledge_base-0.0.3 vs app/models/knowledge_base/sectionables/gallery.rb in knowledge_base-0.1.0
- old
+ new
@@ -1,5 +1,9 @@
-module KnowledgeBase
- class Sectionables::Gallery < ActiveRecord::Base
+module KnowledgeBase::Sectionables
+ class Gallery < Sectionable
has_many :images, -> { order 'position DESC' }
+
+ def to_s
+ "#{super}: #{title}"
+ end
end
end