1
This commit is contained in:
@@ -147,17 +147,21 @@ func (a *API) GetCallbackUrlIndex(request *http.Request) (map[string]interface{}
|
||||
}
|
||||
|
||||
var (
|
||||
urlIndex = ""
|
||||
temp = map[string]interface{}{}
|
||||
urlIndex = ""
|
||||
orderStatus float64
|
||||
temp = map[string]interface{}{}
|
||||
)
|
||||
if err = json.Unmarshal(data, &temp); err == nil {
|
||||
globals.SugarLogger.Debugf("GetCallbackUrlIndex temp=%s", utils.Format4Output(temp, false))
|
||||
urlIndex = temp["url_index"].(string)
|
||||
fmt.Println(urlIndex)
|
||||
orderStatus = temp["order_status"].(float64)
|
||||
globals.SugarLogger.Debugf("GetCallbackUrlIndex urlIndex=%s,orderStatus=%d", urlIndex, orderStatus)
|
||||
}
|
||||
|
||||
result := make(map[string]interface{}, 0)
|
||||
|
||||
if orderStatus == OrderStatusFinished {
|
||||
urlIndex = UrlIndexOrderComplete
|
||||
}
|
||||
switch urlIndex {
|
||||
case UrlIndexRiderStatus:
|
||||
retVal := RiderStatus{}
|
||||
|
||||
@@ -65,12 +65,12 @@ func TestCreateOrder(t *testing.T) {
|
||||
DevId: AppID,
|
||||
ShopId: TestSFStoreID,
|
||||
ShopType: 1,
|
||||
ShopOrderId: "20230908Test",
|
||||
ShopOrderId: "20230908-2",
|
||||
OrderSequence: "测试",
|
||||
OrderSource: OrderSourceELM,
|
||||
OrderTime: 1694163550,
|
||||
OrderTime: 1694165402,
|
||||
LbsType: LbsTypeGD,
|
||||
PushTime: 1694163550,
|
||||
PushTime: 1694165402,
|
||||
Version: 19,
|
||||
ReturnFlag: 511,
|
||||
Receive: &ReceiveAddress{
|
||||
|
||||
Reference in New Issue
Block a user