|
|
|
@ -31,7 +31,10 @@ class ActivityController extends Controller
|
|
|
|
|
$endDate = date_create($dataHeader->end_date); |
|
|
|
|
$dataHeader->start_date = date_format($startDate,"Y-m-d H:i:s"); |
|
|
|
|
$dataHeader->end_date = date_format($endDate,"Y-m-d H:i:s"); |
|
|
|
|
$dataHeader->type = "project"; |
|
|
|
|
$dataHeader->progress = $dataHeader->persentase_progress / 100; |
|
|
|
|
$dataHeader->planned_start = isset($dataHeader->planned_start) ? date_format(date_create($dataHeader->planned_start),"Y-m-d H:i:s") : NULL; |
|
|
|
|
$dataHeader->planned_end = isset($dataHeader->planned_end) ? date_format(date_create($dataHeader->planned_end),"Y-m-d H:i:s") : NULL; |
|
|
|
|
$dataHeader->type = "header"; |
|
|
|
|
$dataHeader->text = $dataHeader->name; |
|
|
|
|
$finalData[] = $dataHeader; |
|
|
|
|
$data = Activity::where('version_gantt_id', $id)->where('parent_id', $dataHeader->id)->orderBy('id', 'asc')->get(); |
|
|
|
|