I have this function that gets the data from MySQL by month using carbon
$calls = DB::table('calls') ->where('owned_by_id', $report->id) ->where(DB::raw('month(created_at)'), Carbon::today()->month) ->get(); $report->callsCount = $calls->count();
It works fine what i want to do is to get the data per week
I tried modifying the code like this:
but i get an error in Laravel
Unknown getter 'week'