business_seconds¶ ↑
Instalation:
gem install business_seconds
This is an extension for bokmann/business_time gem. It adds method to count business time (in seconds):
begin = Time.parse("June 11th, 2010, 4:50 pm") end = Time.parse("June 14th, 2010, 9:50 am") Time.business_seconds_duration_from_to(begin, end)
and helper methods:
time = Time.parse("June 11th, 2010, 4:50 pm") Time.business_seconds_left_to_the_end_of_day(time) Time.business_seconds_from_the_beginning_of_day(time) Time.during_business_hours?(time)
This gem is dependent from bokmann/business_time gem:
http://github.com/bokmann/business_time