feat: initialize AutoTeacher Next.js project structure

This commit is contained in:
gameloader
2025-11-10 19:07:47 +08:00
commit 4cb9db1b7c
34 changed files with 8032 additions and 0 deletions

53
src/types/index.ts Normal file
View File

@ -0,0 +1,53 @@
export type Course = {
id: number;
name: string;
description?: string | null;
teacherId: string;
};
export type Classroom = {
id: number;
name: string;
description?: string | null;
courseId: number;
teacherId: string;
};
export type Assignment = {
id: number;
title: string;
description?: string | null;
courseId: number;
classroomId: number;
formSchema: {
fields: Array<{
name: string;
label: string;
type?: "text" | "textarea";
placeholder?: string;
required?: boolean;
}>;
file_upload?: {
accept?: string[];
label?: string;
};
} | null;
teacherId: string;
gradingCriteria?: string | null;
autoEvaluate: boolean;
};
export type Submission = {
id: number;
assignmentId: number;
studentId: string;
studentName: string;
originalFilename: string;
fileUrl: string;
fileKey?: string | null;
submittedAt: string;
formPayload?: Record<string, unknown> | null;
evaluationScore?: number | null;
evaluationComment?: string | null;
evaluatedAt?: string | null;
};