listen können gelösccht werden
This commit is contained in:
1 parent
e7c7ec8deb
commit
4b6348a8f5
1 file changed
+6
@@ -28,6 +28,12 @@ public class PageController {
|
||||
return "index";
|
||||
}
|
||||
|
||||
@DeleteMapping("/list/{id}")
|
||||
public String deleteList(Model model, @PathVariable UUID id){
|
||||
shoppingListRepository.deleteById(id);
|
||||
return "redirect:/";
|
||||
}
|
||||
|
||||
@GetMapping("/list/{id}")
|
||||
public String list(Model model, @PathVariable UUID id){
|
||||
model.addAttribute("list", repository.findById(id));
|
||||
|
||||
Reference in new issue
Block a user