lib/rom/sql/plugin/pagination.rb in rom-sql-1.3.5 vs lib/rom/sql/plugin/pagination.rb in rom-sql-2.0.0.beta1

- old
+ new

@@ -57,13 +57,13 @@ end # Paginate a relation # # @example - # rom.relation(:users).class.per_page(10) - # rom.relation(:users).page(1) - # rom.relation(:users).pager # => info about pagination + # rom.relations[:users].class.per_page(10) + # rom.relations[:users].page(1) + # rom.relations[:users].pager # => info about pagination # # @return [Relation] # # @api public def page(num) @@ -72,10 +72,10 @@ end # Set limit for pagination # # @example - # rom.relation(:users).page(2).per_page(10) + # rom.relations[:users].page(2).per_page(10) # # @api public def per_page(num) next_pager = pager.at(dataset, pager.current_page, num) new(next_pager.dataset, pager: next_pager)