Automattic\WooCommerce\Admin\Features\Blueprint\Exporters

ExportWCShipping::get_steps_for_locations()privateWC 1.0

Retrieve shipping zone locations.

Метод класса: ExportWCShipping{}

Хуков нет.

Возвращает

Массив. Steps for shipping zone locations.

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

// private - только в коде основоного (родительского) класса
$result = $this->get_steps_for_locations(): array;

Код ExportWCShipping::get_steps_for_locations() WC 9.8.5

private function get_steps_for_locations(): array {
	global $wpdb;

	return array_map(
		fn( $location ) => new RunSql( Util::array_to_insert_sql( $location, $wpdb->prefix . 'woocommerce_shipping_zone_locations', 'replace into' ) ),
		$wpdb->get_results( "SELECT * FROM {$wpdb->prefix}woocommerce_shipping_zone_locations", ARRAY_A )
	);
}