Topic: Paginate method
Am new and working on that "Aha!" moment.
I generated CRUD methods via scaffold and was a bit thrown by:
@hotel_pages, @hotels = paginate :hotels, :per_page => 10
Figured "paginate" must be a method that does something like @hotels = hotel.find :all
plus some sort of pagination.
However, I'm thrown by the syntax @hotel_pages, @hotels....
What is going on with the comma? How do these two elements relate to each other? Is this common?
Thanks for any explication you can provide.