Automattic\WooCommerce\Database\Migrations\CustomOrderTable

PostsToOrdersMigrationController::verify_migrated_orders()publicWC 1.0

Verify whether the given order IDs were migrated properly or not.

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

No Hooks.

Return

Array. Array of failed IDs along with columns.

Usage

$PostsToOrdersMigrationController = new PostsToOrdersMigrationController();
$PostsToOrdersMigrationController->verify_migrated_orders( $order_post_ids ): array;
$order_post_ids(array) (required)
Order IDs.

Code of PostsToOrdersMigrationController::verify_migrated_orders() WC 7.1.0

public function verify_migrated_orders( array $order_post_ids ): array {
	$errors = array();
	foreach ( $this->all_migrators as $migrator ) {
		if ( method_exists( $migrator, 'verify_migrated_data' ) ) {
			$errors = $errors + $migrator->verify_migrated_data( $order_post_ids );
		}
	}
	return $errors;
}