• Dimitri Mitsios
  • NEWBIE
  • 35 Points
  • Member since 2018


  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 6
    Replies
I am trying to use the 'Launch Flow in Modal' component in a Lightning Community. I'm placing this button on a Contact record detail page in the Community, and I want to pass the Contact Id to the flow as the input variable 'recordId'.

The options for the component include a field called Flow Input Variables, and the 'info' tooltip for that field gives a syntax example for a JSON string to set the variable that looks like this:

User-added image

I can't figure out how to get the record Id of the current contact from the contact detail page inserted into the flow.

First I tried
 
[{"name": "recordId", "type": "String", "value": {!Record.Id}}]

but that throws this error:
SyntaxError: JSON.parse: unexpected character at line 1 column 51 of the JSON data

I figured the brackets around the variable were the problem so I tried escaping them with backslashes:
 
[{"name": "recordId", "type": "String", "value": \{!Record.Id\}}]

but got the same error.

What's the right way to reference the Id of the current record from a community record detail page to pass to a flow?
  • August 31, 2020
  • Like
  • 1
I’m running into an issue with the new lightning:recordForm component available in Summer ’18 when more than one separately-rendered component uses the same method to retrieve a different list of fields.

Basic example: Let’s say you have one component
<aura:component implements="flexipage:availableForRecordHome,force:hasRecordId,force:hasSObjectName" access="global" >
    <aura:attribute name="recordId" type="String" />
   <aura:attribute name="fields" type="List" default="HomePhone,DoNotCall,Fax,HasOptedOutOfFax"/>
                    <lightning:recordForm 
                                      recordId="{!v.recordId}" 
                                      objectApiName="Contact" 
                                      fields="{!v.fields}"
                                      columns="2"/>
</aura:component>
Then there is an identical component with different fields:
<aura:attribute name="fields" type="List" default="Name,Phone,Email,HasOptedOutOfEmail"/>
You then put these on a lightning record page for your contacts and put them within your Tabs (or Accordion) component. If both components are placed in the same tab, they both render fine when that tab becomes active.

Here’s the issue. If I put them into different tabs, only the one in the first of the tabs that is opened renders properly. When you open the second tab, the recordForm component returns an error: “This record could not be loaded because it includes too many formula fields with complex formulas….”

Has anyone else tried this? Is this expected functionality? Is there a workaround?
Hi Gurus  ,

I have requirement i want make entire record read only if Status is changed to closed . 

Read only conditions apply all profiles no one able to edit the record . tell me best solution for this requirement .

please help me 

Thanks ,
Naveen K.