Sha256: 1cdbf501bb5af050bb8946cd126b17f88290a3cd060b9948cb8bf86956fd58f7

Contents?: true

Size: 492 Bytes

Versions: 2

Compression:

Stored size: 492 Bytes

Contents

# So, ERB and SLIM fans want to make gem became independent of HAML
# Ok, let it be. But you will convert view partials youself
# require "haml"

require "the_sortable_tree/engine"
require "the_sortable_tree/version"

module TheSortableTree
  # include TheSortableTree::Scopes
  module Scopes
    def self.included(base)
      base.class_eval do
        scope :nested_set,          order_by( [[ :lft, :asc ]])
        scope :reversed_nested_set, order('lft DESC')
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
the_sortable_tree_mongoid-1.8.5.1 lib/the_sortable_tree.rb
the_sortable_tree_mongoid-1.8.5 lib/the_sortable_tree.rb