|
@@ -159,7 +159,7 @@ public class ApiController {
|
|
|
|
|
|
|
|
@GetMapping("/inscription/{uuid}")
|
|
@GetMapping("/inscription/{uuid}")
|
|
|
List<Volunteer> getVolunteers(@PathVariable String uuid) {
|
|
List<Volunteer> getVolunteers(@PathVariable String uuid) {
|
|
|
- return repositoryVolunteer.findByEventUuid(uuid);
|
|
|
|
|
|
|
+ return repositoryVolunteer.findByEventUuidAndImportedFalse(uuid);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@PutMapping("/inscription/{uuid}")
|
|
@PutMapping("/inscription/{uuid}")
|
|
@@ -179,7 +179,8 @@ public class ApiController {
|
|
|
boolean deleteVolunteers(@PathVariable String uuid, @PathVariable Long id) {
|
|
boolean deleteVolunteers(@PathVariable String uuid, @PathVariable Long id) {
|
|
|
Optional<Volunteer> v = repositoryVolunteer.findById(id);
|
|
Optional<Volunteer> v = repositoryVolunteer.findById(id);
|
|
|
if (v.isPresent()) {
|
|
if (v.isPresent()) {
|
|
|
- repositoryVolunteer.delete(v.get());
|
|
|
|
|
|
|
+ v.get().setImported(true);
|
|
|
|
|
+ repositoryVolunteer.save(v.get());
|
|
|
return true;
|
|
return true;
|
|
|
}
|
|
}
|
|
|
return false;
|
|
return false;
|