Time calculate method in rails

You also can use the DateHelper (http://api.rubyonrails.org/classes/ ActionView/Helpers/DateHelper.html). Always the Rails API is the best place to start.

Regards.

Franco Catena.