class Booker::V4::Models::LocationDaySchedule

Constants

EndTime
StartTime
Weekday

Attributes

EndTime[RW]
StartTime[RW]
Weekday[RW]

Public Class Methods

from_hash(hash) click to toggle source
Calls superclass method Booker::Model::from_hash
# File lib/booker/v4/models/location_day_schedule.rb, line 9
def self.from_hash(hash)
  model = super
  model.Weekday = to_wday(model.Weekday)
  strftime_format = '%T'
  model.StartTime = model.StartTime.try(:strftime, strftime_format)
  model.EndTime = model.EndTime.try(:strftime, strftime_format)
  model
end