Skip to content

Commit

Permalink
Update ProjectController.php
Browse files Browse the repository at this point in the history
  • Loading branch information
OhmygoodR authored Apr 22, 2024
1 parent 9a92b8a commit 1911b7c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/Http/Controllers/ProjectController.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ public function store(Request $request)
// TASK: Add one sentence to save the project to the logged-in user
// by $request->project_id and with $request->start_date parameter

auth()->user()->projects()->attach($request->project_id,['start_date'=>$request->start_date]);

return 'Success';
}
}

0 comments on commit 1911b7c

Please sign in to comment.