1

What is lightning:quickActionAPI alternative to call from a custom lightning app?

When I try to call any method from the spec I am getting the following error: The API you used isn’t supported on this page. You can only execute this API on record pages.. After checking the spec we can see that the type of actions with which the lightning:quickActionAPI can work is object, so it won`t work with custom lightning app.

That is why I am asking what else can I use to perform quick actions in lightning app.

There is not x-y problem due to this question being asked previously. So, please, do not suggest a completely different approach like using force:recordCreate, force:recordData or lightning:recordEditForm.

1 Answer 1

1

You can use the QuickAction class to activate quick actions in the server-side controller. There is no UI for quick actions that work outside of Lightning Experience, so it will be up to you to provide the necessary components to render the quick action to begin with. You can start by describing the quick action, rendering a UI using the describe results (e.g. which fields are required), and then use the appropriate call in Apex to execute the Quick Action using the collected parameters. Due to the complexity of the code, I don't have an example for you, but I think this should be enough to get you started.

You must log in to answer this question.

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