Sha256: 9813750161be7f820b02fba33f57ac03721921476d8e383d9eed8d9bf4048003

Contents?: true

Size: 426 Bytes

Versions: 2

Compression:

Stored size: 426 Bytes

Contents

module Admin::Resources::PaginationHelper

  def admin_paginate(items, options)
    if defined?(Kaminari)
      paginate(items, options)
    elsif defined?(WillPaginate)
      will_paginate(items, options)
    else
      "<p align='center'>Showing only #{@resource.typus_options_for(:per_page)} records. Please, install <strong>Kaminari</strong> or <strong>WillPaginate</strong> to paginate.</p>".html_safe
    end
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
typus-3.1.10 app/helpers/admin/resources/pagination_helper.rb
typus-3.1.9 app/helpers/admin/resources/pagination_helper.rb