Implement an endpoint to get all the courses of an user

This commit is contained in:
LeoMoulin committed 2024-04-20 23:29:22 +02:00
1 parent 061f329020
commit 1e2efac5bc
5 files changed
+57 -6

No files matched your search

+8
View File
@@ -71,3 +71,11 @@ export async function getCourses(role){
export async function alterCourse(id, changes){
return restPatch("/course/" + id, changes);
}
/**
* Return a list containing all the actual courses of a user
*/
export async function getUserActualCourses(userId){
return restGet("/usercourses/"+userId)
}