I thought I share some more news on what is coming to v2 of CoCart. Progress is being made the project is not dead though with the release of v3.6 of WooCommerce I thought it was going to be but that was solved quickly.
Now one popular request was to get a specific customers cart. I thought this might be a difficult challenge maybe by creating a new cart table in the database but it turns out WooCommerce already has a feature that is probably only known to those who read the whole of the WooCommerce source code.
So those with administrator capabilities can now add a new parameter for the customers ID number. When called it will get the cart contents from that specific customer from when they were logged in last. I don’t see any other user role that would need to access a customers cart. Feel free to comment below if you feel otherwise.
FYI
However, this feature will only work if the site owner has left persistent cart enabled and the session has not cleared or expired. If no cart data is stored for that customer it will fallback to the cart in use.
On top of that I have also applied a filter that allows you to apply additional information to return for the items in the cart.
Version 2 is still in development so please come back for more news as it develops.
Thank you.