LightningFlowComponents icon indicating copy to clipboard operation
LightningFlowComponents copied to clipboard

DataTable - Master-Detail field showing the id instead of the Master's Name

Open jessepink opened this issue 1 year ago • 2 comments

I have an object, "Sales Order Lines" that has a Master-Detail relationship with another object "Sales Order", that when I try to include that field in the datatable for Sales Order Lines, it just shows the id text instead of the expected Name field on the Sales Order record (which is what it does for Lookup fields.). object field flow example

jessepink avatar Oct 09 '24 16:10 jessepink

In order for a lookup or master/detail field to display as a link, it must be “reparentable”

In order to have the Datatable display a Lookup field as a link to the record rather than just the recordId value in the field, the running User must have Edit access to the object whose records are being displayed in the Datatable. For example, if you have a Datatable for Contact records and include the AccountId(Lookup) field, the running User needs to have Edit access for the Contact object in order for the AccountId field to show as a clickable link with the Account’s Name. Without Edit access to the Contact record, the Datatable will display, as unclickable, the Account’s recordId value. For information on how you can temporarily add then remove Edit access in a Flow, read the referenced Help Article and/or complete the referenced Trailhead. Help Article: Create a Flow That Can Activate or Deactivate a Session-Based Permission Set Trailhead: Session-Based Permission Sets and Security

Running User has Edit access to the Contact object image

Running User does not have Edit access to the Contact object image

ericrsmith35 avatar Oct 09 '24 17:10 ericrsmith35

i have a similar situation, my org has a large managed package where i cannot change the lookup field to be reparentable

ive had to create a formula text field to get the link to show right.

'HYPERLINK("Sales Order", "/" + CASESAFEID( Sales_Order__c ) )'

scanlan111 avatar Oct 09 '24 19:10 scanlan111