nova-chartjs
nova-chartjs copied to clipboard
[BUG] series method not working with nova model
Describe the bug
error when using the ->series([])
method instancing graph in a Laravel Nova resource card, using ->model('Class')
.
To Reproduce
(new \Coroowicaksono\ChartJsIntegration\BarChart())
->title('Misura')
->model('\App\Models\Misura')
->col_xaxis('ora')
->options([
'queryFilter' => array([
'key' => 'ora',
'operator' => 'IS NOT NULL',
])
])
->series(array([
'label' => 'Product A',
'filter' => [
'key' => 'type_id',
'value' => '1',
],
]))
->width('2/3'),
Screenshots
Dependencies Version:
- Laravel Version: 9.2
- Nova Version: 4.0
- Nova-ChartJS Version: 0.4.0
- DB: postgreSQL