woocommerce_admin_meta_boxes_variations_per_page

woocommerce_admin_meta_boxes_variations_per_page

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.9.5.1

apply_filters('woocommerce_admin_meta_boxes_variations_per_page') is found 2 times:

  • /includes/admin/class-wc-admin-assets.php line 313
    					'i18n_scheduled_sale_end'             => esc_js( __( 'Sale end date (YYYY-MM-DD format or leave blank)', 'woocommerce' ) ),
    					'i18n_edited_variations'              => esc_js( __( 'Save changes before changing page?', 'woocommerce' ) ),
    					'i18n_variation_count_single'         => esc_js( __( '1 variation', 'woocommerce' ) ),
    					'i18n_variation_count_plural'         => esc_js( __( '%qty% variations', 'woocommerce' ) ),
    					'variations_per_page'                 => absint( apply_filters( 'woocommerce_admin_meta_boxes_variations_per_page', 15 ) ),
    				);
    
    				wp_localize_script( 'wc-admin-variation-meta-boxes', 'woocommerce_admin_meta_boxes_variations', $params );
    			}
    			/* phpcs: enable */
    			if ( $this->is_order_meta_box_screen( $screen_id ) ) {
    
  • /includes/admin/meta-boxes/class-wc-meta-box-product-data.php line 177
    		/* phpcs:disable WooCommerce.Commenting.CommentHooks.MissingHookComment */
    		$variation_attributes   = array_filter( $product_object->get_attributes(), array( __CLASS__, 'filter_variation_attributes' ) );
    		$default_attributes     = $product_object->get_default_attributes();
    		$variations_count       = absint( apply_filters( 'woocommerce_admin_meta_boxes_variations_count', $wpdb->get_var( $wpdb->prepare( "SELECT COUNT(ID) FROM $wpdb->posts WHERE post_parent = %d AND post_type = 'product_variation' AND post_status IN ('publish', 'private')", $post->ID ) ), $post->ID ) );
    		$variations_per_page    = absint( apply_filters( 'woocommerce_admin_meta_boxes_variations_per_page', 15 ) );
    		$variations_total_pages = ceil( $variations_count / $variations_per_page );
    		$modal_title            = get_bloginfo( 'name' ) . __( ' says', 'woocommerce' );
    		/* phpcs: enable */
    
    		include __DIR__ . '/views/html-product-data-variations.php';
    	}