1
This commit is contained in:
@@ -23,7 +23,7 @@ func init() {
|
||||
// sandbox
|
||||
// api = New("594ab45a-9a73-4a43-82b0-a64cbd55d883", "06692746f7224695ad4788ce340bc854", "d6b42a35a7414a5490d811654d745c84")
|
||||
// prod
|
||||
api = New("73e2e9f6-b21e-4dcd-8c92-71e4e100b07e", "21b627c23ea04c69b64b48d0b361213e", "51cd27a748e64c829b4b7f83f4844610")
|
||||
api = New("73e2e9f6-b21e-4dcd-8c92-71e4e100b07e", "1dba76d40cac446ca500c0391a0b6c9d", "a88d031a1e7b462cb1579f12e97fe7f4")
|
||||
// 天天果园
|
||||
//api = New("c45e6510-00ba-4be2-977e-bcb9c9792cc7", "5d5577a2506f41b8b4ec520ba83490f5", "0b01b9eeb15b41dab1c3d05d95c17a26")
|
||||
// 京东果园
|
||||
|
||||
@@ -30,7 +30,7 @@ func TestPickUp(t *testing.T) {
|
||||
|
||||
func TestOrderQuery(t *testing.T) {
|
||||
jdParams := map[string]interface{}{
|
||||
"orderId": "813344594000041",
|
||||
"orderId": "2225712287000273",
|
||||
}
|
||||
result, totalCount, err := api.OrderQuery(jdParams)
|
||||
if err != nil {
|
||||
@@ -94,7 +94,7 @@ func TestDeliveryEndOrder(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetAfsService(t *testing.T) {
|
||||
result, err := api.GetAfsService("34081924")
|
||||
result, err := api.GetAfsService("2225735125000294")
|
||||
if err != nil {
|
||||
t.Fatal(err.Error())
|
||||
}
|
||||
@@ -138,7 +138,7 @@ func TestOrderQuery2(t *testing.T) {
|
||||
}
|
||||
|
||||
func TestGetByOrderNoForOaos(t *testing.T) {
|
||||
orderList, err := api.GetByOrderNoForOaos("2108504597000531")
|
||||
orderList, err := api.GetByOrderNoForOaos("2225735125000294")
|
||||
t.Log(utils.Format4Output(orderList, false))
|
||||
if err != nil {
|
||||
t.Fatal(err.Error())
|
||||
|
||||
@@ -31,30 +31,31 @@ func TestDelVipPrice(t *testing.T) {
|
||||
// t.Log(utils.Format4Output(result, false))
|
||||
}
|
||||
|
||||
func TestQueryOpenUseable(t *testing.T) {
|
||||
result, err := api.QueryOpenUseable([]*BaseStockCenterRequest{
|
||||
&BaseStockCenterRequest{
|
||||
StationNo: mustExistStoreID,
|
||||
SkuId: mustExistSkuID,
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(utils.Format4Output(result, false))
|
||||
}
|
||||
|
||||
func TestQueryStockCenter(t *testing.T) {
|
||||
result, err := api.QueryStockCenter(mustExistStoreJXID, []*SkuIdEntity{
|
||||
&SkuIdEntity{
|
||||
OutSkuId: mustExistSkuJXID,
|
||||
},
|
||||
}, "test")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(utils.Format4Output(result, false))
|
||||
}
|
||||
//
|
||||
//func TestQueryOpenUseable(t *testing.T) {
|
||||
// result, err := api.QueryOpenUseable([]*BaseStockCenterRequest{
|
||||
// &BaseStockCenterRequest{
|
||||
// StationNo: mustExistStoreID,
|
||||
// SkuId: mustExistSkuID,
|
||||
// },
|
||||
// })
|
||||
// if err != nil {
|
||||
// t.Fatal(err)
|
||||
// }
|
||||
// t.Log(utils.Format4Output(result, false))
|
||||
//}
|
||||
//
|
||||
//func TestQueryStockCenter(t *testing.T) {
|
||||
// result, err := api.QueryStockCenter(mustExistStoreJXID, []*SkuIdEntity{
|
||||
// &SkuIdEntity{
|
||||
// OutSkuId: mustExistSkuJXID,
|
||||
// },
|
||||
// }, "test")
|
||||
// if err != nil {
|
||||
// t.Fatal(err)
|
||||
// }
|
||||
// t.Log(utils.Format4Output(result, false))
|
||||
//}
|
||||
|
||||
func TestBatchUpdateVendibility(t *testing.T) {
|
||||
result, err := api.BatchUpdateVendibility("", "100130", "", []*StockVendibility{
|
||||
|
||||
@@ -1,5 +1,10 @@
|
||||
package jdapi
|
||||
|
||||
import (
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"testing"
|
||||
)
|
||||
|
||||
//
|
||||
//import (
|
||||
// "testing"
|
||||
@@ -42,14 +47,15 @@ package jdapi
|
||||
// }
|
||||
//}
|
||||
//
|
||||
//func TestGetStoreInfoByStationNo(t *testing.T) {
|
||||
// result, err := api.GetStoreInfoByStationNo2("11946249")
|
||||
// if err != nil {
|
||||
// t.Fatal(err)
|
||||
// }
|
||||
// t.Log(utils.Format4Output(result, false))
|
||||
//
|
||||
//}
|
||||
func TestGetStoreInfoByStationNo(t *testing.T) {
|
||||
result, err := api.GetStoreInfoByStationNo2("12002719")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
t.Log(utils.Format4Output(result, false))
|
||||
|
||||
}
|
||||
|
||||
//
|
||||
//func TestUpdateStoreInfo4Open(t *testing.T) {
|
||||
// result, err := api.GetStoreInfoByStationNo2(mustExistStoreID)
|
||||
|
||||
Reference in New Issue
Block a user