-
Notifications
You must be signed in to change notification settings - Fork 132
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
李鹏军
committed
Sep 20, 2023
1 parent
e9cd186
commit c1a538c
Showing
5 changed files
with
130 additions
and
111 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 0 additions & 30 deletions
30
platform-api/src/main/java/com/platform/util/ApiUserUtils.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
29 changes: 29 additions & 0 deletions
29
platform-common/src/main/java/com/platform/service/WeixinMaService.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package com.platform.service; | ||
|
||
import cn.binarywang.wx.miniapp.api.impl.WxMaServiceImpl; | ||
import cn.binarywang.wx.miniapp.config.impl.WxMaDefaultConfigImpl; | ||
import com.platform.utils.ResourceUtil; | ||
import org.springframework.stereotype.Service; | ||
|
||
import javax.annotation.PostConstruct; | ||
|
||
/** | ||
* @author pengjun | ||
*/ | ||
@Service | ||
public class WeixinMaService extends WxMaServiceImpl { | ||
|
||
@PostConstruct | ||
public void init() { | ||
final WxMaDefaultConfigImpl config = new WxMaDefaultConfigImpl(); | ||
// 设置微信公众号的appid | ||
config.setAppid(ResourceUtil.getConfigByName("wx.appId")); | ||
// 设置微信公众号的app corpSecret | ||
config.setSecret(ResourceUtil.getConfigByName("wx.secret")); | ||
// // 设置微信公众号的token | ||
// config.setToken(ResourceUtil.getConfigByName("wx.token")); | ||
// // 设置消息加解密密钥 | ||
// config.setAesKey(ResourceUtil.getConfigByName("wx.aesKey")); | ||
super.setWxMaConfig(config); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters