Change chart type according to the selected filter
in my chart widget i'm using this code to change the chart type according to the selected filter but it doesnt work,
any idea ?
any idea ?
protected function getType(): string
{
return $this->filter == 'date' ? 'line' : 'bar';
}