上一页 1 ··· 5 6 7 8 9 10 11 12 下一页
摘要: 写这篇日记记录一下自己的愚蠢行为。 具体报错如下: 信息: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 10, acquireRetryAttempts -> 30 阅读全文
posted @ 2017-08-02 16:38 钓鱼翁 阅读(2467) 评论(0) 推荐(0) 编辑
摘要: 我们在编写的Controller 等服务器端的代码时,接受到的请求参数经常会乱码。 解决:在Tomcat 的安装目录下找到conf 文件夹下的server.xml文件用记事本打开。 找到 添加上URIEncoding="UTF-8" 在把eclipse中的Server 工程中的server.xml文 阅读全文
posted @ 2017-07-31 22:09 钓鱼翁 阅读(568) 评论(0) 推荐(0) 编辑
摘要: Neither BindingResult nor plain target object for bean name 'command' available as request attribute 这个异常引起的原因是modelAttribute这个单词写错了,滑稽,吐槽一些这种应该错误应该在编译期报错的啊。 阅读全文
posted @ 2017-07-31 14:20 钓鱼翁 阅读(542) 评论(0) 推荐(0) 编辑
摘要: 举例说明, 将一个字符串转换成的 User 类型。 例如将字符串 1-zcd-1234-zcd@163.com-1999/12/12 转换成User 类型。 一、实体类 二、Controller 在表单中输入一个字符串 1-zcd-1234-zcd@163.com-1999/12/12 下面的代码没 阅读全文
posted @ 2017-07-30 20:01 钓鱼翁 阅读(247) 评论(0) 推荐(0) 编辑
摘要: SpringMVC进行一些常用的数据类型转换,这里以Date 数据类型的转换为例。 SpringMVC表单中输入日期,一般都是以字符串的形式输入,如何将字符形式的日期转换为Date 类型的呢?这里只需两步。 下面把代码贴出来。 一、在实体类中日期属性上加 @DateTimeFormat(patter 阅读全文
posted @ 2017-07-30 16:06 钓鱼翁 阅读(327) 评论(0) 推荐(0) 编辑
摘要: 一、SpringMVC 会把ModelAndView 的model中的数据放到request 域中 二、如果不想让请求经过任何handler,而直接响应页面,可以使用 mvc:view-controller 标签。但是如果使用了这个标签那么一定要加上 mvc:annotation-driven 标签 阅读全文
posted @ 2017-07-30 10:40 钓鱼翁 阅读(274) 评论(0) 推荐(0) 编辑
摘要: 一、在WEB工程的web.xml文件中配置HiddenHttpMethodFilter 二、form 表单中添加一个隐藏域 name="_method" value="DELETE"。 例如: 阅读全文
posted @ 2017-07-29 21:19 钓鱼翁 阅读(1337) 评论(0) 推荐(0) 编辑
摘要: 这个类的代码比较少,所以把整个类的代码都复制过来。在注释中添加上自己的理解。 阅读全文
posted @ 2017-07-29 20:25 钓鱼翁 阅读(480) 评论(0) 推荐(0) 编辑
摘要: 个人总结:抽象方法必须实现后才能调用。 有关的实现如下: 阅读全文
posted @ 2017-07-28 10:40 钓鱼翁 阅读(1599) 评论(0) 推荐(0) 编辑
摘要: 具体异常:org.hibernate.id.IdentifierGenerationException: attempted to assign id from null one-to-one property[com.pms.entities.personnelManagement.Trainin 阅读全文
posted @ 2017-07-26 10:29 钓鱼翁 阅读(260) 评论(0) 推荐(0) 编辑
上一页 1 ··· 5 6 7 8 9 10 11 12 下一页