#9814 fix width height combined module graph

This commit is contained in:
Jonathan 2023-10-23 17:04:17 +02:00
parent 1f8554e8d1
commit a3c6317910
1 changed files with 8 additions and 2 deletions

View File

@ -439,7 +439,7 @@ class SingleGraphWidget extends Widget
$trickHight = 0;
if ($this->values['showLegend'] === 1) {
// Needed for legend.
$trickHight = 40;
$trickHight = 60;
}
$output = '<div class="container-center widget-mrgn-0px">';
@ -448,10 +448,16 @@ class SingleGraphWidget extends Widget
'period' => $this->values['period'],
'date' => strtotime(date('Y-m-d H:i:s')),
'only_image' => false,
'homeurl' => ui_get_full_url(false, false, false, false).'/',
'height' => ((int) $size['height'] - $trickHight),
'landscape' => $content['landscape'],
'return_img_base_64' => true,
'show_legend' => $this->values['showLegend'],
'width' => '100%',
'height' => ((int) $size['height'] - $trickHight),
'title' => $module_name,
'unit' => $units_name,
'homeurl' => $config['homeurl'],
'menu' => false,
];
$params_combined = [