Automattic\WooCommerce\Admin\Notes
DataStore::get_note_ids_by_type
Find the ids of all notes with a given type.
Method of the class: DataStore{}
No Hooks.
Returns
Array. An array of matching note ids.
Usage
$DataStore = new DataStore(); $DataStore->get_note_ids_by_type( $note_type );
- $note_type(string) (required)
- Type to search for.
DataStore::get_note_ids_by_type() DataStore::get note ids by type code WC 10.6.2
public function get_note_ids_by_type( $note_type ) {
global $wpdb;
return $wpdb->get_col(
$wpdb->prepare(
"SELECT note_id FROM {$wpdb->prefix}wc_admin_notes WHERE type = %s ORDER BY note_id ASC",
$note_type
)
);
}