mirror of
https://github.com/edcommonwealth/Dashboard.git
synced 2026-03-18 18:26:24 -07:00
chore: show analyze page without errors
This commit is contained in:
parent
e4e6a5c7fb
commit
b47f8d2f61
84 changed files with 2243 additions and 1792 deletions
34
app/views/dashboard/analyze/_school_years.html.erb
Normal file
34
app/views/dashboard/analyze/_school_years.html.erb
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
<h3 class="sub-header-4 mt-5">School Years</h3>
|
||||
<% available_academic_years.each_with_index do | year, index | %>
|
||||
<div class="d-flex justify-content-start align-items-center mt-1" data-controller="analyze">
|
||||
<input type="checkbox"
|
||||
class="form-check-input"
|
||||
id="<%= year.range %>"
|
||||
name="year-checkbox"
|
||||
value="<%= analyze_subcategory_link(district: district, school: school, academic_year: academic_year, category: category, subcategory: subcategory) %>"
|
||||
<%= selected_academic_years.include?(year) ? "checked" : "" %>
|
||||
data-action="click->analyze#refresh"
|
||||
<% empty_dataset = empty_dataset?(measures: measures, school: school, academic_year: year) %>
|
||||
<% empty_survey_dataset = empty_survey_dataset?(measures: measures, school: school, academic_year: year) %>
|
||||
<% if graph.slug == 'all-data' %>
|
||||
<%= empty_dataset ? "disabled" : "" %>
|
||||
<% else %>
|
||||
<%= empty_survey_dataset ? "disabled" : "" %>
|
||||
<% end %>
|
||||
>
|
||||
<label class="px-3" for="<%= year.range %>"><%= year.range %></label><br>
|
||||
<div class="bg-color-blue px-3" style="width:20px;height:20px;background-color:<%= colors[index] %>;"></div>
|
||||
<% if graph.slug == 'all-data' && empty_dataset %>
|
||||
<i class="fa-solid fa-circle-exclamation px-3"
|
||||
data-bs-toggle="popover" data-bs-placement="right"
|
||||
data-bs-content="No admin data OR teacher and student survey response rates below <%= Dashboard::ResponseRate::TEACHER_RATE_THRESHOLD %>%">
|
||||
</i>
|
||||
<% end %>
|
||||
<% if graph.slug != 'all-data' && empty_survey_dataset %>
|
||||
<i class="fa-solid fa-circle-exclamation px-3"
|
||||
data-bs-toggle="popover" data-bs-placement="right"
|
||||
data-bs-content="Teacher and student survey response rates below <%= Dashboard::ResponseRate::TEACHER_RATE_THRESHOLD %>%">
|
||||
</i>
|
||||
<% end %>
|
||||
</div>
|
||||
<% end %>
|
||||
Loading…
Add table
Add a link
Reference in a new issue