Line Item Properties NOT adding to cart when using 'Buy Again' button

Within the New Customer Accounts interface, when a customer looks at a previous order, they can click the button “Buy Again” which re-adds the same products to a new cart.

However, any custom Line Item Properties that existed are completely lost. This “Buy Again” feature suddenly becomes fairly useless for products that required custom information.

Is this a design choice from Shopify or an oversight that needs to be addressed?

1 Like

Hey Sanico,

That does seem like a challenging limitation - I’ve flagged this to the product team for their recommendation and will update here once I hear back. Our product teams are currently on leave however, so there won’t be an update until early January.

This bug is genuinely frustrating, and a fix would be greatly appreciated as soon as possible. It would be helpful to know if this issue is already being addressed or has been resolved. Thanks!

Hi folks,

The product team are aware of this limitation for products which have custom line item properties, and is on their back-log to address. However there’s no ETA to share currently on this.

My solution here was to spin up an app extension for the order status page with a button that builds a checkout with the item and item properties on your order page. I then needed the current shopify but to be remove which Shopify can do through support by implementing a beta flag on their end.

1 Like

Thanks for posting this solution Craig!

any update on this? It is end of February now.

I dont think you can expect a fix very soon, let alone an update in this thread.

I think the best is to keep an eye at Recent changes to Shopify’s platform

1 Like

Hello @Craig_Scott
Could you please share how you managed to get this working? I have the checkoutURL for redirection, but I’m unable to make it redirect to checkout page. Any insights would be appreciated!

For me when I used the cartTransform mutations with my app it creates that checkoutURL and that goes to the checkout on it’s own. If you are asking how I actually used that url, I had it created in the app and then used that for the button link in the component I rendered on the order status page.

If you want it to go to the /cart url on your site instead of going directly to checkout you can also do that by using the cart/checkout token as a parameter in the link the /cart and it will rebuild it on the front end with some simple listeners.

If you have a more specific example of what you are trying to redirect I can try to give you a more direct answer for how I solved.

Thank you so much, @Craig_Scott, for your guidance! Taking your advice into account, I was able to create a checkout URL in the Customer Account UI Extension. However, I’m stuck on navigating to the cart page since the cart create mutation only provides a checkout URL in the response.

1 Like

From the cart create mutation I got the cart token. Then I set up the button to direct the user to ‘yourStoreUrl/cart?transferCartId=TOKEN’

Then the next step you could do with a script you add onsite, but I did it the following way so it would all be done with the app and not need extra steps.

In my app I created a very simple theme app extension. All it does it load a script on the cart page that gets that tokenid from the url parameter and uses it to set the cookie ‘cart’ to that token id.

Updating that cookie will build the cart for the customer and they will be able to shop as normal from that point.

Hi there,
the amount of extra work needed to copy over the line item attributes from previous orders is very cumbersome.
Do you have any ETA on when this bug will be fixed?