|
@@ -7,6 +7,7 @@ import (
|
|
"github.com/silenceper/wechat/v2/credential"
|
|
"github.com/silenceper/wechat/v2/credential"
|
|
"github.com/silenceper/wechat/v2/officialaccount"
|
|
"github.com/silenceper/wechat/v2/officialaccount"
|
|
"github.com/silenceper/wechat/v2/officialaccount/config"
|
|
"github.com/silenceper/wechat/v2/officialaccount/config"
|
|
|
|
+ "github.com/silenceper/wechat/v2/officialaccount/js"
|
|
"github.com/silenceper/wechat/v2/officialaccount/user"
|
|
"github.com/silenceper/wechat/v2/officialaccount/user"
|
|
"hongze/hongze_yb/global"
|
|
"hongze/hongze_yb/global"
|
|
"hongze/hongze_yb/models/tables/wx_token"
|
|
"hongze/hongze_yb/models/tables/wx_token"
|
|
@@ -90,6 +91,14 @@ func GetUserInfo(openid string) (userInfo *user.Info, err error) {
|
|
return
|
|
return
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+// GetJsConfig 获取公众号jsConfig
|
|
|
|
+func GetJsConfig(signUrl string) (jsConf *js.Config, err error) {
|
|
|
|
+ wechatClient := GetWxChat()
|
|
|
|
+ j := wechatClient.GetJs()
|
|
|
|
+ jsConf, err = j.GetConfig(signUrl)
|
|
|
|
+ return
|
|
|
|
+}
|
|
|
|
+
|
|
type WechatAccessToken struct {
|
|
type WechatAccessToken struct {
|
|
}
|
|
}
|
|
|
|
|