Refactoring: cursus -> curriculum frontend
All checks were successful
Build and test backend / Build-backend (pull_request) Successful in 2m3s
Build and test backend / Test-backend (pull_request) Successful in 1m58s
Build and test FrontEnd / Build-frontend (pull_request) Successful in 25s

I hope I didn't missed anything, this commit is following the previous
one in this branch
This commit is contained in:
2024-03-16 10:17:04 +01:00
parent e2da7271af
commit 17d0ae7ccc
8 changed files with 60 additions and 60 deletions

View File

@ -24,7 +24,7 @@ export async function createRegister(){
* - country
* - birthdate
* - email
* - cursus
* - curriculum
* - degree
*/
export async function getRegisters(id){

View File

@ -14,10 +14,10 @@ export async function login(user, pass, exp){
* @param mail
* @param address
* @param country
* @param cursus
* @param curriculum
* @param imageId id of the image in database returned when uploaded
*/
export async function register(firstname, lastname, birthDate, password, email, address, country, cursus, imageId){
export async function register(firstname, lastname, birthDate, password, email, address, country, curriculum, imageId){
return restPost("/register", {
firstname: firstname,
lastname: lastname,
@ -26,7 +26,7 @@ export async function register(firstname, lastname, birthDate, password, email,
email: email,
address: address,
country: country,
cursus: cursus
curriculum: curriculum
});
}

View File

@ -0,0 +1,41 @@
/**
* curriculum API
*/
import { restGet, restPostn, restDelete, restPatch } from './restConsumer.js'
/**
* Create a new curriculum (bundle of courses)
* @param courses list of courses
*/
export async function createcurriculum(courses){
return restPost("/curriculum", {courses: courses} );
}
/**
* Delete the specified curriculum
*/
export async function deletecurriculum(id){
return restDelete("/curriculum/" + id);
}
/**
* Get informations on a particular curriculum
*
* @param id identification of the curriculum
*
* @return list of courses
*/
export async function getcurriculum(id){
return restGet("/curriculum/" + id);
}
/**
* Modify the courses of a curriculum
*
* @param id the id of the curriculum
* @param courses list of new courses
*/
export async function altercurriculum(id, courses){
return restPatch("/curriculum/" + id, courses);
}

View File

@ -1,41 +0,0 @@
/**
* cursus API
*/
import { restGet, restPostn, restDelete, restPatch } from './restConsumer.js'
/**
* Create a new cursus (bundle of courses)
* @param courses list of courses
*/
export async function createCursus(courses){
return restPost("/cursus", {courses: courses} );
}
/**
* Delete the specified cursus
*/
export async function deleteCursus(id){
return restDelete("/cursus/" + id);
}
/**
* Get informations on a particular cursus
*
* @param id identification of the cursus
*
* @return list of courses
*/
export async function getCursus(id){
return restGet("/cursus/" + id);
}
/**
* Modify the courses of a cursus
*
* @param id the id of the cursus
* @param courses list of new courses
*/
export async function alterCursus(id, courses){
return restPatch("/cursus/" + id, courses);
}