I have the following spring controller
@Controller
@RequestMapping("/accreq")
with the following display
@RequestMapping(value = "/defRoles", method=RequestMethod.GET)
public @ResponseBody String loadDefaultRoles(
@RequestParam(value="idGroup", required=false) String groupID
throws ServletException{
I am trying to call this method with the following jquery ajax
$.ajax({
type: 'GET',
url: '/accreq/defRoles',
data: {idGroup: $('#infoGroup').val() },
success: function() {
alert("success");
}
});
Please help me figure out why the Spring method is not called, even if the ajax method is called when the button is clicked. I went through a script with firebug and it definitely gets into the ajax function.
coder source
share