You need to sign in to do that
Don't have an account?
Max Paq
Multiple ui:inputSelect in lightning component
Hey everyone,
I am hoping someone can point to me what I am doing something wrong. I have 3 UI:inputSelect field in a lightning component and they all show data correctly. However, whenever I select an option in my second and third field the value never change.
Thank you for your help,
I am hoping someone can point to me what I am doing something wrong. I have 3 UI:inputSelect field in a lightning component and they all show data correctly. However, whenever I select an option in my second and third field the value never change.
Thank you for your help,
<ui:inputSelect aura:id="buildingList" change="{!c.onBuildingSelection}"> <ui:inputSelectOption label="Please Select a building"/> <aura:iteration items="{!v.buildings}" var="building"> <ui:inputSelectOption label="{!building.Name}" text="{!building.Id}" /> </aura:iteration> </ui:inputSelect> <ui:inputSelect aura:id="inspectionList" change="{!c.onInspectionSelection}"> <ui:inputSelectOption label="Please Select an Inspection"/> <aura:iteration items="{!v.inspections}" var="inspection"> <ui:inputSelectOption label="{!inspection.Name}" text="{!inspection.id}"/> </aura:iteration> </ui:inputSelect> <ui:inputSelect aura:id="spaceList"> <ui:inputSelectOption label="Please Select a Space"/> <aura:iteration items="{!v.spaces}" var="space"> <ui:inputSelectOption label="{!space}"/> </aura:iteration> </ui:inputSelect>
Also, do the controller methods attached to the onchange event do anything in regards to the inputSelect value?
So I think I got it to work by moving my <ui:inputSelectOption label="please select"/> after my aura:iteration