Filtering the Product List

You can define custom filters to reduce the number of products listed when you select a price book on the Add Products page. The Add Products page is displayed when you add line items via the Lightning component related list on a plan, contract, or billing document.

You define custom filters using Salesforce custom metadata. Refer to the Salesforce documentation for information about the permissions required to create custom metadata.

To filter the product list:

  1. Go to Setup | Custom Metadata Types | BC Filter and click Manage Records.
  2. Click New to create a new BC Filter record.
  3. Complete the BC Filter details:
    • Enter a label and name for the filter.
    • Set the filter's purpose to Add Product Drop-Down.
    • Set the object to Product. (Custom filters for any other object are ignored.)
    • Select the field you want to filter on.
    • Choose the condition you want to use in the filter.
    • Enter the value you want to apply to the condition. See Wildcard Support.
    • Select the Active checkbox.
  4. Save the filter.
  5. If required, repeat steps 2-4 to create additional filters.

Once you have created and activated a BC Filter no further setup is required.

If there are multiple active filters, a product must match all the filters to be included in the product list.

You can deselect a filter's Active checkbox at any time to stop the filter being applied. If there are no active filters, filtering is not applied to the product list.

Wildcard Support

When entering a value for the filter, note that the % and _ characters are treated as wildcards when used with the Contains or Does not contain condition:

  • % represents zero or more characters
  • _ represents one character

For example, a product named 'Handset' would match both the following filters:
Name Contains h%d
Name Contains h_n