Update ReportController.php
This commit is contained in:
@@ -650,29 +650,29 @@ class ReportController extends Controller
|
|||||||
$forms = [
|
$forms = [
|
||||||
'Up Country' => FormUpCountry::whereIn('user_id', $userIds)
|
'Up Country' => FormUpCountry::whereIn('user_id', $userIds)
|
||||||
->whereBetween('tanggal', [$startDate, $endDate])
|
->whereBetween('tanggal', [$startDate, $endDate])
|
||||||
->whereIn('status', ['Approved', 'On Progress'])
|
->whereIn('status', ['Approved', 'Closed'])
|
||||||
->get(),
|
->get(),
|
||||||
|
|
||||||
'Vehicle Running Cost' => FormVehicleRunningCost::whereIn('user_id', $userIds)
|
'Vehicle Running Cost' => FormVehicleRunningCost::whereIn('user_id', $userIds)
|
||||||
->whereBetween('tanggal', [$startDate, $endDate])
|
->whereBetween('tanggal', [$startDate, $endDate])
|
||||||
->whereIn('status', ['Approved', 'On Progress'])
|
->whereIn('status', ['Approved', 'Closed'])
|
||||||
->get(),
|
->get(),
|
||||||
|
|
||||||
'Entertainment' => FormEntertaimentPresentation::whereIn('user_id', $userIds)
|
'Entertainment' => FormEntertaimentPresentation::whereIn('user_id', $userIds)
|
||||||
->whereBetween('tanggal', [$startDate, $endDate])
|
->whereBetween('tanggal', [$startDate, $endDate])
|
||||||
->whereIn('status', ['Approved', 'On Progress'])
|
->whereIn('status', ['Approved', 'Closed'])
|
||||||
->get(),
|
->get(),
|
||||||
|
|
||||||
'Meeting / Seminar' => FormMeetingSeminar::whereIn('user_id', $userIds)
|
'Meeting / Seminar' => FormMeetingSeminar::whereIn('user_id', $userIds)
|
||||||
->whereBetween('created_at', [$startDate, $endDate])
|
->whereBetween('created_at', [$startDate, $endDate])
|
||||||
->whereIn('status', ['Approved', 'On Progress'])
|
->whereIn('status', ['Approved', 'Closed'])
|
||||||
->get(),
|
->get(),
|
||||||
];
|
];
|
||||||
|
|
||||||
// Forms "Others" dikelompokkan berdasarkan kategori
|
// Forms "Others" dikelompokkan berdasarkan kategori
|
||||||
$otherForms = FormOthers::whereIn('user_id', $userIds)
|
$otherForms = FormOthers::whereIn('user_id', $userIds)
|
||||||
->whereBetween('tanggal', [$startDate, $endDate])
|
->whereBetween('tanggal', [$startDate, $endDate])
|
||||||
->whereIn('status', ['Approved', 'On Progress'])
|
->whereIn('status', ['Approved', 'Closed'])
|
||||||
->get();
|
->get();
|
||||||
|
|
||||||
// Total nominal per kategori
|
// Total nominal per kategori
|
||||||
|
|||||||
Reference in New Issue
Block a user