add check quizz for student
This commit is contained in:
parent
76f8ab120a
commit
c982ab2c05
3 changed files with 232 additions and 0 deletions
|
|
@ -319,3 +319,48 @@ export interface CompleteLessonResponse {
|
|||
certificate_issued?: boolean;
|
||||
};
|
||||
}
|
||||
|
||||
// ============================================
|
||||
// Quiz Submission Types
|
||||
// ============================================
|
||||
|
||||
export interface QuizAnswerInput {
|
||||
question_id: number;
|
||||
choice_id: number; // For MULTIPLE_CHOICE and TRUE_FALSE
|
||||
}
|
||||
|
||||
export interface SubmitQuizInput {
|
||||
token: string;
|
||||
course_id: number;
|
||||
lesson_id: number;
|
||||
answers: QuizAnswerInput[];
|
||||
}
|
||||
|
||||
export interface SubmitQuizBody {
|
||||
answers: QuizAnswerInput[];
|
||||
}
|
||||
|
||||
export interface SubmitQuizResponse {
|
||||
code: number;
|
||||
message: string;
|
||||
data?: {
|
||||
attempt_id: number;
|
||||
quiz_id: number;
|
||||
score: number;
|
||||
total_score: number;
|
||||
total_questions: number;
|
||||
correct_answers: number;
|
||||
is_passed: boolean;
|
||||
passing_score: number;
|
||||
attempt_number: number;
|
||||
started_at: Date;
|
||||
completed_at: Date;
|
||||
answers_review?: {
|
||||
question_id: number;
|
||||
selected_choice_id: number;
|
||||
correct_choice_id: number;
|
||||
is_correct: boolean;
|
||||
score: number;
|
||||
}[];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue