1
This commit is contained in:
@@ -4,7 +4,6 @@ import (
|
||||
"encoding/json"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/jxstore/secretNumber"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
"io/ioutil"
|
||||
)
|
||||
@@ -26,7 +25,6 @@ func (c *AliApiController) SecretNumberMsg() {
|
||||
var res *secretNumber.SecretNumberMsgRes
|
||||
for k, _ := range mapData {
|
||||
if err := json.Unmarshal([]byte(k), &res); err == nil {
|
||||
globals.SugarLogger.Debugf("SecretNumberMsg msg: %v", utils.Format4Output(res, true))
|
||||
secretNumber.CallbackBrandBill(res)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -116,7 +116,6 @@ func (c *Auth2Controller) TiktokDecrypt() {
|
||||
// @router /Login [post]
|
||||
func (c *Auth2Controller) Login() {
|
||||
c.callLogin(func(params *tAuth2LoginParams) (retVal interface{}, errCode string, err error) {
|
||||
globals.SugarLogger.Debug("params.AuthType==============", params.AuthType)
|
||||
if params.AuthType == auth2.AuthTypeMobile {
|
||||
params.AuthIDType = auth2.UserIDMobile
|
||||
} else if params.AuthType == auth2.AuthTypeEmail {
|
||||
@@ -136,7 +135,6 @@ func (c *Auth2Controller) Login() {
|
||||
ctx := auth2.NewContext(c.Ctx.ResponseWriter, c.Ctx.Request)
|
||||
globals.SugarLogger.Debug("params.AuthType, params.AuthID, params.AuthIDType, params.AuthSecret==============", params.AuthType, params.AuthID, params.AuthIDType, params.AuthSecret)
|
||||
authInfo, err := auth2.Login(ctx, params.AuthType, params.AuthID, params.AuthIDType, params.AuthSecret)
|
||||
globals.SugarLogger.Debug("authInfo==============", authInfo)
|
||||
// TODO 兼容没有取到authid2的错误
|
||||
if err == nil && authInfo.AuthBindInfo != nil {
|
||||
if authInfo.AuthBindInfo.AuthID2 == "" {
|
||||
@@ -348,7 +346,6 @@ func (c *Auth2Controller) AddAuthBindWithMobile() {
|
||||
if err != nil {
|
||||
return retVal, "", err
|
||||
}
|
||||
globals.SugarLogger.Debug("打印newAuthInfo==============", newAuthInfo)
|
||||
err = auth2.AddAuthBindWithMobile(newAuthInfo, params.Mobile)
|
||||
return retVal, "", err
|
||||
})
|
||||
|
||||
@@ -9,8 +9,6 @@ import (
|
||||
"git.rosy.net.cn/jx-callback/business/model/dao"
|
||||
"time"
|
||||
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
)
|
||||
@@ -54,7 +52,6 @@ func (c *DDAPIController) Sign() {
|
||||
str := "jsapi_ticket=" + ddapi.Ticket +
|
||||
"&noncestr=" + params.NonceStr + "×tamp=" + params.TimeStamp + "&url=" + params.Url
|
||||
retVal = fmt.Sprintf("%x", sha1.Sum([]byte(str)))
|
||||
globals.SugarLogger.Debugf("dingapi str:%s sign:%v", str, retVal)
|
||||
}
|
||||
return retVal, "", err
|
||||
})
|
||||
|
||||
@@ -20,7 +20,6 @@ type EnterpriseController struct {
|
||||
// 消息结构体将使用创建应用时的EncodingAESKey进行加密(特别注意, 在第三方回调事件中使用加解密算法,receiveid的内容为suiteid)
|
||||
// ,请参考接收消息解析数据包。
|
||||
func (e *EnterpriseController) EnterpriseCallback() {
|
||||
globals.SugarLogger.Debug("==============企业微信通知回调")
|
||||
r := e.Ctx.Request
|
||||
switch e.Ctx.Request.Method {
|
||||
case http.MethodPost:
|
||||
|
||||
@@ -7,8 +7,6 @@ import (
|
||||
|
||||
"git.rosy.net.cn/jx-callback/business/partner/purchase/jdshop"
|
||||
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
)
|
||||
@@ -25,7 +23,6 @@ func (c *JdsController) Msg() {
|
||||
if err == nil {
|
||||
jdshop.OnCallbackMsg(call)
|
||||
}
|
||||
globals.SugarLogger.Debugf("jds callback callbackResponse:%s", utils.Format4Output(call, true))
|
||||
c.Data["json"] = call
|
||||
c.ServeJSON()
|
||||
} else {
|
||||
|
||||
@@ -2,9 +2,7 @@ package controllers
|
||||
|
||||
import (
|
||||
"git.rosy.net.cn/baseapi/platformapi/mtwmapi"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/partner/purchase/mtwm"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
)
|
||||
@@ -16,7 +14,6 @@ type MtwmController struct {
|
||||
func (c *MtwmController) onCallbackMsg(msgType string) {
|
||||
c.Data["json"] = mtwmapi.Err2CallbackResponse(nil, "")
|
||||
msg, callbackResponse := api.MtwmAPI.GetCallbackMsg(c.Ctx.Request)
|
||||
globals.SugarLogger.Debug(utils.Format4Output(msg, true))
|
||||
if callbackResponse == nil {
|
||||
callbackResponse = mtwm.OnCallbackMsg(msg)
|
||||
if callbackResponse == nil {
|
||||
|
||||
@@ -7,10 +7,7 @@ import (
|
||||
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/partner/purchase/jx/localjx"
|
||||
"git.rosy.net.cn/jx-callback/globals"
|
||||
|
||||
"github.com/astaxie/beego/server/web"
|
||||
"github.com/astaxie/beego/server/web/context"
|
||||
)
|
||||
@@ -22,7 +19,6 @@ type TongLianController struct {
|
||||
func (c *TongLianController) Msg() {
|
||||
if c.Ctx.Input.Method() == http.MethodPost {
|
||||
call, err := api.TLpayAPI.GetCallbackMsg(getUsefulRequest2(c.Ctx))
|
||||
globals.SugarLogger.Debugf("tonglianapi callback callbackResponse:%s", utils.Format4Output(call, true))
|
||||
if err == nil {
|
||||
err = localjx.OnTLPayCallback(call)
|
||||
}
|
||||
|
||||
@@ -31,7 +31,6 @@ func (c *WeimobController) onCallbackMsg() {
|
||||
}
|
||||
|
||||
func (c *WeimobController) Code() {
|
||||
globals.SugarLogger.Debugf("WeimobController code, code:%s, state:%s", c.GetString("code"), c.GetString("state"))
|
||||
state := c.GetString("state")
|
||||
if state == globals.WeimobStateSecret { // 防止有人故意搞坏,添加一个secret
|
||||
code := c.GetString("code")
|
||||
|
||||
Reference in New Issue
Block a user