Module: TimeTable::TimetableCalendarHelper

Defined in:
app/helpers/time_table/timetable_calendar_helper.rb

Defined Under Namespace

Classes: Timetable, TimetableCalendar

Instance Method Summary collapse

Instance Method Details

#timetable_calendar(bounds:, range: 7, scale: 60, clip: 15, frozen: false, **options, &block) ⇒ Object



3
4
5
6
7
8
9
10
11
# File 'app/helpers/time_table/timetable_calendar_helper.rb', line 3

def timetable_calendar(bounds:, range: 7, scale: 60, clip: 15, frozen: false, **options, &block)
  timetable_calendar = TimetableCalendar.new(bounds: bounds, range: range, view: self, query_params: request.query_parameters)
  timetable_calendar.set_multi_timetable(scale: scale, clip: clip, frozen: frozen, view: self)

  options[:class] = "#{options[:class]} timetable-calendar"
   :div, **options do 
    yield timetable_calendar
  end
end