Hi Experts, @Elna Miller ,
Is lightning pages (standard layout) in any ways capable of showing/hiding fields based on certain value in another field.
E.g. If i select priority (picklist) as 'High' then only show 'Business justification' field (Text Field). Otherwise this field should be hidden.
for such a small requirement, I have to override the page with lightning component. Any suggestion will be appreciated !!
Thanks,
Mamata
Another workaround is to use a simple custom component which allows you to place a single field on your page. You can then set conditional visibility on the component
1. Open Developer Console
2. File > New > Lightning Component
3. Give it a name and description. You can leave all checkboxes under "Component Configuration" blank.
4. Click Submit
5. Paste in this code, then customize it by changing title=" ", objectApiName=" ", fields=" and "iconName=" "
<aura:component implements="force:appHostable,flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:hasRecordId,forceCommunity:availableForAllPageTypes,force:lightningQuickAction" access="global" >
<lightning:card iconName="custom:custom19" title="YOUR TITLE">
<div class="slds-p-left_large slds-p-right_medium">
<lightning:recordForm recordId="{!v.recordId}" objectApiName="YOUR_OBJECT_API_NAME" fields="your_custom_field"/>
</div>
</lightning:card>
</aura:component>
6. Save
7. Edit your object's lightning page(s) and select the component from the custom section and add it to your layout.
8. Set whatever conditional visibility you like on the single field component.