gpi_always_show_inventory_limit_in_editor

  1. Description
  2. Usage
  3. Parameters
  4. Examples
    1. Always use inventory limit in Form Editor
  5. Since

Description

Force the Form Editor to always show the Inventory Limit for choices, products, and resources rather than the current inventory.

Usage

add_filter( 'gpi_always_show_inventory_limit_in_editor', '__return_true' );

Parameters

  • always_show_limit_in_editor boolean

    Whether to always show the limit instead of current inventory in the Form Editor. Default: false.

Examples

Always use inventory limit in Form Editor

<?php
/**
 * Gravity Perks // Inventory // Show Inventory Limit in Form Editor
 * https://gravitywiz.com/documentation/gravity-forms-inventory/
 *
 * By default the current inventory is shown in the form editor.
 * Use this filter to show the inventory limit.
 */
add_filter( 'gpi_always_show_inventory_limit_in_editor', '__return_true' );

Since

This filter is available since Gravity Forms Inventory 1.0-beta-1.0.