Automattic\WooCommerce\Internal\Admin\Orders
ListTable::get_bulk_actions()
Retrieves the list of bulk actions available for this table.
Method of the class: ListTable{}
No Hooks.
Return
Array
.
Usage
// protected - for code of main (parent) or child class $result = $this->get_bulk_actions();
ListTable::get_bulk_actions() ListTable::get bulk actions code WC 9.6.1
protected function get_bulk_actions() { $selected_status = $this->order_query_args['status'] ?? false; if ( array( 'trash' ) === $selected_status ) { $actions = array( 'untrash' => __( 'Restore', 'woocommerce' ), 'delete' => __( 'Delete permanently', 'woocommerce' ), ); } else { $actions = array( 'mark_processing' => __( 'Change status to processing', 'woocommerce' ), 'mark_on-hold' => __( 'Change status to on-hold', 'woocommerce' ), 'mark_completed' => __( 'Change status to completed', 'woocommerce' ), 'mark_cancelled' => __( 'Change status to cancelled', 'woocommerce' ), 'trash' => __( 'Move to Trash', 'woocommerce' ), ); } if ( wc_string_to_bool( get_option( 'woocommerce_allow_bulk_remove_personal_data', 'no' ) ) ) { $actions['remove_personal_data'] = __( 'Remove personal data', 'woocommerce' ); } return $actions; }