Allows custom components to get a list of the available actions on a record page.
Arguments
None.
Sample Code
getAvailableActions : function( cmp, event, helper) {
var actionAPI = cmp.find("quickActionAPI");
actionAPI.getAvailableActions().then(function(result){
//All available actions shown;
}).catch(function(e){
if(e.errors){
//If the specified action isn't found on the page, show an error message in the my component
}
});
}
Response
Returns a Promise. Success resolves to a response object. The Promise is rejected on error response.
success: true,
actions:
{actionName: "Case._LightningUpdateCase", recordId: "recordId", type: "QuickAction"}
{actionName: "FeedItem.TextPost", recordId: "recordId", type: "QuickAction"}
{actionName: "Case.LogACall", recordId: "recordId", type: "QuickAction"}
{actionName: "Case.SendEmail", recordId: "recordId", type: "QuickAction"}
errors: []