mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-07 21:48:16 -08:00
Rename ResponseRate to ResponseRateCalculator. Create a new response
rate model. Create a loader to refresh response rates for all subcategories. Use precalculated response rates in views Wrap more elements in page caching Calculate a response rate for a subcategory if one does not already exist
This commit is contained in:
parent
dfc5202b88
commit
c03615cb43
16 changed files with 352 additions and 177 deletions
|
|
@ -74,7 +74,8 @@ module AnalyzeHelper
|
|||
def empty_dataset?(measures:, school:, academic_year:)
|
||||
@empty_dataset ||= Hash.new do |memo, (school, academic_year)|
|
||||
memo[[school, academic_year]] = measures.all? do |measure|
|
||||
measure.survey_item_responses.where(school:, academic_year:).none? || measure.none_meet_threshold?(school:, academic_year:)
|
||||
response_rate = measure.subcategory.response_rate(school:, academic_year:)
|
||||
!response_rate.meets_student_threshold && !response_rate.meets_teacher_threshold
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue