8

I want to add a lightning quick action in the list view of opportunity. The quick action should use the Lightning component. How to add the quick action with lightning component in the List View?

2
  • What does your quick action do? Does it create or update a record?
    – Jayant Das
    Jul 10, 2018 at 23:53
  • Quick action should open the layout with Opportunity, Account fields which is done in Lightning component
    – user57911
    Jul 11, 2018 at 4:00

3 Answers 3

3

I'm afraid that's currently not possible (Summer '18).

You can add quick actions to list view but not the ones that are invoking lightning components.

I tried for example to create quick action that creates a record then I added it to a list view from Setup-> Object Manager -> Desired Object -> Search layouts -> List View -> Click edit -> Move quick actions in duallistbox in List View Actions in Lightning Experience section. I was able to add quick action that creates or updates the record, but quick action that invokes lightning component is not visible at all in those lists

enter image description here

1

You can pass IDs like this,

{!URLFOR("lightning/cmp/c__OpportunityNewBtnOverrideCmp", null, [c__id=Opportunity.Id,c__sObjectName="Opportunity"])}
0

You can use the "lightning:isUrlAddressable" to access a lightning component using an url and create a "List Button" with behavior as "Display in existing window without sidebar or header" that directs you to the component URL, as mentioned in the documentation:

https://developer.salesforce.com/docs/component-library/bundle/lightning:isUrlAddressable/documentation

The URL in the list button should look like below:

{!URLFOR('/lightning/cmp/namespace__componentName', null, [param=value])}
2
  • How are the IDs of the selected records passed to this URL? Dec 26, 2019 at 19:05
  • The button appears this way but it is not opening the lightning component. Dec 31, 2019 at 10:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .