WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

ActionScheduler_Abstract_ListTable::prepare_items() public WC 1.0

Prepares the data to feed WP_Table_List.

Ищем WP-разработчика! Фулл-тайм, удаленка, хорошая зарплата, соц. пакет. Подробности.
Компания Boosta.

This has the core for selecting, sorting and filting data. To keep the code simple its logic is split among many methods (get_items_query_*).

Beside populating the items this function will also count all the records that matches the filtering criteria and will do fill the pagination variables.

{} Это метод класса: ActionScheduler_Abstract_ListTable{}

Хуков нет.

Возвращает

null. Ничего.

Использование

$ActionScheduler_Abstract_ListTable = new ActionScheduler_Abstract_ListTable();
$ActionScheduler_Abstract_ListTable->prepare_items();

Код ActionScheduler_Abstract_ListTable::prepare_items() WC 5.8.0

public function prepare_items() {
	global $wpdb;

	$this->process_bulk_action();

	$this->process_row_actions();

	if ( ! empty( $_REQUEST['_wp_http_referer'] ) ) {
		// _wp_http_referer is used only on bulk actions, we remove it to keep the $_GET shorter
		wp_redirect( remove_query_arg( array( '_wp_http_referer', '_wpnonce' ), wp_unslash( $_SERVER['REQUEST_URI'] ) ) );
		exit;
	}

	$this->prepare_column_headers();

	$limit   = $this->get_items_query_limit();
	$offset  = $this->get_items_query_offset();
	$order   = $this->get_items_query_order();
	$where   = array_filter(array(
		$this->get_items_query_search(),
		$this->get_items_query_filters(),
	));
	$columns = '`' . implode( '`, `', $this->get_table_columns() ) . '`';

	if ( ! empty( $where ) ) {
		$where = 'WHERE ('. implode( ') AND (', $where ) . ')';
	} else {
		$where = '';
	}

	$sql = "SELECT $columns FROM {$this->table_name} {$where} {$order} {$limit} {$offset}";

	$this->set_items( $wpdb->get_results( $sql, ARRAY_A ) );

	$query_count = "SELECT COUNT({$this->ID}) FROM {$this->table_name} {$where}";
	$total_items = $wpdb->get_var( $query_count );
	$per_page    = $this->get_items_per_page( $this->package . '_items_per_page', $this->items_per_page );
	$this->set_pagination_args( array(
		'total_items' => $total_items,
		'per_page'    => $per_page,
		'total_pages' => ceil( $total_items / $per_page ),
	) );
}