From 8996b3d09b8ddfcd7ba06ab91d75c3687c869a68 Mon Sep 17 00:00:00 2001 From: Deon George Date: Thu, 12 Aug 2021 00:15:58 +1000 Subject: [PATCH] Show message numbers in echorea list --- config/app.php | 1 + resources/views/domain/view.blade.php | 12 +++++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/config/app.php b/config/app.php index 33450b7..5eb260b 100644 --- a/config/app.php +++ b/config/app.php @@ -204,6 +204,7 @@ return [ 'Blade' => Illuminate\Support\Facades\Blade::class, 'Broadcast' => Illuminate\Support\Facades\Broadcast::class, 'Bus' => Illuminate\Support\Facades\Bus::class, + 'Carbon' => \Carbon\Carbon::class, 'Cache' => Illuminate\Support\Facades\Cache::class, 'Config' => Illuminate\Support\Facades\Config::class, 'Cookie' => Illuminate\Support\Facades\Cookie::class, diff --git a/resources/views/domain/view.blade.php b/resources/views/domain/view.blade.php index cae4845..3463237 100644 --- a/resources/views/domain/view.blade.php +++ b/resources/views/domain/view.blade.php @@ -28,12 +28,19 @@
@if($o->echoareas->count())

This network provides the following Echomail areas:

- +
+ + + + + + + @@ -43,6 +50,9 @@ + + + @endforeach
Messages
Echoarea Description Last MessageDayWeekMonth
{{ $oo->name }} {{ $oo->description }} {{ ($x=$oo->echomail()->orderBy('created_at','DESC')->first()) ? $x->created_at->format('Y-m-d H:i') : '-' }}{{ number_format($oo->echomail()->where('created_at','>=',Carbon::now()->subDay())->count()) }}{{ number_format($oo->echomail()->where('created_at','>=',Carbon::now()->subWeek())->count()) }}{{ number_format($oo->echomail()->where('created_at','>=',Carbon::now()->subMonth())->count()) }}