I am facing an issue in which I am creating a lightning component with "lightning:input type = "radio". All is working fine but this is not working if I am using the same component twice on the same lightning page.
On both, only one component radio button is checked true. And when click one another get disappear. And I am not sure how I can prevent this.
<div class="slds-col slds-grid slds-grid_align-spread outer-div2 " style="position:relative;width:100%">
<div class = "slds-col ">
<lightning:input aura:id="allRadio" type="radio" label="All" value = "allRadio" name = "options" checked = "true" onchange="{!c.init}"/>
</div>
<div class = "slds-col ">
<lightning:input type="radio" label="Priority" value = "priority" name = "options" onchange="{!c.priorInit}"/>
<lightning:radioGroup name="radioGroup"
label="Radio Group"
options="{! v.options }"
value="{! v.value }"
type="radio"/>
</div>
</div>
I have tried radiogroup as well. But get no luck!!
Any help will be helpful.