|
@ -17,6 +17,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
import org.springframework.web.bind.annotation.RequestMethod;
|
|
|
|
|
|
import java.io.BufferedReader;
|
|
import java.io.BufferedReader;
|
|
|
|
import java.io.File;
|
|
import java.io.FileInputStream;
|
|
import java.io.FileInputStream;
|
|
import java.io.InputStreamReader;
|
|
import java.io.InputStreamReader;
|
|
|
|
|
|
@ -45,6 +46,8 @@ public class WechatMenuController extends EnvelopRestEndpoint {
|
|
try {
|
|
try {
|
|
WxAccessTokenDO wxAccessTokenDO = wxAccessTokenService.getWxAccessTokenById(wechatId);
|
|
WxAccessTokenDO wxAccessTokenDO = wxAccessTokenService.getWxAccessTokenById(wechatId);
|
|
String filePath = "/usr/local/hospital/weixin_menu.txt";
|
|
String filePath = "/usr/local/hospital/weixin_menu.txt";
|
|
|
|
// String filePath = WechatCoreController.class.getResource("/").getPath() +
|
|
|
|
// File.separator + "wechat" + File.separator + "weixin_menu.txt";
|
|
logger.info("filePath"+filePath);
|
|
logger.info("filePath"+filePath);
|
|
String url = "https://api.weixin.qq.com/cgi-bin/menu/create?access_token=" + wxAccessTokenDO.getAccessToken();
|
|
String url = "https://api.weixin.qq.com/cgi-bin/menu/create?access_token=" + wxAccessTokenDO.getAccessToken();
|
|
// 读取微信菜单配置文件
|
|
// 读取微信菜单配置文件
|