From 99a449ac89d1c2faef34254435d31b9a6d476f87 Mon Sep 17 00:00:00 2001 From: alexmcdermid Date: Fri, 13 Sep 2024 14:54:31 -0700 Subject: [PATCH 1/2] fix grade filter validation --- backend/src/components/studentFilters.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/components/studentFilters.js b/backend/src/components/studentFilters.js index 983b520b..6a992bad 100644 --- a/backend/src/components/studentFilters.js +++ b/backend/src/components/studentFilters.js @@ -351,7 +351,7 @@ function validateFteZeroFilter(filters) { } function validateGradeFilter(filterGrades = []) { - const activeGradeCodes = cacheService.getActiveEnrolledGradeCodes(); + const activeGradeCodes = cacheService.getActiveEnrolledGradeCodes().map(grade => grade.enrolledGradeCode); if (filterGrades.length > 0) { if (!filterGrades.every(value => activeGradeCodes.includes(value))) { log.error('Invalid grade filter.'); From 0985018f82572b3daa77540313eb1ffc909de05c Mon Sep 17 00:00:00 2001 From: alexmcdermid Date: Fri, 13 Sep 2024 15:33:24 -0700 Subject: [PATCH 2/2] update sdcSchoolCollection sort --- .../components/data-collection/AllStudents/DetailComponent.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/components/data-collection/AllStudents/DetailComponent.vue b/frontend/src/components/data-collection/AllStudents/DetailComponent.vue index 9e84ad13..67b02a01 100644 --- a/frontend/src/components/data-collection/AllStudents/DetailComponent.vue +++ b/frontend/src/components/data-collection/AllStudents/DetailComponent.vue @@ -243,7 +243,7 @@ export default { const filterKey = this.indySchoolDistrictObject.type === 'indy' ? 'schoolNameNumber' : 'districtNameNumber'; this.filterSearchParams.schoolOrDistrictId = {key: filterKey, value: this.indySchoolDistrictObject.id}; if (this.indySchoolDistrictObject.type === 'district') { - sort = { sdcSchoolCollection: 'DESC' }; + sort = { sdcSchoolCollection: 'ASC' }; } } ApiService.apiAxios.get(`${Routes.sdc.BASE_URL}/collection/${this.collectionObject.collectionID}/students-paginated-slice?tableFormat=true`, {