Reputation: 1
@RequestMapping(value="/doSearch", method = RequestMethod.POST)
public ModelAndView listSerchClients(@RequestParam("bnCustomerName") String searchText) {
Map<String, Object> model = new HashMap<String, Object>();
model.put("sclients", prepareListofBean(clientService.listSearchClientss(searchText))) ;
return new ModelAndView("serchResult", model);
}
Curently Searchresults return to serchResult.jsp
but i want to keep serch result in current jsp (search.jsp) how to achieve this
Upvotes: 0
Views: 933
Reputation: 26961
Curently Searchresults return to
serchResult.jsp
but i want to keep serch result in current jsp (search.jsp
) how to achieve this
This is because you return serchResult.jsp
in the method. Just change the returning ModelAndView
to search
return new ModelAndView("search", model);
Upvotes: 1