代码是这样的,这里不需要value啊
@Controller
@RequestMapping("/")
public class HelloWorldController {
/*
* This method will serve as default GET handler.
*
*/
@RequestMapping(method = RequestMethod.GET)
public String newRegistration(ModelMap model) {
Student student = new Student();
model.addAttribute("student", student);
return "enroll";
}
}