diff --git a/.gitignore b/.gitignore
index 5ad5761e1f9129fc8dc958c115a2d26d6f8c2d32..0aea98510b971066d46c963bd022317c1acd1b0a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -41,4 +41,10 @@ logs/
.qoder/
-.kiro/
\ No newline at end of file
+.kiro/
+fs-admin/src/main/resources/application-xydev.yml
+fs-admin/src/main/resources/application-xyprod.yml
+/fs-admin/src/main/resources/static/pc
+/fs-admin/src/main/resources/templates/index.html
+fs-admin/src/main/resources/logback-spring.xml
+fs-admin/src/main/resources/logback-spring.xml
diff --git a/fs-admin/pom.xml b/fs-admin/pom.xml
index b94ff18c657cf183bf2a813ccd4f95b3fcc4cc5b..41022ff96647dd3274f286d27d730cd7a1f7b6dd 100644
--- a/fs-admin/pom.xml
+++ b/fs-admin/pom.xml
@@ -69,6 +69,64 @@
+
+ org.codehaus.mojo
+ exec-maven-plugin
+ 3.5.0
+
+
+ install-frontend-dependencies
+ generate-resources
+
+ exec
+
+
+ pnpm
+ D:\workspace\OpenSoucre\UGit\freefs-myfork\free-fs-frontend
+
+ install
+
+
+
+
+ build-frontend
+ generate-resources
+
+ exec
+
+
+ pnpm
+ D:\workspace\OpenSoucre\UGit\freefs-myfork\free-fs-frontend
+
+ run
+ build
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-antrun-plugin
+ 3.1.0
+
+
+ clean-frontend-resources
+ process-resources
+
+ run
+
+
+
+
+
+
+
+
+
+
+
+
org.apache.maven.plugins
maven-resources-plugin
@@ -91,6 +149,42 @@
+
+ copy-frontend-index
+ process-resources
+
+ copy-resources
+
+
+ ${project.build.outputDirectory}/templates
+
+
+ D:\workspace\OpenSoucre\UGit\freefs-myfork\free-fs-frontend\dist
+
+ index.html
+
+
+
+
+
+
+ copy-frontend-static
+ process-resources
+
+ copy-resources
+
+
+ ${project.build.outputDirectory}/static
+
+
+ D:\workspace\OpenSoucre\UGit\freefs-myfork\free-fs-frontend\dist
+
+ index.html
+
+
+
+
+
diff --git a/fs-admin/src/main/java/com/xddcodec/fs/controller/IndexController.java b/fs-admin/src/main/java/com/xddcodec/fs/controller/IndexController.java
new file mode 100644
index 0000000000000000000000000000000000000000..3131e51acbf8baeac9a57942192b3fb81db172c5
--- /dev/null
+++ b/fs-admin/src/main/java/com/xddcodec/fs/controller/IndexController.java
@@ -0,0 +1,62 @@
+package com.xddcodec.fs.controller;
+
+import jakarta.servlet.http.HttpServletRequest;
+import jakarta.servlet.http.HttpServletResponse;
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+/**
+ * @author xiao
+ */
+@Controller
+public class IndexController {
+
+ /**
+ * 默认进入系统页面,系统首页
+ */
+ @RequestMapping(value= {"/", "/view/**"})
+ public String index(HttpServletRequest request, HttpServletResponse response) {
+ String requestURI = request.getRequestURI();
+// todo 后续如果加入移动端代码放开此部分代码
+// if ("/".equals(requestURI)) {
+// if (isMobile(request)) {
+// return "redirect:/mv/";
+// }
+// return "redirect:/pv/";
+// } else {
+// if (isMobile(request)) {
+// return "redirect:" + requestURI.replaceFirst("/view", "/mv");
+// }
+// return "redirect:" + requestURI.replaceFirst("/view", "/pv");
+// }
+ return "redirect:/pv/";
+ }
+
+ /**
+ * pc端 系统首页
+ */
+ @RequestMapping("/pv/**")
+ public String pvindex(HttpServletRequest request, HttpServletResponse response) {
+ return "index";
+ }
+
+ /**
+ * 移动端 系统首页
+ */
+ @RequestMapping("/mv/**")
+ public String mvindex(HttpServletRequest request, HttpServletResponse response) {
+ return "mobile";
+ }
+
+ /**
+ * 去登陆页
+ */
+ @RequestMapping("/login")
+ public String login(HttpServletRequest request, HttpServletResponse response) {
+// todo 后续如果加入移动端代码放开此部分代码
+// if (isMobile(request)) {
+// return "redirect:/mv/login";
+// }
+ return "redirect:/pv/login";
+ }
+}
diff --git a/fs-admin/src/main/resources/application.yml b/fs-admin/src/main/resources/application.yml
index fae869cff1ce0726376341cb9de16509c4cc5f37..30e7ac970c8b4a6d67eb66e3921cb7a91ce572d4 100644
--- a/fs-admin/src/main/resources/application.yml
+++ b/fs-admin/src/main/resources/application.yml
@@ -39,11 +39,11 @@ spring:
messages:
basename: i18n/messages
encoding: UTF-8
- # 模版引擎配置
- # thymeleaf:
- # mode: LEGACYHTML5
- # prefix: classpath:/templates/
- # encoding: UTF-8
+ # 模版引擎配置 用于后端 统一打包前端 前端打包后的index.html直接放置到 /templates/index.html 同理移动端配置打包后的入口文件为mobile.html放置在/templates/mobile.html,其他静态资源放置在static即可
+ thymeleaf:
+ mode: LEGACYHTML5
+ prefix: classpath:/templates/
+ encoding: UTF-8
# 邮件配置
mail:
diff --git a/fs-admin/src/main/resources/logback-spring.xml b/fs-admin/src/main/resources/logback-spring.xml
deleted file mode 100644
index e2e39d9c434441b500813beb2f66b3120d64fcff..0000000000000000000000000000000000000000
--- a/fs-admin/src/main/resources/logback-spring.xml
+++ /dev/null
@@ -1,78 +0,0 @@
-
-
-
-
- logback
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- ${CONSOLE_LOG_PATTERN}
-
- UTF-8
-
-
-
-
-
-
-
-
-
- ${log.path}/${application_name}.%d{yyyy-MM-dd}.log
-
- 30
-
-
- ${FILE_LOG_PATTERN}
-
- UTF-8
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file