Sha256: 0e4566ea11408419c6ea97616189351e73fdb2cd1bb5186b9ebeec26deba6792

Contents?: true

Size: 547 Bytes

Versions: 31

Compression:

Stored size: 547 Bytes

Contents

# frozen_string_literal: true
module ActiveAdmin

  class Resource
    module Pagination

      # The default number of records to display per page
      attr_accessor :per_page

      # The default number of records to display per page
      attr_accessor :max_per_page

      # Enable / disable pagination (defaults to true)
      attr_accessor :paginate

      def initialize(*args)
        super
        @paginate = true
        @per_page = namespace.default_per_page
        @max_per_page = namespace.max_per_page
      end
    end
  end
end

Version data entries

31 entries across 31 versions & 1 rubygems

Version Path
activeadmin-4.0.0.beta14 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta13 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta12 lib/active_admin/resource/pagination.rb
activeadmin-3.2.5 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta11 lib/active_admin/resource/pagination.rb
activeadmin-3.2.4 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta10 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta9 lib/active_admin/resource/pagination.rb
activeadmin-3.2.3 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta8 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta7 lib/active_admin/resource/pagination.rb
activeadmin-3.2.2 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta6 lib/active_admin/resource/pagination.rb
activeadmin-3.2.1 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta5 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta4 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta3 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta2 lib/active_admin/resource/pagination.rb
activeadmin-4.0.0.beta1 lib/active_admin/resource/pagination.rb
activeadmin-3.2.0 lib/active_admin/resource/pagination.rb