You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
sqm-dashboards/app/controllers/analyze_controller.rb

10 lines
377 B

# frozen_string_literal: true
class AnalyzeController < SqmApplicationController
def index
@presenter = Analyze::Presenter.new(params:, school: @school, academic_year: @academic_year)
@background ||= BackgroundPresenter.new(num_of_columns: @presenter.graph.columns.count)
@academic_year = @presenter.selected_academic_years&.first || AcademicYear.last
end
end