added production line count chart
This commit is contained in:
@@ -8,8 +8,7 @@ class ItemOverview extends ChartWidget
|
||||
{
|
||||
protected static ?string $heading = 'Hourly Production';
|
||||
|
||||
// protected int|string|array $columnSpan = 'full';
|
||||
protected int|string|array $columnSpan = 12;
|
||||
protected int|string|array $columnSpan = '12';
|
||||
|
||||
protected static ?string $maxHeight = '350px';
|
||||
|
||||
@@ -146,20 +145,6 @@ class ItemOverview extends ChartWidget
|
||||
return 'line';
|
||||
}
|
||||
|
||||
// protected function getContent(): string
|
||||
// {
|
||||
// return '<div style="height: 100%;">' . $this->chart->render() . '</div>';
|
||||
// }
|
||||
// protected function getContent(): string
|
||||
// {
|
||||
// return <<<HTML
|
||||
// <div id="chart-container" style="height: 100vh; width: 100%;">
|
||||
// {$this->chart->render()}
|
||||
// </div>
|
||||
// HTML;
|
||||
// }
|
||||
|
||||
|
||||
|
||||
protected function getOptions(): array
|
||||
{
|
||||
@@ -173,15 +158,6 @@ class ItemOverview extends ChartWidget
|
||||
],
|
||||
],
|
||||
],
|
||||
|
||||
// 'scales' => [
|
||||
// 'y' => [
|
||||
// 'beginAtZero' => true, //Start Y-axis from 0
|
||||
// 'ticks' => [
|
||||
// 'stepSize' => 0.5,
|
||||
// ],
|
||||
// ],
|
||||
// ],
|
||||
];
|
||||
}
|
||||
|
||||
@@ -194,4 +170,10 @@ class ItemOverview extends ChartWidget
|
||||
'this_month'=> 'This Month',
|
||||
];
|
||||
}
|
||||
|
||||
public static function canView(): bool
|
||||
{
|
||||
// Only show on HourlyProduction page
|
||||
return request()->routeIs('filament.pages.hourly-production');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user