27 lines
413 B
Go
27 lines
413 B
Go
package controllers
|
|
|
|
import (
|
|
"net/http"
|
|
|
|
"git.rosy.net.cn/jx-callback/globals/api"
|
|
|
|
"github.com/astaxie/beego"
|
|
)
|
|
|
|
type FnController struct {
|
|
beego.Controller
|
|
}
|
|
|
|
func (c *FnController) Msg() {
|
|
if c.Ctx.Input.Method() == http.MethodPost {
|
|
msg := api.FnAPI.GetOrderCallbackMsg(c.Ctx.Request)
|
|
if msg != nil {
|
|
fn.OnWaybillMsg(msg)
|
|
}
|
|
c.Data["json"] = ""
|
|
c.ServeJSON()
|
|
} else {
|
|
c.Abort("404")
|
|
}
|
|
}
|