Merge pull request #15952 from woocommerce/add-filter-parameter-15923
Pass $column_id into export filter
This commit is contained in:
commit
b0a9c5a9c2
|
@ -152,7 +152,7 @@ class WC_Product_CSV_Exporter extends WC_CSV_Batch_Exporter {
|
||||||
|
|
||||||
// Filter for 3rd parties.
|
// Filter for 3rd parties.
|
||||||
if ( has_filter( "woocommerce_product_export_{$this->export_type}_column_{$column_id}" ) ) {
|
if ( has_filter( "woocommerce_product_export_{$this->export_type}_column_{$column_id}" ) ) {
|
||||||
$value = apply_filters( "woocommerce_product_export_{$this->export_type}_column_{$column_id}", '', $product );
|
$value = apply_filters( "woocommerce_product_export_{$this->export_type}_column_{$column_id}", '', $product, $column_id );
|
||||||
|
|
||||||
// Handle special columns which don't map 1:1 to product data.
|
// Handle special columns which don't map 1:1 to product data.
|
||||||
} elseif ( is_callable( array( $this, "get_column_value_{$column_id}" ) ) ) {
|
} elseif ( is_callable( array( $this, "get_column_value_{$column_id}" ) ) ) {
|
||||||
|
|
Loading…
Reference in New Issue