Listing events from today and being able to step forwards and backwards

时间:2016-04-04 18:44:33

标签: ruby-on-rails ruby-on-rails-4 pagination

Im trying to build a simple event app in rails. The events have a date and a name. I want the index view to list 10 events from "today" and on. Then it should be possible to step forward/backwards in time and list the next/previous 10 events.

"Next" => Step forward in time by 10 events.

"Previous" => Step backwards in time by 10 events.

I dont know how I should tackle this problem. I have had a look at the will_paginate gem. But there Im only able to list the events from today and step forward.

0 个答案:

没有答案