request->getQuery('statistics_entry_amount', 5); $statistics_pie_include_remaining = $this->request->getQuery('statistics_include_remainging', true); if (is_string($statistics_pie_include_remaining)) { $statistics_pie_include_remaining = $statistics_pie_include_remaining == 'true' ? true : false; } $statistics_pie_ignore_null = $this->request->getQuery('statistics_ignore_null', true); if (is_string($statistics_pie_ignore_null)) { $statistics_pie_ignore_null = $statistics_pie_ignore_null == 'true' ? true : false; } $seedPiechart = 's-' . mt_rand(); foreach ($statistics['usage'] as $scope => $graphData) { $pieChart = $this->element('charts/pie', [ 'data' => $graphData, 'chartOptions' => [ 'chart' => [ 'height' => '80px', 'sparkline' => [ 'enabled' => true, ] ], 'plotOptions' => [ 'pie' => [ 'customScale' => 0.9, ] ], ], ]); $titleHtml = sprintf( '%s%s', Inflector::Pluralize(Inflector::Humanize(h($scope))), $this->Bootstrap->button([ 'variant' => 'link', 'icon' => 'cog', 'size' => 'xs', 'nodeType' => 'a', 'onclick' => '', 'class' => ['btn-statistics-pie-configurator-' . $seedPiechart], 'params' => [ 'data-bs-toggle' => 'popover', ] ]) ); $panelHtml = sprintf( '