Quellcode durchsuchen

修改boardshow等路径

sunyj vor 8 Jahren
Ursprung
Commit
038b9f67ec

+ 10 - 9
kanban-console/src/main/java/com/uas/kanban/WebAppConfiguration.java

@@ -41,14 +41,13 @@ public class WebAppConfiguration extends WebMvcConfigurerAdapter {
 		// 使用/src/main/webapp下资源均需在此添加
 		registry.addResourceHandler("/static/**").addResourceLocations("/resources/");
 		registry.addResourceHandler("/WEB-INF/**").addResourceLocations("/WEB-INF/");
-		registry.addResourceHandler("/html/**").addResourceLocations("/html/");
 		registry.addResourceHandler("/app/**").addResourceLocations("/app/");
 		super.addResourceHandlers(registry);
 	}
 
 	@Override
 	public void configureViewResolvers(ViewResolverRegistry registry) {
-		InternalResourceViewResolver viewResolver = new InternalResourceViewResolver("", ".html");
+		InternalResourceViewResolver viewResolver = new InternalResourceViewResolver("/WEB-INF/views/", ".html");
 		viewResolver.setContentType("text/html;charset=UTF-8");
 		registry.viewResolver(viewResolver);
 		super.configureViewResolvers(registry);
@@ -56,13 +55,15 @@ public class WebAppConfiguration extends WebMvcConfigurerAdapter {
 
 	@Override
 	public void addViewControllers(ViewControllerRegistry registry) {
-		registry.addViewController("/").setViewName("/WEB-INF/views/index");
-		registry.addViewController("/index").setViewName("/WEB-INF/views/index");
-		registry.addViewController("/console").setViewName("/WEB-INF/views/console");
-		registry.addViewController("/fileUpload").setViewName("/WEB-INF/views/fileUpload");
-		registry.addViewController("/board").setViewName("/html/board");
-		registry.addViewController("/desktop").setViewName("/html/desktop");
-		registry.addViewController("/login").setViewName("/html/login");
+		registry.addViewController("/").setViewName("desktop");
+		registry.addViewController("/index").setViewName("desktop");
+		registry.addViewController("/desktop").setViewName("desktop");
+		registry.addViewController("/board").setViewName("board");
+		registry.addViewController("/boardshow").setViewName("boardshow");
+		registry.addViewController("/login").setViewName("login");
+
+		registry.addViewController("/console").setViewName("console");
+		registry.addViewController("/fileUpload").setViewName("fileUpload");
 		super.addViewControllers(registry);
 	}
 

+ 0 - 0
kanban-console/src/main/webapp/html/board.html → kanban-console/src/main/webapp/WEB-INF/views/board.html


+ 12 - 0
kanban-console/src/main/webapp/WEB-INF/views/boardshow.html

@@ -0,0 +1,12 @@
+<!DOCTYPE html>
+<html>
+<head lang="en">
+  <meta charset="UTF-8">
+  <title>Board</title>
+</head>
+<body style="margin:0px">
+  <div id="root"></div>
+  <script type="text/javascript" src="/static/lib/echarts-for-react/echarts.min.js"></script>
+  <script src="/static/js/bundle.js"></script>
+</body>
+</html>

+ 0 - 0
kanban-console/src/main/webapp/html/desktop.html → kanban-console/src/main/webapp/WEB-INF/views/desktop.html


+ 0 - 10
kanban-console/src/main/webapp/WEB-INF/views/index.html

@@ -1,10 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8">
-<title>Kanban</title>
-</head>
-<body>
-	<p>Kanban Home</p>
-</body>
-</html>

+ 0 - 0
kanban-console/src/main/webapp/html/login.html → kanban-console/src/main/webapp/WEB-INF/views/login.html


+ 0 - 12
kanban-console/src/main/webapp/build/index.html

@@ -1,12 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head lang="en">
-  <meta charset="UTF-8">
-  <title>Board</title>
-</head>
-<body style="margin:0px">
-  <div id="root"></div>
-  <script type="text/javascript" src="./lib/echarts-for-react/echarts.min.js"></script>
-  <script src="bundle.js"></script>
-</body>
-</html>

+ 0 - 0
kanban-console/src/main/webapp/build/images/dad624ed.log.png → kanban-console/src/main/webapp/resources/images/dad624ed.log.png


+ 0 - 0
kanban-console/src/main/webapp/build/bundle.js → kanban-console/src/main/webapp/resources/js/bundle.js


+ 0 - 0
kanban-console/src/main/webapp/build/lib/echarts-for-react/echarts.min.js → kanban-console/src/main/webapp/resources/lib/echarts-for-react/echarts.min.js


+ 0 - 0
kanban-console/src/main/webapp/build/lib/echarts-for-react/lib/core.js → kanban-console/src/main/webapp/resources/lib/echarts-for-react/lib/core.js


+ 0 - 0
kanban-console/src/main/webapp/build/lib/echarts-for-react/lib/index.js → kanban-console/src/main/webapp/resources/lib/echarts-for-react/lib/index.js


+ 0 - 0
kanban-console/src/main/webapp/build/lib/my_echarts.min.js → kanban-console/src/main/webapp/resources/lib/my_echarts.min.js