|
|
@@ -7,8 +7,8 @@ import (
|
|
|
"github.com/astaxie/beego"
|
|
|
|
|
|
"bytes"
|
|
|
- "io/ioutil"
|
|
|
"fohow.com/libs/tool"
|
|
|
+ "io/ioutil"
|
|
|
"net/http"
|
|
|
)
|
|
|
|
|
|
@@ -31,7 +31,7 @@ func GetXcxSessionKey(appId, appSecret, code string) *SessionKey {
|
|
|
url := fmt.Sprintf("https://api.weixin.qq.com/sns/jscode2session?appid=%s&secret=%s&js_code=%s&grant_type=authorization_code", appId, appSecret, code)
|
|
|
resp := tool.HttpCall(url, "GET", nil, nil)
|
|
|
var key *SessionKey
|
|
|
- beego.BeeLogger.Warn("GetXcxSessionKey resp: %s", resp)
|
|
|
+ //beego.BeeLogger.Warn("GetXcxSessionKey resp: %s", resp)
|
|
|
if err := json.Unmarshal([]byte(resp), &key); err != nil {
|
|
|
beego.BeeLogger.Error("GetXcxSessionKey parse query error:", err)
|
|
|
}
|