Dedicated to the Hydrogen framework, headless commerce, and building custom storefronts using the Storefront API.
We've been building a customer storefront and about to launch soon.
Notice during testing today that since we rolled into 2021, that when logged in, customers only see the orders placed in 2021 not the 2020 ones?
Just using a typical `customer()` graphQL query along these lines:-
customer(customerAccessToken: $token) {
id
orders(first: $first, after:$afterCursor, reverse: true) {
pageInfo {
hasNextPage
hasPreviousPage
}
edges {
cursor
node { ...
Anyone else noticed this and know how to grab orders back before 2021?
Solved! Go to the solution
This is an accepted solution.
Strange, just tested mine and it's giving me the expected result (orders from 2021 and 2020), test query below:
customer(customerAccessToken: $customerAccessToken) {
orders(first: 100, reverse: true) {
edges {
node {
id
orderNumber
processedAt
}
}
}
}
Using the xx.myshopify.com/api/2021-01/graphql.json endpoint.
This is an accepted solution.
Strange, just tested mine and it's giving me the expected result (orders from 2021 and 2020), test query below:
customer(customerAccessToken: $customerAccessToken) {
orders(first: 100, reverse: true) {
edges {
node {
id
orderNumber
processedAt
}
}
}
}
Using the xx.myshopify.com/api/2021-01/graphql.json endpoint.
So turned out to be an unrelated bug in the frontend, that happened to affect the the last order of 2020.
Thanks for reassuring me it wasn't a problem with the backend at least.