Update ReportController.php

This commit is contained in:
Jagad R R
2025-05-05 23:19:22 +07:00
parent 35ad132607
commit 9a8cec7165
@@ -650,29 +650,29 @@ class ReportController extends Controller
$forms = [
'Up Country' => FormUpCountry::whereIn('user_id', $userIds)
->whereBetween('tanggal', [$startDate, $endDate])
->whereIn('status', ['Approved', 'On Progress'])
->whereIn('status', ['Approved', 'Closed'])
->get(),
'Vehicle Running Cost' => FormVehicleRunningCost::whereIn('user_id', $userIds)
->whereBetween('tanggal', [$startDate, $endDate])
->whereIn('status', ['Approved', 'On Progress'])
->whereIn('status', ['Approved', 'Closed'])
->get(),
'Entertainment' => FormEntertaimentPresentation::whereIn('user_id', $userIds)
->whereBetween('tanggal', [$startDate, $endDate])
->whereIn('status', ['Approved', 'On Progress'])
->whereIn('status', ['Approved', 'Closed'])
->get(),
'Meeting / Seminar' => FormMeetingSeminar::whereIn('user_id', $userIds)
->whereBetween('created_at', [$startDate, $endDate])
->whereIn('status', ['Approved', 'On Progress'])
->whereIn('status', ['Approved', 'Closed'])
->get(),
];
// Forms "Others" dikelompokkan berdasarkan kategori
$otherForms = FormOthers::whereIn('user_id', $userIds)
->whereBetween('tanggal', [$startDate, $endDate])
->whereIn('status', ['Approved', 'On Progress'])
->whereIn('status', ['Approved', 'Closed'])
->get();
// Total nominal per kategori