You need to sign in to do that
Don't have an account?
Brooks Johnson 6
Build A Conference Management App Build a Lightning Component
I do not seem to have any errors in my code. But when I go to override the Edit button my Lightning Component is not visible. The dropdown reads none. Where did I go wrong?
<aura:component implements="flexipage:availableForRecordHome,force:hasRecordId" access="global" > <aura:attribute name = "speaker" type = "Speaker__c" /> <aura:attribute name = "recordId" type="String" /> <div class = "slds-p-bottom_large slds-p-left_large" style = "width:600px"> <lightning:recordEditForm aura:id = "recordViewForm" recordId = "{!v.recordId}" recordTypeId = "{!v.speaker}" objectApiName ="Speaker__c" onSuccess ="{!c.onSuccess}"> <lightning:messages/> <lightning:inputField fieldName ="First_Name__c"/> <lightning:inputField fieldName = "Last_Name__c"/> <lightning:inputField fieldName = "Email__c" /> <Lightning:InputField fieldName = "Bio__c" /> <Lightning:button aura:id = "submit" type = "submit" label="Update Speaker" class = "slds-m-top_medium"/> </lightning:recordEditForm> </div> </aura:component>
<aura:component implements="flexipage:availableForRecordHome,force:hasRecordId" access="global" > <aura:attribute name = "speaker" type = "Speaker__c" /> <aura:attribute name = "recordId" type="String" /> <div class = "slds-p-bottom_large slds-p-left_large" style = "width:600px"> <lightning:recordEditForm aura:id = "recordViewForm" recordId = "{!v.recordId}" recordTypeId = "{!v.speaker}" objectApiName ="Speaker__c" onSuccess ="{!c.onSuccess}"> <lightning:messages/> <lightning:inputField fieldName ="First_Name__c"/> <lightning:inputField fieldName = "Last_Name__c"/> <lightning:inputField fieldName = "Email__c" /> <Lightning:InputField fieldName = "Bio__c" /> <Lightning:button aura:id = "submit" type = "submit" label="Update Speaker" class = "slds-m-top_medium"/> </lightning:recordEditForm> </div> </aura:component>
Make sure that while creating the component you have selected the Lightning Record Page.
Name the component SpeakerForm, select Lightning Record Page, and select Submit.
Please mark it as solved if my reply was helpful, it will make it available
for others as a proper solution.
Best Regards,
Sandhya