How to display all phone type clickable fields in Salesforce Lightning Component?

Is managing multiple phone type fields becoming a complex problem for you? Don’t worry! We are here to simplify things for you. With the help of this solution, you will be able to display clickable multiple phone fields like Phone, Mobile, Fax, etc., in the same place.

Today, we will share an ultimate solution that will make things a lot easier for you. So, let’s get started with it.

Why should you try out this solution?

  • You will not have to search and scroll on the full detail page layout for the different phone type fields. They all will be available on a single page with just a click.
  • Also, you will be having phone fields with hyperlinks that will redirect you to any URL.
  • You can use this functionality to make calls using an external app, and the URL will change dynamically based on the phone field clicked.
  • This solution is also helpful for Salesforce mobile app users as it has an additional display layout.

Code

Apex Controller

JS Controller:

Component mark up:

Conclusion

Displaying clickable fields in Salesforce Lightning Component has never been easier than this! Try out this solution and see how this makes things better for you and your business. Also, please let us know your feedback about this blog. If you try out this solution, then don’t forget to share your experiences with us. We will be back with another solution soon.

Till then, Happy Learning!

Our Location worldwide
India
3rd Floor, A-10, Pegasus Tower, Sector 68, Noida, Uttar Pradesh 201301 +91-1203117884
SR Tower 2nd Floor Hydel Gate Haldwani Uttarakhand 263126 +91-5946359996
USA
333 West Brown Deer Road Unit G – 366 Milwaukee WI, USA 53217 +1(262) 310-7818
UK
7 Bell Yard, London, WC2A 2JR +44 20 3239 9428
Canada
HIC Global Solutions INC
43 Lafferty Lane, Richmond Hill, L4C 3N8, CA +1(262) 310-7818