|
你的数据我拿来测试了一下,发现订单最终日期请求时间是1月份的 ,我这边使用该代码测试使用工具和调试工具返回的数据都是一样的都是2018-5-10~2018-5-11数据都是9条,你可以填写您的token测试一下
- public static void main(String[] args) throws ParseException {
- // TODO Auto-generated method stub
- YZClient client = new DefaultYZClient(new Token("")); //new Sign(appKey, appSecret)
- YouzanTradesSoldGetParams youzanTradesSoldGetParams = new YouzanTradesSoldGetParams();
- // SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-DD HH:mm:ss");
- // Date StartCreateTime = sdf.parse("2018-5-11 00:00:00");
- //创建时间
- String StartCreateTime = new String("2018-5-10 01:00:00");
- SimpleDateFormat format;
- format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
- Date date = format.parse(StartCreateTime);
- System.out.println(date);
- youzanTradesSoldGetParams.setStartCreated(date);
- //结束时间
- String EndCreateTime = new String("2018-5-11 00:00:00");
- SimpleDateFormat format1 ;
- format1 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
- Date date1 = format1.parse(EndCreateTime);
- System.out.println(date1);
-
- // Date EndCreateTime = sdf.parse("2018-5-12 00:00:00");
- youzanTradesSoldGetParams.setEndCreated(date1);
- YouzanTradesSoldGet youzanTradesSoldGet = new YouzanTradesSoldGet();
- youzanTradesSoldGet.setAPIParams(youzanTradesSoldGetParams);
- YouzanTradesSoldGetResult result = client.invoke(youzanTradesSoldGet);
- System.out.println(JSON.toJSONString(result));
- }
- }
复制代码
|
|
|
|
|
|
|