0
 <lightning:recordEditForm aura:id="editFormAccount"  objectApiName="Account">       
                <table class="slds-table slds-table_bordered slds-table_col-bordered" style="min-width: 100px;">
                    <thead >                            
                        <tr class="slds-no-hover">
                            <th>Account Name</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr>
                            <td><lightning:inputField fieldName="Name" /></td>
                        </tr>
                        <tr>
                            <td><lightning:inputField fieldName="Phone" value="{!acc.Phone}"/></td>
                        </tr>
                        <tr>
                            <td><lightning:inputField fieldName="ParentID"/></td>
                        </tr>
                    </tbody>
                </table>
                <lightning:button aura:id="submit" type="submit" label="Save" class="slds-m-top_medium" />
            </lightning:recordEditForm>

Is it possible to Clone previous row values to the next row?

This is Controleller I used.

handleSubmit: function(component, event, helper) {    
     component.find('editFormAccount').submit();
}

<td><lightning:inputField fieldName="Phone" value="{!acc.Phone}"/></td>

By avove inout field line I was able to Copy the Phone field to next row but and after update the new value to 2nd tow on phone field then I click on Add row, again it is reflecting same phone values to all rows this even on 1 st row as well.

It should affect to next row only not the previous row.

Thank you.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.