0
Gentlemen, I’m using the Laravel 5.7 and the following problem
Class 'ConsoleTVs\Charts\Facades\Charts' not found
I did his installation correctly:
composer require consoletvs/charts
added in the config/app.php
'providers' => [
....
....
ConsoleTVs\Charts\ChartsServiceProvider::class,
],
'aliases' => [
....
....
'Charts' => ConsoleTVs\Charts\Facades\Charts::class,
],
I created the model and Controller
necessary
$products = Product::where(DB::raw("(DATE_FORMAT(created_at,'%Y'))"),date('Y'))->get();
$chart = Charts::database($products, 'bar', 'highcharts')
->title("Product Details")
->elementLabel("Total Products")
->dimensions(1000, 500)
->responsive(true)
->groupByMonth(date('Y'), true);
$pie_chart = Charts::create('pie', 'highcharts')
->title('Pie Chart Demo')
->labels(['Product 1', 'Product 2', 'Product 3'])
->values([15,25,50])
->dimensions(1000,500)
->responsive(true);
and in my View
{!! $chart->render() !!}
Where can I be missing?
You turned the remote
php artisan vendor:publish --tag=charts_config
?– sant0will
Yes rodei yes @sant0will
– Cristiano Facirolli