updated spring boot to 2.2.1

* added a header as fragment
This commit is contained in:
2019-11-25 16:15:36 +01:00
부모 89748e7ef5
커밋 6f6f705495
5개의 변경된 파일50개의 추가작업 그리고 1개의 파일을 삭제

파일 보기

@ -3,7 +3,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:2.1.10.RELEASE")
classpath("org.springframework.boot:spring-boot-gradle-plugin:2.2.1.RELEASE")
}
}

파일 보기

@ -14,4 +14,10 @@ public class GreetingController {
return "greeting";
}
@GetMapping("/home")
public String home(Model model) {
//model.addAttribute("name", name);
return "home";
}
}

파일 보기

@ -0,0 +1,15 @@
# ----------------------------------------
# CORE PROPERTIES
# ----------------------------------------
# LOGGING
logging.level.org.springframework.web=INFO
# ----------------------------------------
# WEB PROPERTIES
# ----------------------------------------
# EMBEDDED SERVER CONFIGURATION (ServerProperties)
server.address=127.0.0.1
server.port=8080

파일 보기

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html lang="de" dir="ltr" xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="utf-8">
<style></style>
</head>
<body>
<nav class="hero-secondary" th:fragment="header">
<div class="content-width flex">
<h1>Project eCommerce</h1>
<a>Angebote</a>
<input class="spacer" type="text" placeholder="Nach Produkten suchen...">
<button>Login</button>
</div>
</nav>
</body>
</html>

파일 보기

@ -0,0 +1,11 @@
<!DOCTYPE html>
<html lang="de" dir="ltr" xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="utf-8">
<title>e-commerce</title>
<style></style>
</head>
<body>
<div th:replace="fragments/header :: header">Header</div>
</body>
</html>