Hi all,
Iâm trying to do the following:
in the detail /edit view of an Account, provide a button in the recordâs action dropdown that
- letâs you select linked quotes in a modal
- creates a file (e.g. pdf) for that quote & account and sends it (download)
Iâve managed the first part following this tutorial:
The problem is though, that this is an async action. I can think of two options to solve that, and would appreciate hints on how to do either of them (or even another solution).
Option 1: return a url in the return value and add some javascript to redirect to it. I know how to add the url in the response, but how and where would I add the javascript? And would that target URL be a custom entry point?
Option 2: call a custom entrypoint, i.e. redirect to it directly from the action dropdownâs button. Unfortunately, I found no tutorial on how to do that. Iâve tried the following, with keys like uri/url/linkâŚ, but none seems to work. btwâŚwhere are all the possible keys documented?
$recordActions['create-pdf'] = [
//'key' => 'account-create-pdf',
'uri' => 'index.php?entryPoint=MyEntryPoint'
'labelKey' => 'LBL_CREATE_PDF',
'modes' => ['detail', 'edit'],
'params' => [
// Allow selecting a record from a modal before running action
'selectModal' => [
'module' => 'AOS_Quotes'
]
]
];
Thanks!
BR,
Chris