From 33cd2cef7d125f90ba699858ec8cc2cba652485e Mon Sep 17 00:00:00 2001 From: omair saleh Date: Wed, 6 Oct 2021 21:50:26 +0800 Subject: [PATCH] fix sales report decimals --- app/Http/Controllers/Reports/MonthlyReportController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/Reports/MonthlyReportController.php b/app/Http/Controllers/Reports/MonthlyReportController.php index 5edcee46..cb07f2b5 100644 --- a/app/Http/Controllers/Reports/MonthlyReportController.php +++ b/app/Http/Controllers/Reports/MonthlyReportController.php @@ -19,7 +19,7 @@ use Illuminate\Http\Request; class MonthlyReportController { public function salesReport(Request $request): JsonResponse { - $today = Carbon::now(); + $today = Carbon::now()->subMonth(); $containers = Container::whereMonth('loading_date', $today->format('m'))->whereYear('loading_date', $today->format('Y'))->orderBy('loading_date')->get();