Reviewed-on: ordo/adw-backend#55 Reviewed-by: ibnu <ibnu@mail.com>
@ -456,9 +456,8 @@ class ProjectController extends Controller
}
public function getManpower($proyek_id){
$manPower = UserToProyek::where('proyek_id', $proyek_id)->get();
$manCount = $manPower->count();
return response()->json(['data'=>$manPower, 'totalRecord'=>$manCount]);
$manCount = UserToProyek::where('proyek_id', $proyek_id)->count();
return response()->json(['totalRecord'=>$manCount]);
public function getAssignedHR($gantt_id){
@ -41,7 +41,8 @@ class UserToActivityController extends Controller
"activity_id" => $request->activity_id,
"role_proyek_id" => $users_role[$index],
"proyek_id" => $request->proyek_id,
"created_by" => $this->currentName
"created_by" => $this->currentName,
"version_gantt_id" => $request->version_gantt_id
);
$result = UserToActivity::create($dataInsert);
if($result){