Created
February 24, 2018 14:53
-
-
Save lfreeland/ae21e962d49a3558fea997f251cf2757 to your computer and use it in GitHub Desktop.
Lightning Field Set Form V2 Markup
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <aura:component controller="FieldSetFormControllerV2" implements="flexipage:availableForRecordHome,force:hasRecordId,force:hasSObjectName,flexipage:availableForAllPageTypes"> | |
| <aura:attribute name="fieldSetName" type="String" description="The api name of the field set to use from the given object." /> | |
| <aura:attribute name="recordTypeId" type="String" /> | |
| <aura:attribute name="fields" type="Object[]" access="private" /> | |
| <aura:handler name="init" value="{!this}" action="{!c.init}" /> | |
| <aura:handler event="force:refreshView" action="{!c.init}" /> | |
| <lightning:recordEditForm aura:id="test" | |
| objectApiName="{! v.sObjectName }" | |
| recordId="{! v.recordId }" | |
| recordTypeId="{! v.recordTypeId }"> | |
| <lightning:messages /> | |
| <aura:iteration items="{! v.fields }" var="field"> | |
| <lightning:inputField fieldName="{! field.APIName }" class="slds-p-top_small slds-m-top_medium" /> | |
| </aura:iteration> | |
| <lightning:button class="slds-m-top_small" type="submit" label="Save" /> | |
| </lightning:recordEditForm> | |
| </aura:component> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment