Questions tagged [kaminari]

A Scope & Engine based, clean, powerful, customizable and sophisticated paginator for Rails 3

A Scope & Engine based, clean, powerful, customizable and sophisticated paginator for Rails 3

572 questions
0
votes
2 answers

Kaminari outputs **n** tables each with **n** rows

I am new to RoR so I'm missing something very basic here, but I can't figure it out. I'm using Kaminari gem for pagination in RoR application by calling in controller: users_controller.rb: def index @users = User.order('created_at…
zrl3dx
  • 7,699
  • 3
  • 25
  • 35
0
votes
1 answer

Infinite scrolling in rails with haml

I'm trying to implement infinite scrolling into my project. I have do everything as in this howto: https://github.com/amatsuda/kaminari/wiki/How-To:-Create-Infinite-Scrolling-with-jQuery But it's not working for me :( Controller: def show …
bmalets
  • 3,207
  • 7
  • 35
  • 64
0
votes
3 answers

undefined method current_page for array kaminari

I'm trying to do pagination for products details(images), but I'm getting this error. NoMethodError in Home#index Showing /home/aws002/webpage/app/views/home/index.html.erb where line #6 raised: undefined method `current_page' for # Here is my…
user2218532
  • 331
  • 1
  • 5
  • 10
0
votes
1 answer

Rails and kaminari pagination, how do you use the name of the collection in the pagination text?

I'm using kaminari for pagination in a rails project and it's working great. I've generate the views and locale files for it too. One issue I'm having however is using the name of the collection thats being paginated in the pagination text. For…
CafeHey
  • 5,699
  • 19
  • 82
  • 145
0
votes
0 answers

Kaminari wrong number of arguments (0 for 1)

I'm using kaminari and bootstrap_kaminari gems in my app. Previously they worked fine, but now, I don't know if it was an update that I made, this error appears every time the method paginate is called: ActionView::Template::Error (wrong number of…
Renan
  • 1,910
  • 4
  • 22
  • 36
0
votes
3 answers

kaminari: undefined method `paginate' for #

In my controller, I have: @bills = Bill.where(:param1 => x, :param2 => y).sort_by {|u| u.created_at}.reverse.paginate(:page => params[:page]) And I get the above-mentioned error when I try to render. Getting rid of the where, sort and reverse…
user1436111
  • 2,111
  • 7
  • 24
  • 41
0
votes
1 answer

Pagination in a partial using AJAX

I've asked this question before, but I think I've figured what the problem may be. I have a page, which holds a table div. I use an AJAX call to get a table (not a partial, its just another table.html.erb with its own method in its controller). In…
user1002563
  • 335
  • 1
  • 4
  • 17
0
votes
2 answers

Why this pagination doesn't work when using Kaminari?

Here's error and my codes. I'm using Kaminari Error: undefined method `model_name' for # 73: <%= page_entries_info(@communities).html_safe %> view <%= page_entries_info(@communities).html_safe %> Community…
HUSTEN
  • 5,117
  • 4
  • 24
  • 38
0
votes
2 answers

Paginator shows weird result. Why?

I'm using kaminari for pagination. Then I have 3 models such as User, Community, and Uniquecode. I'm facing the problem, in which the number of shown records varie(change) at each params[:page]. In addition, if I put <% @uniquecode_count %>, it…
MKK
  • 2,713
  • 5
  • 31
  • 51
0
votes
1 answer

Rails
    numbers reset at each page using Kaminari

Have a news story display, similar to HackerNews, that uses an
    tag for numbering and vote ranking. When trying to paginate using the Kaminari gem the
  1. numbers of each article get reset to 1-20 on every page. I've tried using CSS…
lux
  • 37
  • 7
0
votes
1 answer

Kaminari with AJAX, unable to paginate

I've followed the AJAX Kaminari example here: https://github.com/amatsuda/kaminari_example/tree/ajax I've successfully generated the partial and table. However, pressing the pages in the pagination does not update my table. In fact, upon pressing,…
user1002563
  • 335
  • 1
  • 4
  • 17
0
votes
1 answer

Kaminari index from both data-remote and html messing with links

I have an index view for a model(nested ) that never gets called from the model, but is rendered from a couple different models. One view can render the index with either JS or html. With JS is it in a #related div in the show view and a data-remote…
appleII717
  • 328
  • 3
  • 12
0
votes
2 answers

Wrong url in paginate (kaminari) for search with %

I have paginate (kaminari) on search page, and if i search somthing with % like "50% discount" i get page http://some.domain.com/50%25+discount where paginate has wrong urls (without escaping %) like: http://some.domain.com/50%+discount?page=2 Do i…
Alexey
  • 2,326
  • 5
  • 17
  • 27
0
votes
1 answer

Kaminari in Apotomo widget, links messed up

I have Kaminari pagination inside an apotomo widget. The pagination links render as expected until an apotomo event is fired. Then the pagination links render with a href that appears to be the url of the previous apotomo…
rigyt
  • 2,219
  • 3
  • 28
  • 40
0
votes
2 answers

Pagination in ruby on rails

I had got a task to do pagination.When i am doing pagination i had got these error NoMethodError in ProductsController#index undefined method `page' for []:ActiveRecord::Relation Rails.root: /home/nithinv/store Application Trace | Framework Trace…
Nithin Viswanathan
  • 3,245
  • 7
  • 39
  • 84