Fix: renamed all the tables, with repo and controller associated to them (might have missed some), and fix some key dependency issues

This commit is contained in:
Théo Le Lez
2025-02-19 18:41:37 +01:00
parent 04a73073c1
commit 40afde89b7
54 changed files with 1161 additions and 1101 deletions

View File

@ -24,7 +24,7 @@ public class AdminApi {
* @return a list of all project managed by the current admin user
*/
@GetMapping("/admin/projects")
public Iterable<Administrateurs> getProjects() {
public Iterable<Administrator> getProjects() {
return adminApiService.getProjects();
}
@ -34,7 +34,7 @@ public class AdminApi {
* @return a list of upcoming appointments for the current user
*/
@GetMapping("/admin/appointments/upcoming")
public Iterable<Appointment> getUpcomingAppointments() {
public Iterable<DelAppointment> getUpcomingAppointments() {
return adminApiService.getUpcomingAppointments();
}
@ -44,7 +44,7 @@ public class AdminApi {
* @return a list of current unvalidated projects, waiting to be accepted
*/
@GetMapping("/admin/projects/pending")
public Iterable<Project> getPendingProjects() {
public Iterable<DelProject> getPendingProjects() {
return adminApiService.getPendingProjects();
}
@ -64,7 +64,7 @@ public class AdminApi {
* @return the status code of the request
*/
@PostMapping("/admin/project/add")
public void addNewProject(@RequestBody Project project) {
public void addNewProject(@RequestBody DelProject project) {
adminApiService.addNewProject(project);
}
@ -77,7 +77,7 @@ public class AdminApi {
*/
@PostMapping("/admin/appoitements/report/{appointmentId}")
public void createAppointmentReport(
@PathVariable String appointmentId, @RequestBody Report report) {
@PathVariable String appointmentId, @RequestBody DelReport report) {
adminApiService.createAppointmentReport(appointmentId, report);
}

View File

@ -1,7 +1,7 @@
package enseirb.myinpulse.controller;
import enseirb.myinpulse.model.LCSection;
import enseirb.myinpulse.model.Project;
import enseirb.myinpulse.model.DelProject;
import enseirb.myinpulse.service.EntrepreneurApiService;
import org.springframework.beans.factory.annotation.Autowired;
@ -63,7 +63,7 @@ public class EntrepreneurApi {
* @return status code
*/
@PostMapping("/entrepreneur/project/request")
public void requestNewProject(@RequestBody Project project) {
public void requestNewProject(@RequestBody DelProject project) {
entrepreneurApiService.requestNewProject(project);
}
}

View File

@ -1,9 +1,9 @@
package enseirb.myinpulse.controller;
import enseirb.myinpulse.model.Administrateurs;
import enseirb.myinpulse.model.Appointment;
import enseirb.myinpulse.model.Entrepreneurs;
import enseirb.myinpulse.model.Sections;
import enseirb.myinpulse.model.Administrator;
import enseirb.myinpulse.model.DelAppointment;
import enseirb.myinpulse.model.Entrepreneur;
import enseirb.myinpulse.model.SectionCell;
import enseirb.myinpulse.service.SharedApiService;
import org.springframework.beans.factory.annotation.Autowired;
@ -31,7 +31,7 @@ public class SharedApi {
* @return a list of lean canvas sections
*/
@GetMapping("/shared/project/lcsection/{projectId}/{title}/{date}")
public Iterable<Sections> getLCSection(
public Iterable<SectionCell> getLCSection(
@PathVariable("projectId") String projectId,
@PathVariable("title") String title,
@PathVariable("date") String date) {
@ -44,7 +44,7 @@ public class SharedApi {
* @return a list of all entrepreneurs in a project
*/
@GetMapping("/shared/entrepreneurs/{projectId}")
public Iterable<Entrepreneurs> getEntrepreneursByProjectId(@PathVariable int projectId) {
public Iterable<Entrepreneur> getEntrepreneursByProjectId(@PathVariable int projectId) {
return sharedApiService.getEntrepreneursByProjectId(projectId);
}
@ -57,7 +57,7 @@ public class SharedApi {
* @return a list of all project managed by the current admin user
*/
@GetMapping("/shared/projects/admin/{projectId}")
public Iterable<Administrateurs> getAdminByProjectId(@PathVariable int projectId) {
public Iterable<Administrator> getAdminByProjectId(@PathVariable int projectId) {
return sharedApiService.getAdminByProjectId(projectId);
}
@ -70,7 +70,7 @@ public class SharedApi {
* @return a list of all appointments.
*/
@GetMapping("/shared/projects/appointments/{projectId}")
public Iterable<Appointment> getAppointmentsByProjectId(@PathVariable int projectId) {
public Iterable<DelAppointment> getAppointmentsByProjectId(@PathVariable int projectId) {
return sharedApiService.getAppointmentsByProjectId(projectId);
}
@ -90,7 +90,7 @@ public class SharedApi {
* @return TODO
*/
@PostMapping("/shared/appointment/request")
public void createAppointmentRequest(@RequestBody Appointment appointment) {
public void createAppointmentRequest(@RequestBody DelAppointment appointment) {
sharedApiService.createAppointmentRequest(appointment);
}
}