diff --git a/backend-java/services/ai-service/pom.xml b/backend-java/services/ai-service/pom.xml
new file mode 100644
index 0000000..8019334
--- /dev/null
+++ b/backend-java/services/ai-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+
+ 1.0.0
+ jar
+
+
+ AI能力服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/ai-service/src/main/java/com/xlxumu/ai/AIServiceApplication.java b/backend-java/services/ai-service/src/main/java/com/xlxumu/ai/AIServiceApplication.java
new file mode 100644
index 0000000..94a4bb9
--- /dev/null
+++ b/backend-java/services/ai-service/src/main/java/com/xlxumu/ai/AIServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.ai;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class AIServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(AIServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/ai-service/src/main/resources/application.properties b/backend-java/services/ai-service/src/main/resources/application.properties
new file mode 100644
index 0000000..fbc1166
--- /dev/null
+++ b/backend-java/services/ai-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8089
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_ai?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/data-platform-service/pom.xml b/backend-java/services/data-platform-service/pom.xml
new file mode 100644
index 0000000..b67b39b
--- /dev/null
+++ b/backend-java/services/data-platform-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+ data-platform-service
+ 1.0.0
+ jar
+
+ data-platform-service
+ 数据平台服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/data-platform-service/src/main/java/com/xlxumu/dataplatform/DataPlatformServiceApplication.java b/backend-java/services/data-platform-service/src/main/java/com/xlxumu/dataplatform/DataPlatformServiceApplication.java
new file mode 100644
index 0000000..27707ec
--- /dev/null
+++ b/backend-java/services/data-platform-service/src/main/java/com/xlxumu/dataplatform/DataPlatformServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.dataplatform;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class DataPlatformServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(DataPlatformServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/data-platform-service/src/main/resources/application.properties b/backend-java/services/data-platform-service/src/main/resources/application.properties
new file mode 100644
index 0000000..68630ea
--- /dev/null
+++ b/backend-java/services/data-platform-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8085
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_data?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/finance-service/pom.xml b/backend-java/services/finance-service/pom.xml
new file mode 100644
index 0000000..44c2f4c
--- /dev/null
+++ b/backend-java/services/finance-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+ finance-service
+ 1.0.0
+ jar
+
+ finance-service
+ 金融服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/finance-service/src/main/java/com/xlxumu/finance/FinanceServiceApplication.java b/backend-java/services/finance-service/src/main/java/com/xlxumu/finance/FinanceServiceApplication.java
new file mode 100644
index 0000000..7d39ff6
--- /dev/null
+++ b/backend-java/services/finance-service/src/main/java/com/xlxumu/finance/FinanceServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.finance;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class FinanceServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(FinanceServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/finance-service/src/main/resources/application.properties b/backend-java/services/finance-service/src/main/resources/application.properties
new file mode 100644
index 0000000..25df0d3
--- /dev/null
+++ b/backend-java/services/finance-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8084
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_finance?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/government-service/pom.xml b/backend-java/services/government-service/pom.xml
new file mode 100644
index 0000000..16be42d
--- /dev/null
+++ b/backend-java/services/government-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+
+ 1.0.0
+ jar
+
+
+ 政务服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/government-service/src/main/java/com/xlxumu/government/GovernmentServiceApplication.java b/backend-java/services/government-service/src/main/java/com/xlxumu/government/GovernmentServiceApplication.java
new file mode 100644
index 0000000..4bb079a
--- /dev/null
+++ b/backend-java/services/government-service/src/main/java/com/xlxumu/government/GovernmentServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.government;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class GovernmentServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(GovernmentServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/government-service/src/main/resources/application.properties b/backend-java/services/government-service/src/main/resources/application.properties
new file mode 100644
index 0000000..4bbeccb
--- /dev/null
+++ b/backend-java/services/government-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8086
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_government?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/mall-service/pom.xml b/backend-java/services/mall-service/pom.xml
new file mode 100644
index 0000000..d296788
--- /dev/null
+++ b/backend-java/services/mall-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+
+ 1.0.0
+ jar
+
+
+ 商城服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/mall-service/src/main/java/com/xlxumu/mall/MallServiceApplication.java b/backend-java/services/mall-service/src/main/java/com/xlxumu/mall/MallServiceApplication.java
new file mode 100644
index 0000000..6e3a6a6
--- /dev/null
+++ b/backend-java/services/mall-service/src/main/java/com/xlxumu/mall/MallServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.mall;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class MallServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(MallServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/mall-service/src/main/resources/application.properties b/backend-java/services/mall-service/src/main/resources/application.properties
new file mode 100644
index 0000000..4a1bc8f
--- /dev/null
+++ b/backend-java/services/mall-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8088
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_mall?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/trade-service/pom.xml b/backend-java/services/trade-service/pom.xml
new file mode 100644
index 0000000..8bfa45c
--- /dev/null
+++ b/backend-java/services/trade-service/pom.xml
@@ -0,0 +1,53 @@
+
+
+ 4.0.0
+
+
+ com.xlxumu
+ backend-java
+ 1.0.0
+
+
+ trade-service
+ 1.0.0
+ jar
+
+ trade-service
+ 交易服务
+
+
+
+ org.springframework.boot
+ spring-boot-starter-web
+
+
+
+ org.springframework.boot
+ spring-boot-starter-data-jpa
+
+
+
+ mysql
+ mysql-connector-java
+ runtime
+
+
+
+ org.springframework.boot
+ spring-boot-starter-test
+ test
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+
+
\ No newline at end of file
diff --git a/backend-java/services/trade-service/src/main/java/com/xlxumu/trade/TradeServiceApplication.java b/backend-java/services/trade-service/src/main/java/com/xlxumu/trade/TradeServiceApplication.java
new file mode 100644
index 0000000..8cf2e59
--- /dev/null
+++ b/backend-java/services/trade-service/src/main/java/com/xlxumu/trade/TradeServiceApplication.java
@@ -0,0 +1,11 @@
+package com.xlxumu.trade;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class TradeServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(TradeServiceApplication.class, args);
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/trade-service/src/main/resources/application.properties b/backend-java/services/trade-service/src/main/resources/application.properties
new file mode 100644
index 0000000..5c26d1f
--- /dev/null
+++ b/backend-java/services/trade-service/src/main/resources/application.properties
@@ -0,0 +1,10 @@
+server.port=8083
+
+spring.datasource.url=jdbc:mysql://localhost:3306/xlxumu_trade?useSSL=false&serverTimezone=UTC
+spring.datasource.username=root
+spring.datasource.password=
+spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
+
+spring.jpa.hibernate.ddl-auto=update
+spring.jpa.show-sql=true
+spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL8Dialect
\ No newline at end of file
diff --git a/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/JwtInterceptor.java b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/JwtInterceptor.java
new file mode 100644
index 0000000..37562bd
--- /dev/null
+++ b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/JwtInterceptor.java
@@ -0,0 +1,47 @@
+package com.xlxumu.user.config;
+
+import com.xlxumu.user.util.JwtUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+import org.springframework.web.servlet.HandlerInterceptor;
+
+import javax.servlet.http.HttpServletRequest;
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+
+@Component
+public class JwtInterceptor implements HandlerInterceptor {
+
+ @Autowired
+ private JwtUtil jwtUtil;
+
+ @Override
+ public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws IOException {
+ // 获取请求头中的Authorization字段
+ String authorizationHeader = request.getHeader("Authorization");
+
+ // 检查Authorization字段是否存在且以"Bearer "开头
+ if (authorizationHeader != null && authorizationHeader.startsWith("Bearer ")) {
+ // 提取JWT令牌
+ String token = authorizationHeader.substring(7);
+
+ try {
+ // 验证令牌
+ Long userId = jwtUtil.getUserIdFromToken(token);
+ // 将用户ID添加到请求属性中,以便在控制器中使用
+ request.setAttribute("userId", userId);
+ return true;
+ } catch (Exception e) {
+ // 令牌无效
+ response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
+ response.getWriter().write("{\"code\": 401, \"message\": \"无效的访问令牌\"}");
+ return false;
+ }
+ } else {
+ // 缺少Authorization字段或格式不正确
+ response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
+ response.getWriter().write("{\"code\": 401, \"message\": \"缺少访问令牌\"}");
+ return false;
+ }
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/WebConfig.java b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/WebConfig.java
new file mode 100644
index 0000000..429c8e7
--- /dev/null
+++ b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/config/WebConfig.java
@@ -0,0 +1,22 @@
+package com.xlxumu.user.config;
+
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.context.annotation.Configuration;
+import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
+import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
+
+@Configuration
+public class WebConfig implements WebMvcConfigurer {
+
+ @Autowired
+ private JwtInterceptor jwtInterceptor;
+
+ @Override
+ public void addInterceptors(InterceptorRegistry registry) {
+ // 注册JWT拦截器,拦截除了注册和登录之外的所有API请求
+ registry.addInterceptor(jwtInterceptor)
+ .addPathPatterns("/api/**")
+ .excludePathPatterns("/api/users/register")
+ .excludePathPatterns("/api/users/login");
+ }
+}
\ No newline at end of file
diff --git a/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/controller/AddressController.java b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/controller/AddressController.java
new file mode 100644
index 0000000..34ff191
--- /dev/null
+++ b/backend-java/services/user-center-service/src/main/java/com/xlxumu/user/controller/AddressController.java
@@ -0,0 +1,175 @@
+package com.xlxumu.user.controller;
+
+import com.xlxumu.user.entity.Address;
+import com.xlxumu.user.service.AddressService;
+import com.xlxumu.user.util.JwtTokenUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.http.ResponseEntity;
+import org.springframework.web.bind.annotation.*;
+
+import javax.servlet.http.HttpServletRequest;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 收货地址控制器
+ * 处理收货地址相关的HTTP请求
+ *
+ * @author xlxumu
+ * @since 2024-01-15
+ */
+@RestController
+@RequestMapping("/api/addresses")
+public class AddressController {
+
+ @Autowired
+ private AddressService addressService;
+
+ @Autowired
+ private JwtTokenUtil jwtTokenUtil;
+
+ /**
+ * 创建收货地址接口
+ */
+ @PostMapping
+ public ResponseEntity