mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-13 01:10:39 -07:00
Set up bullet gem. Implement bullet gem suggestions.
This commit is contained in:
parent
3408ecd749
commit
5a8d032dd0
10 changed files with 39 additions and 17 deletions
|
|
@ -1,7 +1,7 @@
|
|||
class HomeController < ApplicationController
|
||||
def index
|
||||
@districts = District.all.order(:name)
|
||||
@schools = School.all.order(:name)
|
||||
@schools = School.all.includes([:district]).order(:name)
|
||||
|
||||
@categories = Category.sorted.map { |category| CategoryPresenter.new(category: category) }
|
||||
end
|
||||
|
|
|
|||
|
|
@ -12,8 +12,8 @@ class SqmApplicationController < ApplicationController
|
|||
def set_schools_and_districts
|
||||
@district = District.find_by_slug district_slug
|
||||
@districts = District.all.order(:name)
|
||||
@school = School.find_by_slug school_slug
|
||||
@schools = School.where(district: @district).order(:name)
|
||||
@school = School.find_by_slug(school_slug)
|
||||
@schools = School.includes([:district]).where(district: @district).order(:name)
|
||||
@academic_year = AcademicYear.find_by_range params[:year]
|
||||
@has_empty_dataset = Measure.none_meet_threshold? school: @school, academic_year: @academic_year
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue