I have problem with kaminari gem. I have forum controller. On forum controller show action.View for show action is table with all topics associated with this forum. It looks like this:
class ForumsController < ApplicationController
before_action :authenticate_user!
before_action :set_forum, only: :show
def index
@forums = Forum.all
end
def show
@forum_topics = @forum.topics.page(params[:page])
end
private
def set_forum
@forum = Forum.find(params[:id])
end
end
Forum show view:
= paginate @forum_topics
At the bottom of the page I see pagination links but when i click to take to the second page i have the same topics like in the first page? What's wrong? Any ideas?