OCS Gradebook System

Assignment Resource Management System

Complete ecosystem for managing assignment submissions, grading, and file delivery. Covers automatic assignment creation from frontmatter, URL/file submissions, a role-gated review dashboard, and a student grade viewer — all secured by JWT and server-side role enforcement.

Production Ready
Endpoints POST /api/assignments/auto-create / GET /api/assignments/debug

Automatic Assignment Creation

CI-driven assignment sync from page frontmatter

GitHub Actions workflow scans all pages with assignment: true frontmatter
Auto-POSTs to backend on every push — idempotent, no duplicates
Supports assignment_name override frontmatter for custom names
Works for both .md posts and .ipynb notebooks after conversion
Script: scripts/create_assignments_from_frontmatter.py
GitHub Actions Python Script Spring REST Idempotent POST

About

Every page with assignment: true in its frontmatter is automatically registered as an assignment in the Spring backend on each push. The workflow resolves the assignment name from frontmatter (assignment_name field) and POSTs to /api/assignments/auto-create, which handles deduplication. IPython notebooks are converted to markdown posts first, making all notebook-based lessons submittable.

Security

Bot credentials stored as GitHub Actions secrets
Server-side deduplication prevents duplicate assignments
No manual assignment creation needed — reduces admin error
View in Dashboard
Production Ready
Endpoints POST /api/submissions/submit/{assignmentId} / GET /api/person/uid/{uid} / GET /api/assignments/debug

Student Submission Interface

URL and file upload submissions from any lesson page

Inline submission widget embedded in every post/lesson layout
Supports URL link submissions and file uploads (multipart)
assignment_name frontmatter auto-resolves to assignment ID
Late detection: compares submission time to assignment dueDate
Group submission toggle — submits on behalf of a selected group
post.html Layout Spring Multipart JWT Auth FormData API

About

Every lesson or blog post with assignment: true gets an embedded submission form via the post.html layout. Students submit a URL or upload a file — the frontend resolves the assignment ID from the page's frontmatter assignment_name field, attaches the student's identity via /api/person/uid, and POSTs to Spring. Late status is computed client-side against the stored due date.

Security

JWT credentials included on all mutation requests
Assignment ID resolved server-side — client cannot spoof a different assignment
File uploads validated for MIME type and extension server-side
View in Dashboard
Production Ready
Endpoints GET /api/assignment-submission-view/list / GET /api/assignment-submission-view/user-info / PUT /api/submissions/{id} / POST /api/submissions/grade/{id} / DELETE /api/submissions/{id}

Submissions Dashboard

Role-gated review, grading, edit, and delete

My Submissions tab: student sees only their own submissions
All Submissions tab: admin/teacher sees all with filter by name, assignment, status
Inline grade input per row for admins — saves via POST /api/submissions/grade/{id}
Edit modal: students can update URL/notes/comment; admins also set grade, feedback, isLate
Delete button (admin only) with confirmation — hard-deletes the record
File submissions show filename + Download file link via /api/files/download/{uid}/{file}
renderContent() handles URL links, file uploads, and plain text uniformly
Status badges: Pending Review / Graded / Late
Tailwind CSS Tab Switcher Role-Based UI Modal Edit

About

Centralized submissions dashboard at /submissions. The backend returns only the current user's submissions to non-admins; admins receive all submissions. CyberLord09 built the initial layout and edit modal; Hypernova101 added file download support; illuminati1618 added the Submission content column, renderContent helper, and synergy grade display.

Security

Server-side role check in AssignmentSubmissionViewController — students cannot request other users' submissions
Edit modal: grade/feedback/isLate fields hidden from non-admins in HTML and guarded in saveSubmissionEdit()
Delete endpoint requires ADMIN or TEACHER role server-side
isLate can only be set by admins — students cannot clear a late flag
View in Dashboard
Production Ready
Endpoints GET /api/assignment-submission-view/user-info / GET /api/person/uid/{uid} / GET /api/assignment-submission-view/list

Student Grade Viewer

Per-student view of grades, feedback, and status

Resolves current user via user-info → person/uid to get userId
Fetches submission list and filters to current student's submitterId
Columns: Assignment, Grade, Feedback, Status badge
Status badge: Graded (blue) / Late (red) / Pending Review (amber)
Average grade row appended at the bottom of the table
Grade sourced from AssignmentSubmission.grade — set by teacher on /submissions
Jekyll Post Spring API Status Badges Module Imports

About

The grade viewer at /student/view-grades was refactored by illuminati1618 to pull grades directly from AssignmentSubmission records via the unified list endpoint, replacing the old platform-wide grade scan. Feedback and Status columns were added so students see teacher comments and whether submissions are pending/graded/late in a single table.

Security

Backend filters list to current user's submissions — no cross-user data leakage
JWT required; unauthenticated requests get a 401 error message in the table
No admin-only data exposed — grade/feedback only shown, not editable
View in Dashboard