Grid filter configuration tips

This topic describes various tips for configuration filters on grid pages.

Value from the parent entity filters configuration tips

When you are setting a grid page, and this page is embedded into a detail page, you normally want the records on this embedded grid to be filtered by the current record on the detail page. For this filtering to work, you need to set up filters differently depending on the origin of records on your portal.

In general, there are three scenarios for how records can be created on the portal:

  • Scenario A: Records that are created directly on the portal
  • Scenario B: Records that are synchronized from an ERP
  • Scenario C: A mix of records (both created on the portal and synchronized from an ERP) 

For each of these scenarios, you set up filters on an embedded grid page differently.

Scenario A: Records that are created directly on the portal

If, on an embedded grid page, records are only created on the portal, you normally set up a filter with the Value from the parent entity value type (when the filter value is taken from a field of the parent entity), where Value from the parent entity field = UniqueId [ParentEntityName], as well as Field = RelatedUniqueId (CurrentEntityName), to filter embedded grid records by the field value on the parent entity, which is enough in this case. 

Scenario B: Records that are synchronized from an ERP

If, on an embedded grid page, records are only synchronized from an ERP, set up filter(s) based on field values from the PortalMembers entity (use the Value-from member field name value type for this, which means that filter value is taken from the portal member settings). This filter will always be applied and cannot be empty. Use the AND filter logic for this filter.

For example:

A filter where the Sell-to Customer No./Customer No./Bill-to Customer No./No. field (the field depends on the used entity) = [member] CustomerId (PortalMembers).

  Note

This solution will be applicable if the PortalMembers entity and the entity that you want to use on the grid have the corresponding fields suitable for your business scenario. 

Scenario C: A mix of records (both created on the portal and synchronized from an ERP) 

For this scenario, you need to set up a combination of filters from scenario A (Value from the parent entity field = UniqueId [ParentEntityName] for records created on the portal) and scenario B (Value-from member field name = SomeField (PortalMembers)) for records that are synchronized from an ERP).

In this case, use the OR filter logic for the filter with Value-from member field name = SomeField (PortalMembers).