コード例 #1
0
 /** Select an existing Team entity */
 @RequestMapping(value = "/Team/{team_id}", method = RequestMethod.GET)
 @ResponseBody
 public Team loadTeam(@PathVariable Integer team_id) {
   return teamDAO.findTeamByPrimaryKey(team_id);
 }
コード例 #2
0
 /** Create a new Team entity */
 @RequestMapping(value = "/Team", method = RequestMethod.POST)
 @ResponseBody
 public Team newTeam(@RequestBody Team team) {
   teamService.saveTeam(team);
   return teamDAO.findTeamByPrimaryKey(team.getId());
 }
コード例 #3
0
 /** Delete an existing Team entity */
 @RequestMapping(value = "/Team/{team_id}", method = RequestMethod.DELETE)
 @ResponseBody
 public void deleteTeam(@PathVariable Integer team_id) {
   Team team = teamDAO.findTeamByPrimaryKey(team_id);
   teamService.deleteTeam(team);
 }