Magento 2 REST搜索订单

时间:2016-10-26 20:43:57

标签: magento magento2

我正在使用Magento 2 REST API。我试图根据日期创建的订单列表。我想要从10月12日到10月13日创建订单。我的网址会发送所有已创建的订单,即使是2014年的订单。我的网址有什么问题?

/休息/ V1 /订单searchCriteria [filter_groups] [0] [过滤器] [0] [字段] = created_at&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [值] = 2016-10- 26T04:00:00.0000000Z&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [condition_type]从&安培=; searchCriteria [filter_groups] [0] [过滤器] [1] [字段] = created_at&安培; searchCriteria [filter_groups] [ 0] [过滤器] [1] [值] = 2016-10-27T03:59:00.0000000Z&安培; searchCriteria [filter_groups] [0] [过滤器] [1] [condition_type] =至&安培; searchCriteria [当前第] = 1&安培; searchCriteria [pageSize的] = 100

如果我省略这一部分,我会收到来自以下地址的订单:

/休息/ V1 /订单searchCriteria [filter_groups] [0] [过滤器] [0] [字段] = created_at&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [值] = 2016-10- 26T04:00:00.0000000Z&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [condition_type]从

=

1 个答案:

答案 0 :(得分:1)

这是正确的网址

/休息/ V1 /订单searchCriteria [filter_groups] [0] [过滤器] [0] [字段] = created_at&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [值] = 2016-10- 11T04:00:00.0000000Z&安培; searchCriteria [filter_groups] [0] [过滤器] [0] [condition_type]从&安培=; searchCriteria [filter_groups] [1] [过滤器] [0] [字段] = created_at&安培; searchCriteria [filter_groups] [ 1] [过滤器] [0] [值] = 2016-10-12T03:59:00.0000000Z&安培; searchCriteria [filter_groups] [1] [过滤器] [0] [condition_type] =至&安培; searchCriteria [当前第] = 1&安培; searchCriteria [pageSize的] = 100