Browse Source

Fix link creation

pull/3/head
Wahyu Ramadhan 2 years ago
parent
commit
f6a0574857
  1. 2
      app/Http/Controllers/ActivityController.php

2
app/Http/Controllers/ActivityController.php

@ -488,7 +488,7 @@ class ActivityController extends Controller
if (!empty($activity_row['predecessor'])) {
$key = array_search($activity_row['predecessor'], array_column($data['activities'], 'no'));
if (!$predecessorActivity = Activity::find($data['activities'][$key]['activity_id']))
if (!isset($data['activities'][$key]['activity_id']) || !$predecessorActivity = Activity::find($data['activities'][$key]['activity_id']))
continue;
$predecessorFinishDate = new \DateTime($predecessorActivity->end_date);

Loading…
Cancel
Save