From 724b92c21c90425ea0e0767051a107f2c47f7ca9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Fri, 7 Aug 2020 09:56:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=AC=E4=B8=9C=E5=95=86=E5=9F=8E=E8=AE=A2?= =?UTF-8?q?=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- platformapi/jdshopapi/order.go | 2 +- platformapi/jdshopapi/store_page_test.go | 18 +++++++++--------- platformapi/mtpsapi/shop_test.go | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/platformapi/jdshopapi/order.go b/platformapi/jdshopapi/order.go index 576bf368..591d6837 100644 --- a/platformapi/jdshopapi/order.go +++ b/platformapi/jdshopapi/order.go @@ -105,7 +105,7 @@ func (a *API) GetOrder(orderID int64, isStatus bool) (getOrderResult *GetOrderRe params["optional_fields"] = `orderType,payType,orderTotalPrice,orderSellerPrice, orderPayment,freightPrice,orderState,orderStateRemark, orderStartTime,orderEndTime,orderRemark,consigneeInfo, - itemInfoList,pauseBizInfo,pin,idSopShipmenttype` + itemInfoList,pauseBizInfo,pin,idSopShipmenttype,scDT` if isStatus { params["order_state"] = "WAIT_SELLER_STOCK_OUT,PAUSE,TRADE_CANCELED" } diff --git a/platformapi/jdshopapi/store_page_test.go b/platformapi/jdshopapi/store_page_test.go index bbe707ef..57151748 100644 --- a/platformapi/jdshopapi/store_page_test.go +++ b/platformapi/jdshopapi/store_page_test.go @@ -43,16 +43,16 @@ func TestNewInfoList(t *testing.T) { } func Test11(t *testing.T) { - type StrA struct { - Cat string `json:"cat"` - Dog int `json:"dog,omitempty"` - Mouse int `json:"mouse"` + change := func(s ...string) { + s[0] = "Go" + s = append(s, "playground") + fmt.Println(s) } - a := &StrA{ - Cat: "加菲", - } - fmt.Println(utils.Format4Output(a, false)) - fmt.Println(a.Dog == 0, a.Mouse) + + welcome := []string{"hello", "world"} + change(welcome...) + fmt.Println(welcome) + } func TestAllOrders(t *testing.T) { diff --git a/platformapi/mtpsapi/shop_test.go b/platformapi/mtpsapi/shop_test.go index 99732a22..4b307bc5 100644 --- a/platformapi/mtpsapi/shop_test.go +++ b/platformapi/mtpsapi/shop_test.go @@ -18,7 +18,7 @@ func TestShopQuery(t *testing.T) { // if err == nil { // t.Fatal("应该报错找不到门店") // } - shopInfo, err := api.ShopQuery("11732425") + shopInfo, err := api.ShopQuery("667446") if err != nil { t.Fatal(err) }