Embedded Canvas Apps

Challenge #3: One-to-many relationships

Challenge #3

Displaying records of a one-to-many relationship by filtering the related entity based on the ModelDrivenFormIntegration control results in the unfiltered list of related records being displayed first for a couple of seconds. The list then gets filtered to only show one-to-many records related to the contextual record. The following formula to display related contacts of an Account although correct results in this bad user experience.

Filter(Contacts, 'Company Name' = [@ModelDrivenFormIntegration].Item)

One-to-many relationship by filtering the related entity (click to enlarge)

Trick #3

Using the ModelDrivenFormIntegration control directly to fetch the related entity's records leads to a much better user experience as then the list of filtered records is displayed without flashing the unfiltered list first. This formula works best to display related records in a one-to-many relationship.

[@ModelDrivenFormIntegration].Item.Contacts

One-to-many relationship using ModelDrivenFormIntegration control (click to enlarge)

Have fun! Get addicted!

1 thought on “Challenge #3: One-to-many relationships”

Leave a Reply