mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-28 16:54:16 +00:00
show active customers in the report
This commit is contained in:
+1
-1
@@ -29,7 +29,7 @@ Route::group(['middleware' => ['role:admin']], function() {
|
||||
});
|
||||
|
||||
foreach($months as $month => $bookings){
|
||||
$newCustomers = \App\User::whereYear('created_at', '=', Carbon::parse($month)->format('Y')) ->whereMonth('created_at', '=', Carbon::parse($month)->format('Y'))->get();
|
||||
$newCustomers = \App\User::whereYear('created_at', '=', Carbon::parse($month)->format('Y')) ->whereMonth('created_at', '=', Carbon::parse($month)->format('m'))->get();
|
||||
echo "<h1>".Carbon::parse($month)->format('m-Y').": <small style='color: green; font-size: larger'>".$bookings->sum('bia')." MYR</small></h1>";
|
||||
echo "<h3>New Customer: <small style='color: green; font-size: larger'>".count($newCustomers)." Customers</small></h3>";
|
||||
echo "<h3>Active Customers: <small style='color: green; font-size: larger'>".count($bookings->groupBy(function($item){
|
||||
|
||||
Reference in New Issue
Block a user