diff options
Diffstat (limited to 'js/teachers.js')
-rw-r--r-- | js/teachers.js | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/js/teachers.js b/js/teachers.js index c41a621..aab7d74 100644 --- a/js/teachers.js +++ b/js/teachers.js @@ -119,10 +119,11 @@ function teacherInfo(teacher_id) { let subject = subjectsString.slice(0, -2); let office_day = dateString.day(teacher_object["tpMeetings"]["day"]); let office_lesson = teacher_object["tpMeetings"]["period"]; - document.getElementById("teacher-name").innerText = name; - document.getElementById("teacher-subject").innerText = S("schoolSubject") + ": " + subject; - document.getElementById("teacher-office").innerText = office_day + ", " + S("lesson") + " " + office_lesson; - const modal = document.querySelectorAll('.side-modal')[0]; + $("#teacher-name").text(name); + $("#teacher-subject").text(`${S("schoolSubject")}: ${subject}`); + $("#teacher-office").text(`${office_day}, ${S("lesson")} ${office_lesson}`); + + const modal = document.querySelectorAll(".side-modal")[0]; M.Sidenav.getInstance(modal).open(); } |