Using LWC I made a custom progress bar in an attempt to replace the out of the box chevron progress bar tied to the Opportunity Stages for a Sales Process.
What I need to do next is find out what are the Opportunity Stages for the Sales Process and Record Type and which is the active StageName at the moment so I can display all that in my progress bar.
After researching I couldn't find a viable solution to do that. I thought that since it's 2020 there might have been an update in Salesforce since the last time this was asked for. If anybody has an idea of an easy way to achieve this I would love to hear it.
Best Answer
As @sfdcfox suggested, you need to use a few UI API wire adapters.
You'll need a combination of
getRecord
,getObjectInfo
andgetPicklistValues
for a totally generic solution with no hardcoded Ids.The good news is that I blogged exactly about that: https://developer.salesforce.com/blogs/2019/12/retrieving-picklist-values-without-using-apex.html