woocommerce_migrate_country_states_for_orders_batch_size

FILTER woocommerce\src\Database\Migrations\MigrationHelper.php (ligne 180) github
Filters the value of N, where the maximum count of database records that will be updated in one single run of migrate_country_states_for_orders is N*2*count($old_to_new_states_mapping) if the woocommerce_orders table exists, or N*count($old_to_new_states_mapping) otherwise.

Paramètres

Entrée :
100, $country_code, $old_to_new_states_mapping
Sortie :
@param int $batch_size Default value for the count of records to update.
@param string $country_code Country code for the update.
@param array  $old_to_new_states_mapping Associative array of old to new state codes.

Utilisation

// Modifier la valeur avec le filtre 'woocommerce_migrate_country_states_for_orders_batch_size'
add_filter('woocommerce_migrate_country_states_for_orders_batch_size', 'ma_fonction_filtre', 10, 1);

function ma_fonction_filtre(100) {
    // Modifier la valeur
    return 100;
}

Actualités

Chargement des actualités...