thymeleaf集成

This commit is contained in:
xwolf
2018-03-27 15:09:21 +08:00
parent 2113079be2
commit 527b50e7ba
8 changed files with 7 additions and 6 deletions
+1 -1
View File
@@ -6,6 +6,6 @@
>* jackson 日期时间格式化
>* swagger2 api管理
>* 自定义Filter,避免XSS攻击和SQL注入攻击
>* 自定义AOP配合redis解决重复提交问题
>* 自定义AOP配合redis解决重复提交问题
>* 自定义拦截器,拦截referer来避免CSRF攻击
>* 自定义拦截器,集成thymeleaf根据不同的响应状态码跳转不同的页面
+1
View File
@@ -46,6 +46,7 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
@@ -24,7 +24,6 @@ public class InterceptorConfig extends WebMvcConfigurerAdapter {
CsrfInterceptor csrfInterceptor(){
return new CsrfInterceptor();
}
/**
* 错误拦截
* @return
@@ -31,4 +31,5 @@ public class ErrorController {
public String error302(){
return "302";
}
}
+1 -1
View File
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" >
<html lang="en">
<head>
<meta charset="UTF-8"/>
<title>302</title>
+1 -1
View File
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" >
<html lang="en">
<head>
<meta charset="UTF-8"/>
<title>400</title>
+1 -1
View File
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en">
<html lang="en" >
<head>
<meta charset="UTF-8"/>
<title>404</title>
+1 -1
View File
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="en" >
<html lang="en">
<head>
<meta charset="UTF-8" />
<title>500</title>