问题遇到的现象和发生背景
跳转不过去页面,如何实现这个需求呢??
问题相关代码,请勿粘贴截图
function edit(data) {
debugger
$.ajax({
url: '${ctx}/xxxxx/editDetail',
type: 'POST',
async: false,
dataType: 'json',
data: {'personId': data.personId},
success: function (data) {
console.log("发送成功")
}, error: function () {
console.log("获取错误");
return "error";
}
});
}
controller层:
@RequestMapping("/editDetail")
@ResponseBody
public ModelAndView editPayDetail(Integer personId) {
ModelAndView mv = new ModelAndView();
Map<String, Object> map = provincialCompanyService.getDetail(personId);
mv.addObject("map", map);
mv.setViewName("xxxxx/view");
return mv;
}