![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
ssm
风泊月
赠人玫瑰,手留余香!
展开
-
This XML file does not appear to have any style information associated with it. The document tree is
服务端返回的数据 在页面上通过xml显示转为json显示//注意producess 的 包import org.springframework.http.MediaType; @RequestMapping(value = "/find",produces = MediaType.APPLICATION_JSON_UTF8_VALUE)在RequestMapping注解后 ...原创 2019-11-20 14:12:15 · 12659 阅读 · 0 评论 -
Driver for test database type [H2] is not available in the classpath
反复测试 报错 [DUBBO] Error creating bean with name 'dataSource': Error setting property values; nested exception is org.springframework.beans.PropertyBatchUpdateException; nested PropertyAccessExce...原创 2019-10-28 20:45:15 · 3710 阅读 · 4 评论 -
Failed to convert property value of type java.lang.String to required type java.util.Date for proper
前端页面通过表单传递的数据都是String类型 但是我们自定义类中的属性可以是任意类型。当 包含日期类型时 直接将数据进行SpringMVC的封装就会报错 string ====>date 类型错误解决方案很简单,在对应的实体类上@DateTimeFormat注解即可例子如下: @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss"...原创 2019-10-23 20:08:35 · 1071 阅读 · 0 评论 -
SpringMVC完成文件上传
本案例采用maven构建。项目结构图pom文件。<?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaL...原创 2019-08-22 15:13:00 · 186 阅读 · 0 评论 -
springMvc配置拦截器
拦截器总体流程:拦截器:对请求到达控制层前后做更多的管理 有点aop的味道。类似于Servlet 开发中的过滤器 Filter,用于对处理器进行预处理和后处理。拦截器和过滤器的区别?过滤器是 servlet 规范中的一部分,任何 java web 工程都可以使用。拦截器是 SpringMVC 框架自己的,只有使用了 SpringMVC 框架的工程才能用。过滤器在 url-p...原创 2019-08-23 15:24:47 · 306 阅读 · 0 评论 -
ssm整合配置文件
目录结构图:jdbc.propertiesjdbc.username=rootjdbc.password=123456jdbc.driver=com.mysql.jdbc.Driverjdbc.url=jdbc:mysql:///jdbc?useUnicode=true&characterEncoding=utf8applicationContext.xml...原创 2019-08-26 17:45:23 · 205 阅读 · 0 评论 -
javatype与oftype的区别
JavaType和ofType都是用来指定对象类型的,但是JavaType是用来指定pojo中对象属性的类型,而ofType指定的是映射到list集合属性中泛型的类型。xml文件<?xml version="1.0" encoding="UTF-8" ?><!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//...原创 2019-09-02 17:08:33 · 4221 阅读 · 0 评论