diff --git a/app/controllers/recipes_controller.rb b/app/controllers/recipes_controller.rb index 62ceaff..fe4498d 100644 --- a/app/controllers/recipes_controller.rb +++ b/app/controllers/recipes_controller.rb @@ -7,6 +7,8 @@ class RecipesController < ApplicationController # GET /recipes def index @criteria = ViewModels::RecipeCriteria.new(params[:criteria]) + @criteria.page = params[:page] + @criteria.per = params[:per] @recipes = Recipe.for_criteria(@criteria) end diff --git a/app/views/recipes/index.html.erb b/app/views/recipes/index.html.erb index 39f3674..b97878d 100644 --- a/app/views/recipes/index.html.erb +++ b/app/views/recipes/index.html.erb @@ -9,9 +9,9 @@
No Recipes
<% else %> - <%= link_to 'New Recipe', new_recipe_path, class: 'btn btn-default' %> + <%= link_to 'New Recipe', new_recipe_path, class: 'btn btn-default' %>