From 92c5f577fd8485fa98a349b2559fc88b6ac52c0c Mon Sep 17 00:00:00 2001 From: esakemp Date: Tue, 13 Aug 2019 12:39:49 +0300 Subject: [PATCH] fix bug with refresh in course population --- .../src/components/CourseStudents/index.jsx | 2 +- .../CourseStudentsFilters/CourseCreditFilter.jsx | 8 ++++---- .../src/components/CourseStudentsFilters/GradeFilter.jsx | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/services/oodikone2-frontend/src/components/CourseStudents/index.jsx b/services/oodikone2-frontend/src/components/CourseStudents/index.jsx index 1e180ca68b..6e7c73fed7 100644 --- a/services/oodikone2-frontend/src/components/CourseStudents/index.jsx +++ b/services/oodikone2-frontend/src/components/CourseStudents/index.jsx @@ -109,7 +109,7 @@ const mapStateToProps = ({ coursePopulation, localize, singleCourseStats, popula selectedStudents = difference(samples.map(s => s.studentNumber), selectedStudents) } } - + console.log(singleCourseStats) return ({ studentData: coursePopulation.students, courses: coursePopulation.courses, diff --git a/services/oodikone2-frontend/src/components/CourseStudentsFilters/CourseCreditFilter.jsx b/services/oodikone2-frontend/src/components/CourseStudentsFilters/CourseCreditFilter.jsx index d368b25519..ea15dac75f 100644 --- a/services/oodikone2-frontend/src/components/CourseStudentsFilters/CourseCreditFilter.jsx +++ b/services/oodikone2-frontend/src/components/CourseStudentsFilters/CourseCreditFilter.jsx @@ -9,7 +9,7 @@ import { courseCreditFilter } from '../../populationFilters' const CourseCreditFilter = ({ coursecode, courseData, filter, setPopulationFilterAction, removePopulationFilterAction }) => { const [credits, setCredits] = useState(0) const handleFilter = () => { - setPopulationFilterAction(courseCreditFilter({ credits, coursecode, coursename: courseData[coursecode].name })) + setPopulationFilterAction(courseCreditFilter({ credits, coursecode, coursename: courseData.name })) } const handleChange = (e, { value }) => { @@ -38,7 +38,7 @@ const CourseCreditFilter = ({ coursecode, courseData, filter, setPopulationFilte /> - +