From ff08801cad71e71924b6d1acb51773bd03a75a04 Mon Sep 17 00:00:00 2001 From: Wahyu Ramadhan Date: Fri, 25 Aug 2023 11:23:13 +0700 Subject: [PATCH] quick fix --- app/Http/Controllers/ActivityController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/ActivityController.php b/app/Http/Controllers/ActivityController.php index 3b8ff84..99f3614 100644 --- a/app/Http/Controllers/ActivityController.php +++ b/app/Http/Controllers/ActivityController.php @@ -165,7 +165,7 @@ class ActivityController extends Controller } public function getActivityLast($parentId){ - $activity = Activity::where('parent_id', $parentId)->orderByRaw('actual_end DESC')->first(); + $activity = Activity::where('parent_id', $parentId)->orderByRaw('actual_start DESC')->first(); if (!isset($activity)) { return null; }