diff --git a/platformapi/dadaapi/order_test.go b/platformapi/dadaapi/order_test.go index a92b8639..81e7663d 100644 --- a/platformapi/dadaapi/order_test.go +++ b/platformapi/dadaapi/order_test.go @@ -45,7 +45,7 @@ import ( //} // func TestCancel(t *testing.T) { - cancelResponse, err := dadaapi.CancelOrder("1100551162883899675", ReasonIDOther, "协商一致") + cancelResponse, err := dadaapi.CancelOrder("1100632781686164762", ReasonIDOther, "协商一致") if err != nil { t.Fatal(err) } diff --git a/platformapi/mtwmapi/act_test.go b/platformapi/mtwmapi/act_test.go index a6381d98..0f123b26 100644 --- a/platformapi/mtwmapi/act_test.go +++ b/platformapi/mtwmapi/act_test.go @@ -84,7 +84,7 @@ func TestRetailDiscountBatchSave(t *testing.T) { } func TestRetailDiscountList(t *testing.T) { - result, err := api.RetailDiscountList("8694203", RetailActTypeSecKill) + result, err := api.RetailDiscountList("9202390", RetailActTypeSecKill) if err != nil { t.Fatal(err) } diff --git a/platformapi/mtwmapi/bill_list_test.go b/platformapi/mtwmapi/bill_list_test.go index 77b0af36..cad6e24b 100644 --- a/platformapi/mtwmapi/bill_list_test.go +++ b/platformapi/mtwmapi/bill_list_test.go @@ -8,10 +8,10 @@ import ( func TestBillList(t *testing.T) { now := time.Now() - from := time.Date(now.Year(), now.Month(), now.Day()-8, 0, 0, 0, 0, time.Local) - to := time.Date(now.Year(), now.Month(), now.Day()-2, 23, 59, 59, 59, time.Local) + from := time.Date(now.Year(), now.Month(), now.Day()-7, 0, 0, 0, 0, time.Local) + to := time.Date(now.Year(), now.Month(), now.Day()-1, 23, 59, 59, 59, time.Local) param := &Bill{ - AppPoiCode: "7379574", + AppPoiCode: "9202390", StartDate: from.Unix(), EndDate: to.Unix(), Offset: 0, diff --git a/platformapi/tao_vegetable/order_afs.go b/platformapi/tao_vegetable/order_afs.go index d08f88e5..96d3cc5b 100644 --- a/platformapi/tao_vegetable/order_afs.go +++ b/platformapi/tao_vegetable/order_afs.go @@ -247,6 +247,10 @@ func (a *API) QueryBillList(req *request591.AlibabaWdkBillListRequest) (*domain5 globals.SugarLogger.Debugf("requestId[%s],err[%s]", data.RequestId, utils.Format4Output(data, false)) return nil, fmt.Errorf(*data.ApiResult.ErrMsg) } + kk := *data.ApiResult.Model + for _, v := range *kk.TxdBillDetailBOS { + globals.SugarLogger.Debugf("kk := %s -- %s == %s", utils.Format4Output(v.BizOrderId, false), *v.OrderType, *v.ReceivableAmount) + } return data.ApiResult.Model, nil } diff --git a/platformapi/tao_vegetable/order_test.go b/platformapi/tao_vegetable/order_test.go index e4e4f357..c7719009 100644 --- a/platformapi/tao_vegetable/order_test.go +++ b/platformapi/tao_vegetable/order_test.go @@ -196,6 +196,27 @@ func TestDeliveryTrajectory(t *testing.T) { apiTao.DeliveryTrajectory(param) } -func TestS(t *testing.T) { - fmt.Println(1 % 20) +func TestQueryBillList(t *testing.T) { + queryData := time.Now() + create := time.Date(queryData.Year(), queryData.Month(), queryData.Day()-7, 0, 0, 0, 0, queryData.Location()) + end := time.Date(queryData.Year(), queryData.Month(), queryData.Day(), 23, 59, 59, 59, queryData.Location()) + createTime := util.LocalTime(create) + endTime := util.LocalTime(end) + param := &request591.AlibabaWdkBillListRequest{ + TxdBillListGetRequest: &domain591.AlibabaWdkBillListTxdBillListGetRequest{ + EndBillDate: &endTime, + StartBillDate: &createTime, + ShopCode: utils.String2Pointer("JX668594"), + PageSize: utils.Int64ToPointer(200), + PageIndex: utils.Int64ToPointer(1), + }, + } + + data, err := apiTao.QueryBillList(param) + if err != nil { + fmt.Println("err === ", err) + return + } + + globals.SugarLogger.Debugf("data:= %s", utils.Format4Output(data, false)) } diff --git a/platformapi/tao_vegetable/sdk/ability591/domain/AlibabaWdkBillListTxdBillDetailBo.go b/platformapi/tao_vegetable/sdk/ability591/domain/AlibabaWdkBillListTxdBillDetailBo.go index b6a5354c..672ebc94 100644 --- a/platformapi/tao_vegetable/sdk/ability591/domain/AlibabaWdkBillListTxdBillDetailBo.go +++ b/platformapi/tao_vegetable/sdk/ability591/domain/AlibabaWdkBillListTxdBillDetailBo.go @@ -42,7 +42,7 @@ type AlibabaWdkBillListTxdBillDetailBo struct { BizOrderId *string `json:"biz_order_id,omitempty" ` /* - 单据类型(正/逆向) */ + 单据类型(正/逆向) positive 有效订单/negative取消订单 */ OrderType *string `json:"order_type,omitempty" ` /* diff --git a/platformapi/tao_vegetable/store_categary.go b/platformapi/tao_vegetable/store_categary.go index 9c58bb92..5aa26819 100644 --- a/platformapi/tao_vegetable/store_categary.go +++ b/platformapi/tao_vegetable/store_categary.go @@ -71,7 +71,7 @@ func (a *API) AddStoreCategoryInfo(param *request.AlibabaWdkSkuCategoryAddReques // DeleteStoreCategoryInfo 删除门店分类 func (a *API) DeleteStoreCategoryInfo(param *request.AlibabaWdkSkuCategoryDeleteRequest) error { - //return nil // 不支持程序删除 + return nil // 不支持程序删除 globals.SugarLogger.Debugf("进入 DeleteStoreCategoryInfo") storeCategory := ability587.NewAbility587(&a.client) resp, _ := storeCategory.AlibabaWdkSkuCategoryDelete(param, a.token) diff --git a/platformapi/uuptapi/uupt_test.go b/platformapi/uuptapi/uupt_test.go index b97e8117..f3f4b870 100644 --- a/platformapi/uuptapi/uupt_test.go +++ b/platformapi/uuptapi/uupt_test.go @@ -83,7 +83,7 @@ func TestAddOrder(t *testing.T) { //获取订单详情 func TestGetOrderDetail(t *testing.T) { - detail, err := api.GetOrderDetail("23022310041019000003804258") + detail, err := api.GetOrderDetail("23071316101004700004743106") fmt.Println(utils.Format4Output(detail, false)) orderPrice := utils.Str2Float64(detail.OrderPrice) priceOff := utils.Str2Float64(detail.PriceOff)