diff --git a/app/Http/Controllers/Reports/LelonganController.php b/app/Http/Controllers/Reports/LelonganController.php index 27a4b7f..1e2195f 100644 --- a/app/Http/Controllers/Reports/LelonganController.php +++ b/app/Http/Controllers/Reports/LelonganController.php @@ -64,7 +64,7 @@ class LelonganController extends Controller if ($request->filled('startDate') && $request->filled('endDate')) { - $query->whereBetween('lelong.t_lelong', [$request->startDate, $request->endDate]); + $query->whereBetween('lelong.t_jual', [$request->startDate, $request->endDate]); } $summary_lelongan_data[$db_connection] = $query->first()->toArray(); diff --git a/app/Services/Reports/LelonganService.php b/app/Services/Reports/LelonganService.php index caf3f6c..410f169 100644 --- a/app/Services/Reports/LelonganService.php +++ b/app/Services/Reports/LelonganService.php @@ -46,8 +46,8 @@ class LelonganService ); $query_total_lelongan->when(!empty($this->startDate) and !empty($this->endDate), function ($q) { - return $q->where('lelong.t_lelong', '>=', $this->startDate) - ->where('lelong.t_lelong', '<=', $this->endDate); + return $q->where('lelong.t_jual', '>=', $this->startDate) + ->where('lelong.t_jual', '<=', $this->endDate); }); $total_lelongan = $this->getTotalLelongan($query_total_lelongan);