From 75c5d2eaa97e0feeebb3e71d3e136e10763361db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Tue, 28 Apr 2020 17:15:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=AC=E4=B8=9C=E5=A2=9E=E5=8A=A0=E5=9B=9E?= =?UTF-8?q?=E8=B0=83=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- controllers/jd_callback.go | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/controllers/jd_callback.go b/controllers/jd_callback.go index 71c51bfa5..3464acc39 100644 --- a/controllers/jd_callback.go +++ b/controllers/jd_callback.go @@ -217,15 +217,19 @@ func (c *DjswController) OrderAddTips() { c.orderStatus() } +// func (c *DjswController) OrderInfoChange() { +// if c.Ctx.Input.Method() == http.MethodPost { +// callbackResponse := c.handleMsg(func(a *jdapi.API, obj interface{}) (callbackResponse *jdapi.CallbackResponse) { +// callbackResponse = jd.OnOrderInfoChangeMsg(obj.(*jdapi.CallbackOrderInfoChangeMsg)) +// return callbackResponse +// }) +// c.Data["json"] = c.transferResponse("OrderInfoChange", callbackResponse) +// c.ServeJSON() +// } else { +// c.Abort("404") +// } +// } + func (c *DjswController) OrderInfoChange() { - if c.Ctx.Input.Method() == http.MethodPost { - callbackResponse := c.handleMsg(func(a *jdapi.API, obj interface{}) (callbackResponse *jdapi.CallbackResponse) { - callbackResponse = jd.OnOrderInfoChangeMsg(obj.(*jdapi.CallbackOrderInfoChangeMsg)) - return callbackResponse - }) - c.Data["json"] = c.transferResponse("OrderInfoChange", callbackResponse) - c.ServeJSON() - } else { - c.Abort("404") - } + c.orderStatus() }