Skip to content
This repository has been archived by the owner on Jun 17, 2020. It is now read-only.

BanjoInc/mongoid-pagination

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What

Adds pagination scopes to your mongoid models.

Usage

class Person
  include Mongoid::Document
  include Mongoid::Pagination

  default_page_size 20
end

Person.paginate(:page => 2, :limit => 25) # limit and page
Person.paginate(:offset => 20, :limit => 25) # limit and offset
Person.per_page(25) # just does a limit

About

Pagination scopes for mongoid

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Ruby 100.0%