@RequestMapping(value="/users")@Controllerpublic class UserController
{ @RequestMapping(value="/queryuser",method = RequestMethod.GET)
public String queryuser(Model model) throws Exception {
return "forward:/users/uc"; }
@RequestMapping(value="/uc",method = RequestMethod.GET)
public String quer(Model model) throws Exception {
return "redirect:/#/home"; }
@RequestMapping(value = "/save", method = RequestMethod.GET)
public ModelAndView saveUser(HttpServletRequest request, HttpServletResponse response) throws Exception {
ModelAndView mv = new ModelAndView("forward:/users/uc");//默认为forward模式
// ModelAndView mv = new ModelAndView("redirect:/#/home");//redirect模式
return mv; } }