mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-07 21:48:16 -08:00
fix dependabot alerts by upgrading puma and nokogiri
This commit is contained in:
parent
cff51bc9f6
commit
bb6f6306c4
5 changed files with 54 additions and 41 deletions
4
Gemfile
4
Gemfile
|
|
@ -13,7 +13,7 @@ gem 'rails', '~> 6.1.4.1'
|
|||
gem 'pg'
|
||||
|
||||
# Use Puma as the app server
|
||||
gem 'puma', '~> 3.0'
|
||||
gem "puma", ">= 5.5.2"
|
||||
# Use SCSS for stylesheets
|
||||
gem 'sassc-rails'
|
||||
# Use Uglifier as compressor for JavaScript assets
|
||||
|
|
@ -34,6 +34,8 @@ gem 'jbuilder', '~> 2.5'
|
|||
# Use Capistrano for deployment
|
||||
# gem 'capistrano-rails', group: :development
|
||||
|
||||
gem "nokogiri", ">= 1.12.5"
|
||||
|
||||
gem 'bootsnap', require: false
|
||||
|
||||
gem 'haml'
|
||||
|
|
|
|||
|
|
@ -164,7 +164,8 @@ GEM
|
|||
pg (1.2.3)
|
||||
popper_js (2.9.3)
|
||||
public_suffix (4.0.6)
|
||||
puma (3.12.6)
|
||||
puma (5.5.2)
|
||||
nio4r (~> 2.0)
|
||||
racc (1.5.2)
|
||||
rack (2.2.3)
|
||||
rack-protection (2.1.0)
|
||||
|
|
@ -299,9 +300,10 @@ DEPENDENCIES
|
|||
listen (~> 3.0.5)
|
||||
nested_scaffold
|
||||
newrelic_rpm
|
||||
nokogiri (>= 1.12.5)
|
||||
omniauth
|
||||
pg
|
||||
puma (~> 3.0)
|
||||
puma (>= 5.5.2)
|
||||
rails (~> 6.1.4.1)
|
||||
rails-controller-testing
|
||||
rspec-rails (~> 4.1.2)
|
||||
|
|
|
|||
|
|
@ -1,13 +1,13 @@
|
|||
// Entry point for the build script in your package.json
|
||||
|
||||
import Rails from "@rails/ujs";
|
||||
import Turbolinks from "turbolinks";
|
||||
import * as ActiveStorage from "@rails/activestorage";
|
||||
// import "channels";
|
||||
import Rails from "@rails/ujs";
|
||||
import Turbolinks from "turbolinks";
|
||||
import * as ActiveStorage from "@rails/activestorage";
|
||||
// import "channels";
|
||||
|
||||
Rails.start();
|
||||
Turbolinks.start();
|
||||
ActiveStorage.start();
|
||||
Rails.start();
|
||||
Turbolinks.start();
|
||||
ActiveStorage.start();
|
||||
import { initializeListenersForNavDropdowns } from "./dashboard.js";
|
||||
import { initializeListenersForHomeDropdowns } from "./home.js";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,14 +1,18 @@
|
|||
export function initializeListenersForNavDropdowns(){
|
||||
document.addEventListener("turbolinks:load", function() {
|
||||
const schoolDropdown = document.querySelector('#select-school');
|
||||
export function initializeListenersForNavDropdowns() {
|
||||
document.addEventListener("turbolinks:load", function () {
|
||||
const schoolDropdown = document.querySelector("#select-school");
|
||||
if (schoolDropdown) {
|
||||
document.querySelector('#select-school').addEventListener('change', (event) => {
|
||||
window.location = event.target.value;
|
||||
});
|
||||
document
|
||||
.querySelector("#select-school")
|
||||
.addEventListener("change", (event) => {
|
||||
window.location = event.target.value;
|
||||
});
|
||||
|
||||
document.querySelector('#select-district').addEventListener('change', (event) => {
|
||||
window.location = event.target.value;
|
||||
});
|
||||
document
|
||||
.querySelector("#select-district")
|
||||
.addEventListener("change", (event) => {
|
||||
window.location = event.target.value;
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,28 +1,33 @@
|
|||
export function initializeListenersForHomeDropdowns(){
|
||||
document.addEventListener('turbolinks:load', () => {
|
||||
const districtDropdown = document.querySelector('#district-dropdown');
|
||||
if (districtDropdown) {
|
||||
districtDropdown.addEventListener('change', event => {
|
||||
const schoolDropdown = document.querySelector('#school-dropdown');
|
||||
export function initializeListenersForHomeDropdowns() {
|
||||
document.addEventListener("turbolinks:load", () => {
|
||||
const districtDropdown = document.querySelector("#district-dropdown");
|
||||
if (districtDropdown) {
|
||||
districtDropdown.addEventListener("change", (event) => {
|
||||
const schoolDropdown = document.querySelector("#school-dropdown");
|
||||
|
||||
const districtId = Number(event.target.value);
|
||||
const districtId = Number(event.target.value);
|
||||
|
||||
const schoolsInDistrict = window.schools.filter(school => school.district_id === districtId);
|
||||
const schoolsInDistrict = window.schools.filter(
|
||||
(school) => school.district_id === districtId
|
||||
);
|
||||
|
||||
schoolsInDistrict.forEach(school => {
|
||||
const optionElem = document.createElement('option');
|
||||
optionElem.setAttribute('value', school.url);
|
||||
const schoolNameNode = document.createTextNode(school.name);
|
||||
optionElem.appendChild(schoolNameNode);
|
||||
schoolDropdown.appendChild(optionElem);
|
||||
schoolsInDistrict.forEach((school) => {
|
||||
const optionElem = document.createElement("option");
|
||||
optionElem.setAttribute("value", school.url);
|
||||
const schoolNameNode = document.createTextNode(school.name);
|
||||
optionElem.appendChild(schoolNameNode);
|
||||
schoolDropdown.appendChild(optionElem);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
document.querySelector('button[data-id="go-to-school"]').addEventListener('click', event => {
|
||||
const selectedSchoolURL = document.querySelector('#school-dropdown').value;
|
||||
window.location = selectedSchoolURL;
|
||||
});
|
||||
}
|
||||
});
|
||||
return true;
|
||||
document
|
||||
.querySelector('button[data-id="go-to-school"]')
|
||||
.addEventListener("click", (event) => {
|
||||
const selectedSchoolURL =
|
||||
document.querySelector("#school-dropdown").value;
|
||||
window.location = selectedSchoolURL;
|
||||
});
|
||||
}
|
||||
});
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue