Exports page

<%= turbo_frame_tag "results" do %> <%= form_with(action: exports_path, method: :get, data: { turbo_frame: "results", turbo_action: "advance", controller: "form", action: "input->form#submit" }) do |f| %>

Report Type

Grouped By

>
>
>
<% if @presenter.show_student_survey_types %>

Student Survey Type

<%= f.select(:student_survey_type, @student_survey_types, selected: @student_survey_type ) %> <% end %> <% if @schools_grouped_by == "district" %>

District

<%= f.select(:district, @districts, selected: @selected_district_id ) %> <% end %> <% if @schools_grouped_by == "school" %>

School

<%= f.select(:school, @schools.map(&:name), selected: @selected_school.name ) %> <% end %>

School Years

<% @academic_years.each_with_index do | year, index | %>
>
<% end %> <%= link_to "Submit", exports_csv_path(format: :csv, params: params.to_enum.to_h ) , class: "btn btn-primary mt-5"%> <% end %> <% end %>