Sha256: 9b0ef11d45b68fc51964b0df5d1b78c17c7e0864600796dc3aaaa4deaba404b0

Contents?: true

Size: 458 Bytes

Versions: 2

Compression:

Stored size: 458 Bytes

Contents

module RailsCoreExtensions
  module ActionControllerSortable
    def self.included(base)
      base.extend ClassMethods
    end

    module ClassMethods
      def sortable
        include RailsCoreExtensions::ActionControllerSortable::InstanceMethods
      end
    end

    module InstanceMethods
      def sort
        RailsCoreExtensions::Sortable.new(params, controller_name).sort

        render :update do |page|
        end
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
rails_core_extensions-0.1.0 lib/rails_core_extensions/action_controller_sortable.rb
rails_core_extensions-0.0.1 lib/rails_core_extensions/action_controller_sortable.rb