// @RequestMapping(value = "/admin/populate", method = RequestMethod.GET) @RequestMapping(value = "/populate", method = RequestMethod.GET) public String populateDatabase(Model model) { Collection<Movie> movies = populator.populateDatabase(); model.addAttribute("movies", movies); addUser(model); return "/movies/list"; }
@RequestMapping(value = "/admin/clean", method = RequestMethod.GET) public String clean(Model model) { populator.cleanDb(); return "movies/list"; }