With WooCommerce 2.4.13, I would like to obtain a list of orders (
WC_Order ) of certain customers (
WC_Customer , not only the current logged-in customer ). From the documentation, the class
WC_Customer has no public property / function to access associated order records.
How can I achieve this? the only solution I can think of is to fetch the raw data from the database. Any better solution?
p.s. It seems it’s difficult to obtain the list of WooCommerce customers as well.