WC_Customer_Data_Store_Interface
in
WC Customer Data Store Interface
Functions that must be defined by customer store classes.
Tags
Table of Contents
- get_last_order() : WC_Order|false
- Gets the customers last order.
- get_order_count() : int
- Return the number of orders this customer has.
- get_total_spent() : float
- Return how much money this customer has spent.
Methods
get_last_order()
Gets the customers last order.
public
get_last_order(WC_Customer &$customer) : WC_Order|false
Parameters
- $customer : WC_Customer
-
Customer object.
Return values
WC_Order|false —get_order_count()
Return the number of orders this customer has.
public
get_order_count(WC_Customer &$customer) : int
Parameters
- $customer : WC_Customer
-
Customer object.
Return values
int —get_total_spent()
Return how much money this customer has spent.
public
get_total_spent(WC_Customer &$customer) : float
Parameters
- $customer : WC_Customer
-
Customer object.