1
This commit is contained in:
@@ -3,6 +3,12 @@ package controllers
|
||||
import (
|
||||
"crypto/md5"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"sort"
|
||||
"strings"
|
||||
|
||||
"git.rosy.net.cn/baseapi/platformapi/tao_vegetable"
|
||||
"git.rosy.net.cn/baseapi/platformapi/tiktok_shop/tiktok_api"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
@@ -12,11 +18,6 @@ import (
|
||||
taoVegetable "git.rosy.net.cn/jx-callback/business/partner/purchase/tao_vegetable"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
"io/ioutil"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"sort"
|
||||
"strings"
|
||||
)
|
||||
|
||||
type TaoBaoVegetableController struct {
|
||||
@@ -224,19 +225,10 @@ func (c *TaoBaoVegetableController) CancelOnSaleRefundOrder() {
|
||||
return
|
||||
}
|
||||
default:
|
||||
//callbackResponse := taoVegetable.OnCallbackMsg(tao_vegetable.OrderStatusOnSaleCancel, utils.Int64ToStr(afsOrder.PartCancelRequest.BizOrderId), afsOrder)
|
||||
//c.Data["json"] = callbackResponse
|
||||
order, err := partner.CurOrderManager.LoadOrder(utils.Int64ToStr(afsOrder.PartCancelRequest.BizOrderId), model.VendorIDTaoVegetable)
|
||||
if err != nil {
|
||||
c.Data["json"] = tao_vegetable.CallBackResultOnSaleCancel(nil)
|
||||
c.ServeJSON()
|
||||
return
|
||||
}
|
||||
if order.Status == model.OrderStatusCanceled {
|
||||
c.Data["json"] = tao_vegetable.CallBackResultOnSaleCancel(nil)
|
||||
c.ServeJSON()
|
||||
return
|
||||
}
|
||||
|
||||
if order.Status >= model.OrderStatusDelivering {
|
||||
if err != nil || order.Status >= model.OrderStatusDelivering {
|
||||
c.Data["json"] = tao_vegetable.CallBackResultOnSaleCancel(fmt.Errorf("不支持售中取消"))
|
||||
c.ServeJSON()
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user