diff --git a/.idea/vcs.xml b/.idea/vcs.xml
deleted file mode 100644
index 94a25f7..0000000
--- a/.idea/vcs.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
-
-
-
-
\ No newline at end of file
diff --git a/mini_program.iml b/mini_program.iml
index a80f8af..1833589 100644
--- a/mini_program.iml
+++ b/mini_program.iml
@@ -2,7 +2,10 @@
-
+
+
+
+
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index a9a1031..f3dde24 100644
--- a/pom.xml
+++ b/pom.xml
@@ -44,6 +44,20 @@
test
+
+
+ org.junit.jupiter
+ junit-jupiter
+ test
+
+
+
+
+ org.mockito
+ mockito-junit-jupiter
+ test
+
+
com.mysql
@@ -63,6 +77,13 @@
json
20231013
+
+
+
+ com.h2database
+ h2
+ test
+
@@ -80,6 +101,13 @@
+
+ org.apache.maven.plugins
+ maven-surefire-plugin
+
+ integration
+
+
diff --git a/src/main/java/com/example/mini_program/service/WxLoginService.java b/src/main/java/com/example/mini_program/service/WxLoginService.java
index 3f2cf5c..b862649 100644
--- a/src/main/java/com/example/mini_program/service/WxLoginService.java
+++ b/src/main/java/com/example/mini_program/service/WxLoginService.java
@@ -19,9 +19,9 @@ public class WxLoginService {
private final WxMiniAppConfig wxMiniAppConfig;
private final RestTemplate restTemplate;
- public WxLoginService(WxMiniAppConfig wxMiniAppConfig) {
+ public WxLoginService(WxMiniAppConfig wxMiniAppConfig, RestTemplate restTemplate) {
this.wxMiniAppConfig = wxMiniAppConfig;
- this.restTemplate = new RestTemplate();
+ this.restTemplate = restTemplate;
}
/**
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index 590eb54..265d424 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -17,10 +17,20 @@ wx:
appid: wx50fe0c5c28dd3060
# 小程序AppSecret
secret: e82fa407fad13a9df35503f2d176e5a4
+ corp: # 企业ID
+ corpid: ww257614cff8a1b61b
+ # 应用Secret
+ corpsecret: 2B0TAefYVewqjVHprLdGJQ8fNHz1drJq6235xN-mqNI
+ # 审批模板ID
+ approval-template-id: C4ej9uEntM19iNJbrtJsUqZakPFfjBNTPNLSKPno2
+ # 审批回调URL(可选)
+ callback-url: http://your-domain.com/api/wx-corp/approval-callback
# MyBatis配置
mybatis:
mapper-locations: classpath:mapper/*.xml
type-aliases-package: com.example.mini_program.entity
configuration:
- map-underscore-to-camel-case: true
\ No newline at end of file
+ map-underscore-to-camel-case: true
+
+# 企业微信配置
\ No newline at end of file