Skip to content

Commit

Permalink
fix: ta can view course users of past semesters
Browse files Browse the repository at this point in the history
  • Loading branch information
Okabe-Rintarou-0 committed Apr 21, 2024
1 parent f9d020a commit 8b065f2
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "sjtu_canvas_helper"
version = "1.2.5"
version = "1.2.6"
description = "SJTU Canvas Helper"
authors = ["Okabe"]
edition = "2021"
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"package": {
"productName": "SJTU Canvas Helper",
"version": "1.2.5"
"version": "1.2.6"
},
"tauri": {
"allowlist": {
Expand Down
2 changes: 1 addition & 1 deletion src/page/users.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export default function UsersPage() {
courses = courses.filter(course => {
const courseEnd = dayjs(course.term.end_at);
const now = dayjs();
return now.isBefore(courseEnd);
return now.isBefore(courseEnd) || course.enrollments.find(enroll => enroll.role === "TaEnrollment") != undefined;
});
setCourses(courses);
} catch (e) {
Expand Down

0 comments on commit 8b065f2

Please sign in to comment.