Fixed url in metaconsole

This commit is contained in:
Daniel Maya 2022-01-11 15:40:49 +01:00
parent 4899d68ec2
commit 191f17b7d6
1 changed files with 14 additions and 3 deletions

View File

@ -323,11 +323,22 @@ class MapsStatusWidget extends Widget
$data = [];
$url = $config['homeurl'];
$url .= 'index.php?sec=visualc';
$url .= '&sec2=operation/visual_console/render_view&refr=60';
if (\is_metaconsole() === true) {
$url .= sprintf(
'index.php?sec=screen&sec2=screens/screens&action=visualmap&pure=0&refr=%s&id_visualmap=%s',
$config['vc_refr'],
$id_layout
);
} else {
$url .= sprintf(
'index.php?sec=visualc&sec2=operation/visual_console/render_view&refr=%s&id=%s',
$config['vc_refr'],
$id_layout
);
}
// This will give us the group name.
$data[0] = '<a href="'.$url.'&id='.$id_layout.'">';
$data[0] = '<a href="'.$url.'">';
$data[0] .= $user_layouts[$id_layout]['name'];
$data[0] .= '</a>';