Wie man jährliche Karte in Laravel bekommt
public function getYearlyVisits()
{
$monthlyVisitors = DB::table('shorteners')
->select([
DB::raw('YEAR(created_at) as year'),
DB::raw('count(total_visits as total_visits'),
])
->groupBy('year')
->get();
}
Horrible Hamerkop