摘要: 一、导jar包: 二、配置springmvc.xml: <!-- 配置CommonsMultipartResolver,用于文件上传 --> <bean id="multipartResolver" class="org.springframework.web.multipart.commons.C 阅读全文
posted @ 2020-11-27 23:48 Double晨 阅读(265) 评论(0) 推荐(0)
摘要: 一、导jar包: 二、controller.java: @ResponseBody @RequestMapping(value="testJson") public List<Student> testJson(){ Student stu1 = new Student(1,"zs",21); St 阅读全文
posted @ 2020-11-27 22:29 Double晨 阅读(219) 评论(0) 推荐(0)
摘要: 一、导入jar包 二、配置:springmvc.xml: <!-- MVC基础配置 --> <mvc:annotation-driven></mvc:annotation-driven> 三、在实体类的属性前面加上: 并且在controller.java中: 阅读全文
posted @ 2020-11-27 21:50 Double晨 阅读(227) 评论(0) 推荐(0)