Sha256: 5be3232ec1e66df8ea226eab6ac4044462ac997f41dec6f479249e2b3ee368f8

Contents?: true

Size: 341 Bytes

Versions: 7

Compression:

Stored size: 341 Bytes

Contents

module Enjoy
  module Models
    module Mongoid
      module Menu
        extend ActiveSupport::Concern

        included do
          has_and_belongs_to_many :pages, inverse_of: :menus, class_name: "Enjoy::Page"
          alias_method :items, :pages

          field :name, type: String, default: ""
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
enjoy_cms-0.3.0.4 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.3.0.3 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.3.0.2 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.2.1 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.2.0.3.2 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.2.0.3.1 lib/enjoy/models/mongoid/menu.rb
enjoy_cms-0.2.0.3 lib/enjoy/models/mongoid/menu.rb