How would I hide the "Add to Cart" button if the product line item already exists in [user] orders?
The situation is an online course, where the a user will buy access to a node. But once they have brought it, they still need to go back to the node to view the content. But we do not want to show the "Add to Cart" button as they have already brought it.
There is a very similar question here: Hide price and add to cart form for purchased product But this only hides the Cart button for 1 SKU. How would this be modified to look at all SKUs in [user]'s orders and hide "add to Cart"?