我在jQuery中有一个ajax调用,但它没有进入相应的控制器,我不确定我在做什么错误
$.ajax({
url: "${pageContext.request.contextPath}/group/edit/export/download",
method: "POST",
data: {
values: savedValues,
groupId: groupIdent
},
success: function(){
},
error: function(){
alert("Error occurred while saving selecte EMail IDs.");
},
complete: function(){
}
});
我的控制器是
@RequestMapping(value = "/group/edit/export/download", method = RequestMethod.POST)
@ResponseBody
public void navdbGroupExport(@RequestParam("values[]")String[] values,@RequestParam String groupId) throws Exception
{
System.out.println("we have come to controller"+values);
System.out.println(groupId);
int i =0;
for(String navdb : values)
{
excelLibrary.setExcelData(i, 0, navdb,groupId);
i++;
}
}
我已经尝试过调试,但控件没有转移到Controller,我很困惑该怎么做。
提前致谢