fix: [baseurl] for openmodal actions in the index factory fixed, fixes #46

- invalid url by prepending any url (even # for modal <a> tags) with the baseurl
pull/54/head
iglocska 2021-05-14 13:31:19 +02:00
parent 5e2107cdb8
commit 32fc30a401
No known key found for this signature in database
GPG Key ID: BEA224F1FEF113AC
1 changed files with 2 additions and 3 deletions

View File

@ -35,7 +35,7 @@
} }
} }
$url_param_data_paths = ''; $url_param_data_paths = '';
$url = empty($action['url']) ? '#' : h($action['url']); $url = empty($action['url']) ? '#' : $baseurl . h($action['url']);
if (!empty($action['url_params_data_paths'])) { if (!empty($action['url_params_data_paths'])) {
if (is_array($action['url_params_data_paths'])) { if (is_array($action['url_params_data_paths'])) {
$temp = array(); $temp = array();
@ -90,8 +90,7 @@
$action['onclick'] = sprintf('UI.openModalFromURL(\'%s\', \'%s\', \'%s\')', $modal_url, $reload_url, $tableRandomValue); $action['onclick'] = sprintf('UI.openModalFromURL(\'%s\', \'%s\', \'%s\')', $modal_url, $reload_url, $tableRandomValue);
} }
echo sprintf( echo sprintf(
'<a href="%s%s" title="%s" aria-label="%s" %s %s class="link-unstyled"><i class="%s"></i></a> ', '<a href="%s" title="%s" aria-label="%s" %s %s class="link-unstyled"><i class="%s"></i></a> ',
$baseurl,
$url, $url,
empty($action['title']) ? '' : h($action['title']), empty($action['title']) ? '' : h($action['title']),
empty($action['title']) ? '' : h($action['title']), empty($action['title']) ? '' : h($action['title']),