Action
rpress_pre_get_customers
On this page
Fires before customers are retrieved.
Fires in RPRESS_Customer_Query::get_items() before the cache key is computed and the customer rows are fetched. The query object is passed by reference so its query vars can still be changed.
Available since RestroPress 1.0.0.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$query | RPRESS_Customer_Query | The query instance, passed by reference. |
Example#
function my_pre_get_customers( $query ) {
$query->query_vars['order'] = 'ASC';
}
add_action( 'rpress_pre_get_customers', 'my_pre_get_customers' );
Source#
Fired from:
includes/class-rpress-customer-query.php(line 288), inRPRESS_Customer_Query::get_items()
See also#
Was this page helpful?
