diff options
| author | Florian Fischer <florian.fischer@muhq.space> | 2026-06-24 09:18:26 +0200 |
|---|---|---|
| committer | Florian Fischer <florian.fischer@muhq.space> | 2026-06-24 09:18:26 +0200 |
| commit | af8585faa1aa7c39564c583963349c4a2922df9c (patch) | |
| tree | 5a806a738a76e5f928e68e4def47e0b3a857d490 /js/student-common.js | |
| parent | 13f9914757b2a72e77369859bbaec35339f31446 (diff) | |
| download | bycs-sol-af8585faa1aa7c39564c583963349c4a2922df9c.tar.gz bycs-sol-af8585faa1aa7c39564c583963349c4a2922df9c.zip | |
cockpit: finish prototype UI
* remove process and calendar
* add observation period
* improve mocking
Diffstat (limited to 'js/student-common.js')
| -rw-r--r-- | js/student-common.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/js/student-common.js b/js/student-common.js index 48f7d60..f0d8ed3 100644 --- a/js/student-common.js +++ b/js/student-common.js @@ -1,8 +1,11 @@ import { getUserIconUrl, getCourseParticipantsUrl } from "./config.js"; +import { fetchGraduation } from "./graduation-common.js"; /** * Class to represent Students. */ class Student { + graduation = null; + constructor(id, name, groups) { this.id = id; this.name = name; @@ -23,6 +26,14 @@ class Student { } return this.groups.filter((g) => g !== this.getGroupName()); } + + async getGraduation() { + if(!this.graduation) { + // fetchGraduation(this) sets this.graduation + await fetchGraduation(this); + } + return this.graduation; + } } async function fetchStudent(idFilter, nameFilter, groupFilter) { |
