Skip to main content
I am using lightning:recordEditForm to display form for User object, below is my code. OOTO_Delegate__c is a self lookup field. 

Upon printing error in console I see '{"message":"Cannot read property 'value' of undefined","detail":"","output":{},"error":{}}'

The field is also present on layout.

<lightning:recordEditForm

                                  onload="{!c.handleLoad}"

                                  onsuccess="{!c.handleSuccess}"

                                  onerror="{!c.handleError}"                  

                                  recordId="{!$SObjectType.CurrentUser.Id}"

                                  objectApiName="User">

            <lightning:messages />

            

            <lightning:inputField fieldName="Currently_OOTO__c" aura:id="currentooo"/>

          

            <lightning:inputField fieldName="OOTO_Delegate__c" />

            

            <div class="slds-m-top_medium">

                <lightning:button disabled="{!v.disabled}" variant="brand" type="submit" name="save" label="Save" />

            </div>

        </lightning:recordEditForm>

 
5 réponses
  1. 23 mars 2020, 15:21
    It was resolved by adding self lookup field to User Profile Layout.
0/9000