wip
This commit is contained in:
1 parent
2734b06350
commit
fbaadcd248
9 files changed
+213
-219
No files matched your search
@@ -0,0 +1,48 @@
|
||||
<?php
|
||||
|
||||
namespace App\Filament\Widgets;
|
||||
|
||||
use App\Filament\Widgets\Data\HelperStatisticType;
|
||||
use App\Filament\Widgets\Data\LoadPlayer;
|
||||
use Filament\Widgets\ChartWidget;
|
||||
use Filament\Widgets\Concerns\InteractsWithPageFilters;
|
||||
|
||||
class ChartPunctualPlayer extends ChartWidget
|
||||
{
|
||||
use InteractsWithPageFilters;
|
||||
|
||||
protected ?string $pollingInterval = null;
|
||||
|
||||
public ?string $header;
|
||||
|
||||
protected ?array $options = [
|
||||
'plugins' => [
|
||||
'legend' => [
|
||||
'display' => false,
|
||||
],
|
||||
],
|
||||
];
|
||||
|
||||
public function getDescription(): ?string
|
||||
{
|
||||
return 'Player Punctual';
|
||||
}
|
||||
|
||||
protected function getData(): array
|
||||
{
|
||||
if ($this->filters['statistic_type'] == 'crn') {
|
||||
return [];
|
||||
}
|
||||
|
||||
$this->heading = HelperStatisticType::get($this->filters);
|
||||
|
||||
$data = LoadPlayer::load($this->filters);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
protected function getType(): string
|
||||
{
|
||||
return 'line';
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user