Sha256: 151be2fd6244958174a988e880ed8e6b0972d0e499fde65dceaf110defee5184

Contents?: true

Size: 325 Bytes

Versions: 1

Compression:

Stored size: 325 Bytes

Contents

module KnowledgeBase
  class Article < ActiveRecord::Base
    extend FriendlyId

    publishable

    friendly_id :title, use: :slugged

    has_many :category_article_associations
    has_many :categories, through: :category_article_associations
    has_many :sections, -> { order 'position ASC' }, as: :container
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
knowledge_base-0.0.3 app/models/knowledge_base/article.rb