Merge pull request #25093 from JoryHogeveen/patch-1
Before and after product list hooks
This commit is contained in:
commit
eefab9d672
|
@ -33,6 +33,8 @@ do_action( 'woocommerce_before_add_to_cart_form' ); ?>
|
||||||
'price',
|
'price',
|
||||||
), $product );
|
), $product );
|
||||||
|
|
||||||
|
do_action( 'woocommerce_grouped_product_list_before', $grouped_product_columns, $quantites_required, $product );
|
||||||
|
|
||||||
foreach ( $grouped_products as $grouped_product_child ) {
|
foreach ( $grouped_products as $grouped_product_child ) {
|
||||||
$post_object = get_post( $grouped_product_child->get_id() );
|
$post_object = get_post( $grouped_product_child->get_id() );
|
||||||
$quantites_required = $quantites_required || ( $grouped_product_child->is_purchasable() && ! $grouped_product_child->has_options() );
|
$quantites_required = $quantites_required || ( $grouped_product_child->is_purchasable() && ! $grouped_product_child->has_options() );
|
||||||
|
@ -90,6 +92,8 @@ do_action( 'woocommerce_before_add_to_cart_form' ); ?>
|
||||||
}
|
}
|
||||||
$post = $previous_post; // WPCS: override ok.
|
$post = $previous_post; // WPCS: override ok.
|
||||||
setup_postdata( $post );
|
setup_postdata( $post );
|
||||||
|
|
||||||
|
do_action( 'woocommerce_grouped_product_list_after', $grouped_product_columns, $quantites_required, $product );
|
||||||
?>
|
?>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
Loading…
Reference in New Issue