|
|
|
@ -304,7 +304,9 @@ class ProjectController extends Controller
|
|
|
|
|
->get(); |
|
|
|
|
$countData = $data->count(); |
|
|
|
|
|
|
|
|
|
$manpowers = UserToProyek::where('proyek_id', $id)->count(); |
|
|
|
|
$rootActivity = Activity::whereNull('parent_id')->where('proyek_id', $id)->orderBy('version_gantt_id', 'desc')->first(); |
|
|
|
|
|
|
|
|
|
if($rootActivity){ |
|
|
|
|
$actualCost = $rootActivity->biaya_actual ?? 0; |
|
|
|
|
$progress = $rootActivity->persentase_progress ?? 0; |
|
|
|
@ -331,9 +333,10 @@ class ProjectController extends Controller
|
|
|
|
|
$arr = explode(" ", $val->pm); |
|
|
|
|
$dataRes['pm'] = $arr[0]; |
|
|
|
|
$dataRes['budget_health'] = $val->budget_health; |
|
|
|
|
$dataRes['actualCost'] = $actualCost; |
|
|
|
|
$dataRes['actual_cost'] = $actualCost; |
|
|
|
|
$dataRes['progress'] = $progress; |
|
|
|
|
$dataRes['comment'] = $commentActivity; |
|
|
|
|
$dataRes['man_power'] = $manpowers; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if(!$data) |
|
|
|
|