去掉模版引擎直接使用html

This commit is contained in:
Captain.B 2020-03-02 18:59:26 +08:00
parent 104b02e242
commit 25426b299e
3 changed files with 6 additions and 14 deletions

View File

@ -41,17 +41,6 @@
<artifactId>spring-boot-starter</artifactId> <artifactId>spring-boot-starter</artifactId>
</dependency> </dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency> <dependency>
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId> <artifactId>spring-boot-starter-test</artifactId>

View File

@ -11,13 +11,13 @@ public class IndexController {
@GetMapping(value = "/") @GetMapping(value = "/")
public String index() { public String index() {
return "index"; return "index.html";
} }
@GetMapping(value = "/login") @GetMapping(value = "/login")
public String login() { public String login() {
if (SessionUtils.getUser() == null) { if (SessionUtils.getUser() == null) {
return "login"; return "login.html";
} else { } else {
return "redirect:/"; return "redirect:/";
} }

View File

@ -22,4 +22,7 @@ mybatis.configuration.use-column-label=true
mybatis.configuration.auto-mapping-behavior=full mybatis.configuration.auto-mapping-behavior=full
mybatis.configuration.default-statement-timeout=25000 mybatis.configuration.default-statement-timeout=25000
logging.file.path=/opt/fit2cloud/logs/${spring.application.name} logging.file.path=/opt/fit2cloud/logs/${spring.application.name}
# view
spring.resources.static-locations=classpath:/templates/,classpath:/static/