This commit is contained in:
suyl
2021-06-15 11:38:29 +08:00
parent c6275b162f
commit 78aa612a50

View File

@@ -4,7 +4,6 @@ import (
"git.rosy.net.cn/baseapi/utils" "git.rosy.net.cn/baseapi/utils"
"git.rosy.net.cn/jx-callback/globals" "git.rosy.net.cn/jx-callback/globals"
beego "github.com/astaxie/beego/server/web" beego "github.com/astaxie/beego/server/web"
"net/http"
) )
type PrintController struct { type PrintController struct {
@@ -17,12 +16,12 @@ type CallBackPrint struct {
} }
func (c *PrintController) Msg() { func (c *PrintController) Msg() {
if c.Ctx.Input.Method() == http.MethodPost { //if c.Ctx.Input.Method() == http.MethodPost {
callBackPrint := &CallBackPrint{} callBackPrint := &CallBackPrint{}
globals.SugarLogger.Debugf("print callback callbackResponse:%s", utils.Format4Output(c.Ctx.Request, true)) globals.SugarLogger.Debugf("print callback callbackResponse:%s", utils.Format4Output(c.Ctx.Request, true))
c.Data["json"] = callBackPrint c.Data["json"] = callBackPrint
c.ServeJSON() c.ServeJSON()
} else { //} else {
c.Abort("404") // c.Abort("404")
} //}
} }