5

I have a simple component which uses lightning:recordViewForm My component loads fine with proper data, however I am getting this error:

Action failed: lightning:recordViewForm$controller$handleRecordIdChange [Cannot read property 'querySelectorAll' of null]

<aura:component implements="flexipage:availableForRecordHome,force:hasRecordId,force:hasSObjectName" access="global" >
    <aura:attribute name="sObjectName" type="String" />
    <aura:attribute name="acctRecId" type="Id" />
    <aura:attribute name="recordId" type="Id" />
    <aura:attribute name="recFields" type="Object" />

    <force:recordData aura:Id="fullRecord"
                      recordId="{!v.recordId}"
                      layoutType="FULL"
                      targetFields="{!v.recFields}"                      
                      />
    <lightning:card title="Internship Work Site Details:" iconName="standard:account">
        <div class="slds-p-around_x-small">                
            <lightning:recordViewForm recordId="{!v.recFields.InternshipWorkSite__c}" objectApiName="Internship_Work_Site__c">         
                <lightning:outputField fieldName="Name" />
                <lightning:outputField fieldName="Amount__c" />
                <lightning:outputField fieldName="Price_Per_Seat__c" />
                <lightning:outputField fieldName="Specialty__c" />                                           
            </lightning:recordViewForm>
        </div>
    </lightning:card>

</aura:component>

Error: enter image description here

Lightning Debug:

DOMException: Failed to execute 'querySelectorAll' on 'Element': '*,:x' is not a valid selector. at chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:1361:7 at assert (chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:930:12) at Sizzle.setDocument (chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:1331:3) at chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:2742:1 at chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:2797:3 at chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:36:3 at chrome-extension://lapbbfoohlcmlbdaakldmmallcbcbpjb/js/jquery/jquery.js:40:4

1
  • did you figured it out? i was getting the same error and when I looked in the tags js file then I realised that the Id is not getting bind at run time due to which the onload js fire and cause this popup.
    – user614946
    Apr 1, 2018 at 9:22

0

You must log in to answer this question.

Browse other questions tagged .