Automattic\WooCommerce\Database\Migrations\CustomOrderTable
PostToOrderAddressTableMigrator::get_where_clause_for_verification
Helper function to generate where clause for fetching data for verification.
Метод класса: PostToOrderAddressTableMigrator{}
Хуков нет.
Возвращает
Строку. WHERE clause.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->get_where_clause_for_verification( $source_ids );
- $source_ids(массив) (обязательный)
- Array of IDs from source table.
Код PostToOrderAddressTableMigrator::get_where_clause_for_verification() PostToOrderAddressTableMigrator::get where clause for verification WC 10.4.3
protected function get_where_clause_for_verification( $source_ids ) {
global $wpdb;
$query = parent::get_where_clause_for_verification( $source_ids );
// phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared -- $query should already be prepared, $schema_config is hardcoded.
return $wpdb->prepare( "$query AND {$this->schema_config['destination']['table_name']}.address_type = %s", $this->type );
}