1
This commit is contained in:
@@ -121,6 +121,7 @@ func (c *BaseScheduler) SelfDeliverDelivering(order *model.GoodsOrder, userName
|
||||
partner.CurOrderManager.OnOrderMsg(order, "SelfDeliverDelivering 调用[SelfDeliverDelivering]转自送", err.Error())
|
||||
}
|
||||
|
||||
if order.VendorID == model.VendorIDMTWM {
|
||||
// 转自送同时取消平台订单(美团才做这个操作)
|
||||
if _, err := partner.GetPurchasePlatformFromVendorID(order.VendorID).GetCancelDeliveryReason(order); err != nil {
|
||||
partner.CurOrderManager.OnOrderMsg(order, "订单转自送取消美团平台发单获取理由失败", err.Error())
|
||||
@@ -138,6 +139,7 @@ func (c *BaseScheduler) SelfDeliverDelivering(order *model.GoodsOrder, userName
|
||||
} else {
|
||||
partner.CurOrderManager.OnOrderMsg(order, "美团外卖转自送成功.", "")
|
||||
}
|
||||
}
|
||||
|
||||
return err
|
||||
}, "SelfDeliverDelivering orderID:%s", order.VendorOrderID)
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
package controllers
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/bidding"
|
||||
"git.rosy.net.cn/jx-callback/business/model"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"github.com/astaxie/beego/server/web"
|
||||
)
|
||||
|
||||
@@ -28,7 +32,7 @@ func (c *BiddingController) GetBiddingMsg() {
|
||||
})
|
||||
}
|
||||
|
||||
// 获取退货账单
|
||||
// GetRefundOrderList 获取退货账单
|
||||
// @Title 获取招标信息
|
||||
// @Description 获取招标信息
|
||||
// @Param token header string true "认证token"
|
||||
@@ -43,3 +47,37 @@ func (c *BiddingController) GetRefundOrderList() {
|
||||
return data, "", err
|
||||
})
|
||||
}
|
||||
|
||||
// GetStoreBindStatus 查询门店是否绑定成功,成功之后创建本地门店
|
||||
// 查询门店是否绑定成功,成功之后创建本地门店
|
||||
// @Title 查询门店是否绑定成功,成功之后创建本地门店
|
||||
// @Description 查询门店是否绑定成功,成功之后创建本地门店
|
||||
// @Param token header string true "认证token"
|
||||
// @Param platformId query string false "授权成功平台id"
|
||||
// @Param platformType query int false "授权平台id"
|
||||
// @Success 200 {object} controllers.CallResult
|
||||
// @Failure 200 {object} controllers.CallResult
|
||||
// @router /GetStoreBindStatus [get]
|
||||
func (c *BiddingController) GetStoreBindStatus() {
|
||||
c.callGetStoreBindStatus(func(params *tBindGetStoreBindStatusParams) (interface{}, string, error) {
|
||||
switch params.PlatformType {
|
||||
case model.VendorIDMTWM:
|
||||
data, err := api.Mtwm2API.GetBoundList(params.PlatformId)
|
||||
if err != nil {
|
||||
return nil, "", err
|
||||
}
|
||||
for _, v := range data {
|
||||
if v.AppID == utils.Str2Int(params.PlatformId) {
|
||||
return data, "", nil
|
||||
}
|
||||
}
|
||||
return nil, "", errors.New("未查询到绑定数据,请检查美团门店id是否正确")
|
||||
case model.VendorIDEBAI:
|
||||
|
||||
case model.VendorIDJD:
|
||||
case model.VendorIDTT:
|
||||
|
||||
}
|
||||
return nil, "", nil
|
||||
})
|
||||
}
|
||||
|
||||
@@ -4069,6 +4069,14 @@ func init() {
|
||||
MethodParams: param.Make(),
|
||||
Filters: nil,
|
||||
Params: nil})
|
||||
web.GlobalControllerRouter["git.rosy.net.cn/jx-callback/controllers:BiddingController"] = append(web.GlobalControllerRouter["git.rosy.net.cn/jx-callback/controllers:BiddingController"],
|
||||
web.ControllerComments{
|
||||
Method: "GetStoreBindStatus",
|
||||
Router: `/GetStoreBindStatus`,
|
||||
AllowHTTPMethods: []string{"get"},
|
||||
MethodParams: param.Make(),
|
||||
Filters: nil,
|
||||
Params: nil})
|
||||
|
||||
// 创建会话,客户群
|
||||
web.GlobalControllerRouter["git.rosy.net.cn/jx-callback/controllers:SessionController"] = append(web.GlobalControllerRouter["git.rosy.net.cn/jx-callback/controllers:SessionController"],
|
||||
|
||||
Reference in New Issue
Block a user