This commit is contained in:
salam committed 2026-05-27 12:28:23 +02:00
1 parent adcac05883
commit 0e35baca70
4 files changed
+23 -15

No files matched your search

@@ -17,24 +17,24 @@ class ChartMovingAverageEvent extends ChartWidget
protected function getData(): array protected function getData(): array
{ {
$this->heading = 'Events '.HelperStatisticType::get($this->filters); $this->heading = 'Events';
$data = LoadEvents::load($this->filters); $data = LoadEvents::load($this->filters);
if ($data) { $this->description = HelperStatisticType::get($this->filters).' Moving Average';
HelperMoveingAverage::get($data);
$this->description = 'Moving Average '.$data['description']; if ($data) {
if (isset($data['description'])) {
$this->description .= $data['description'];
}
HelperMoveingAverage::get($data);
} }
return $data; return $data;
} }
public function getDescription(): ?string
{
return 'Moving Average';
}
protected function getType(): string protected function getType(): string
{ {
return 'line'; return 'line';
@@ -43,7 +43,9 @@ class ChartMovingAveragePlayer extends ChartWidget
return []; return [];
} }
$this->heading = 'Player '.HelperStatisticType::get($this->filters); $this->heading = 'Player';
$this->description = HelperStatisticType::get($this->filters);
$data = LoadPlayer::load($this->filters); $data = LoadPlayer::load($this->filters);
+4 -2
View File
@@ -16,12 +16,14 @@ class ChartPunctualEvent extends ChartWidget
protected function getData(): array protected function getData(): array
{ {
$this->heading = 'Events '.HelperStatisticType::get($this->filters); $this->heading = 'Events';
$data = LoadEvents::load($this->filters); $data = LoadEvents::load($this->filters);
$this->description = HelperStatisticType::get($this->filters);
if (isset($data['description'])) { if (isset($data['description'])) {
$this->description = $data['description']; $this->description .= $data['description'];
} }
return $data; return $data;
+7 -3
View File
@@ -13,8 +13,6 @@ class ChartPunctualPlayer extends ChartWidget
protected ?string $pollingInterval = null; protected ?string $pollingInterval = null;
public ?string $header;
protected ?array $options = [ protected ?array $options = [
'plugins' => [ 'plugins' => [
'legend' => [ 'legend' => [
@@ -37,7 +35,13 @@ class ChartPunctualPlayer extends ChartWidget
return []; return [];
} }
$this->heading = 'Player '.HelperStatisticType::get($this->filters); $this->heading = 'Player';
$this->description = HelperStatisticType::get($this->filters);
if (isset($data['description'])) {
$this->description .= $data['description'];
}
$data = LoadPlayer::load($this->filters); $data = LoadPlayer::load($this->filters);