If you want to disable the datatables for one or more specific products you can use the “woocommerce_variations_table_datatables_enabled” filter like below.

In this example the products with ID 549 and 22 do not use the datatables.

function disable_datatable($enabled) {
	global $product;
	$product_id = $product->get_id();

	if($product_id == 549 || $product_id == 22) {
		$enabled = "0";
	}
	return $enabled;
}
add_filter( 'woocommerce_variations_table_datatables_enabled', 'disable_datatable', 10, 1 );

Deja una respuesta

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *