I am trying to create a list of registered users with the information that I have in a database but the page where the list should appear when using localhost comes up with this, how could I solve it?
I think the error must be in this part of the code
@Controller
public class ListadoControlador {
@Autowired
private ListadoService listadoService;
@GetMapping ("PaginaAdmin")
public String listarUsuarios(@RequestParam(name = "page",defaultValue = "0")int page,Model modelo){
PageRequest pageRequest = PageRequest.of(page,4);
Page<Usuario> usuarios = listadoService.findAll(pageRequest);
PageRender<Usuario> pageRender = new PageRender<>("/PaginaAdmin", usuarios);
modelo.addAttribute("titulo","Listado de usuarios");
modelo.addAttribute("usuarios",usuarios);
modelo.addAttribute("page", pageRender);
return "PaginaAdmin";
}
}
or possibly somewhere in these parts
on other occasions I have been able to make the page open but the table comes out without the corresponding data that I have in the database