You need to sign in to do that
Don't have an account?

Update Attribute on Parent from Chile
I have a parent component that itterates using a child attribute. I have passed the value to the child and in the child code I want to update the parents attribute. I thought the attribute would update based on what I have but its not. Any help would be greatly appreciated! Here is what I have. Its the cloning attribute I want to update. (I stripped out the code that was not relevant)
Parent component:
Here is the sub component:
Parent component:
<!-- attribute used to Toggle when Cloning --> <aura:attribute name="cloning" type="boolean" default="false"/> <aura:if isTrue="{!v.cloning}"> <lightning:layout> <lightning:layoutItem padding="horizontal-medium" size="12"> <!-- Iterate over the list of Group Structures and display them --> <aura:iteration var="NGS" items="{!v.newGroupsStructures}"> <c:GroupStructures newGroupStructures="{!NGS}" cloning="{!v.cloning}" groupstructure="{!v.groupstructures}"/> </aura:iteration> </lightning:layoutItem> </lightning:layout> </aura:if>
Here is the sub component:
NavigatetoGSClone:function(component,event,helper){ //set the variable to cloning to update the page var cloneTrue = "True"; component.set("v.cloning", cloneTrue); },