Article::whereYear('created_at', now()->year)
->whereMonth('created_at', now()->month)
->orWhere(function ($query) {
$query->whereYear('created_at', now()->subYear()->year)
->whereMonth('created_at', now()->month);
})
->get()
->groupBy(function($article) {
return Carbon::parse($article->created_at)
->format('m-Y');
});