I have created a Send Email global action in lightning. I want to open it from the lightning component. It should open in a popup window. My code is as follow :
<aura:component implements="lightning:actionOverride,force:appHostable,
force:hasRecordId,flexipage:availableForAllPageTypes,
flexipage:availableForRecordHome" access="global">
<lightning:quickActionAPI aura:id="quickActionAPI" />
<lightning:button label="Try open email action" onclick="{!c.fireGlobal}" />
</aura:component>
({
fireGlobal: function (cmp, event, helper) {
var actionAPI = cmp.find("quickActionAPI");
var fields = {recordId:cmp.get("v.recordId")};
var args = { actionName: "VRNA__SendEmail",targetFields: fields};
actionAPI.invokeAction(args);
}
})
This opens the email in the Activity tab but I want it to open in a popup window.