mirror of
https://github.com/rzmk/learnhouse.git
synced 2025-12-19 04:19:25 +00:00
feat: init quizblock
This commit is contained in:
parent
eebaef6679
commit
23412ce19a
10 changed files with 263 additions and 6 deletions
10
front/services/blocks/Quiz/quiz.ts
Normal file
10
front/services/blocks/Quiz/quiz.ts
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
import { getAPIUrl } from "@services/config";
|
||||
import { RequestBody, RequestBodyForm } from "@services/utils/requests";
|
||||
|
||||
|
||||
export async function submitQuizBlock(lecture_id: string, data: any) {
|
||||
const result: any = await fetch(`${getAPIUrl()}blocks/quiz/${lecture_id}"`, RequestBody("POST", data))
|
||||
.then((result) => result.json())
|
||||
.catch((error) => console.log("error", error));
|
||||
return result;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue