![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
文章平均质量分 57
谷宜
这个作者很懒,什么都没留下…
展开
-
关于new Date()不是计算机当前时间,相差了8小时的解决方法
相信有朋友写代码时,有时候用new Date()就是当前计算机得最新时间,但有时候又无缘无故相差了8小时,在这里给大家解决:第一步:在yaml文件里添加配置spring: jackson: date-format: yyyy-MM-dd HH:mm:ss time-zone: GMT+8第二步:修改数据库url链接,和配置文件里的time-zone一样统一设置成中国时间spring: datasource: type: com.alibaba.druid.po原创 2021-09-22 09:56:35 · 1414 阅读 · 0 评论 -
Springboot集成shiro
1.依赖导入: <dependency> <groupId>org.apache.shiro</groupId> <artifactId>shiro-spring</artifactId> <version>${shiro.spring.version}</version> </dependency> &l原创 2021-08-21 11:08:45 · 190 阅读 · 0 评论 -
Springboot集成邮箱服务
做项目时集成一个简易的邮箱服务,用的是springboot自带的mail:1.依赖导入:<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-mail</artifactId></dependency>2.yaml文件配置:由于阿里云服务器默认禁止使用25端口,在这里我们开放465端口,使用原创 2021-08-20 11:30:56 · 1670 阅读 · 0 评论 -
java实现在线富文本编辑器,并传格式数据给后端
做了一个简易在线的富文本编辑器,前端是html,后台是Java前端代码:<html lang="en" xmlns:th="http://www.thymeleaf.org"><head> <title></title> <meta http-equiv="content-type" content="text/html;charset=utf-8" /> <script src="https://cdn.sta原创 2021-06-17 09:18:04 · 2697 阅读 · 0 评论