@RequestMapping(value = "/{id}", method = RequestMethod.GET) public String update(@PathVariable("id") int id, Model uiModel) { MemberHelp help = service.findOne(id); addMenu(uiModel); uiModel.addAttribute("help", help); return EDIT; }
@RequestMapping(value = "/{id}", method = RequestMethod.PUT) public String update(@PathVariable("id") int id, @ModelAttribute("help") MemberHelp help) { help.setId(id); service.update(help); return REDIRECT + id; }