Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <aura:component implements="force:appHostable,flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId,forceCommunity:availableForAllPageTypes,force:lightningQuickAction"
- access="global"
- controller="P2EcdependentPicklist_NewRFI">
- <!-- call doInit function on component load -->
- <aura:handler name="init" value="this" action="{!c.doInit}"/>
- <aura:attribute name="recordId" type="Id" />
- <aura:attribute name="recordtypevalu" type="string" />
- <!-- aura attributes-->
- <aura:attribute name="listControllingValues" type="list" default="[]" description="to store controller field values"/>
- <aura:attribute name="listDependingValues" type="list" default="['--- None ---']" description="to store dependent field values"/>
- <aura:attribute name="depnedentFieldMap" type="map" description="map to store dependent values with controlling value"/>
- <aura:attribute name="bDisabledDependentFld" type="boolean" default="true"/>
- <aura:attribute name="objDetail" type="contact" default="{'sobjectType' : 'case'}"/>
- <aura:attribute name="controllingFieldAPI" type="string" default="RFI_Type__c" description="store field API name of Controller field"/>
- <aura:attribute name="dependingFieldAPI" type="string" default="RFI_SubType__c" description="store field API name of dependent field"/>
- <!--Controller Field-->
- <lightning:layoutItem size="12" padding="around-small">
- <lightning:select name="controllerFld"
- value="{!v.objDetail.RFI_Type__c}"
- label="RFI Type"
- onchange="{!c.onControllerFieldChange}" aura:id="RFITypeValue" required="true" messageWhenValueMissing="Choose RFI Type Value!">
- <aura:iteration items="{!v.listControllingValues}" var="val">
- <option value="{!val}">{!val}</option>
- </aura:iteration>
- </lightning:select>
- </lightning:layoutItem>
- <!--Dependent Field-->
- <lightning:layoutItem size="12" padding="around-small">
- <lightning:select name="dependentFld"
- value="{!v.objDetail.RFI_SubType__c}"
- label="RFI SubType"
- disabled="{!v.bDisabledDependentFld}" required="true" messageWhenValueMissing="Choose RFI SubType Value!">
- <aura:iteration items="{!v.listDependingValues}" var="val" >
- <option value="{!val}">{!val}</option>
- </aura:iteration>
- </lightning:select>
- </lightning:layoutItem>
- <c:liu_NewRFIOnOpportunity aura:id="childCmp"/>
- <lightning:button variant="brand" label="Submit" onclick="{! c.handleClick }" />
Add Comment
Please, Sign In to add comment