diff --git a/app/Http/Controllers/ProjectController.php b/app/Http/Controllers/ProjectController.php index 4a396ef..00a20cb 100644 --- a/app/Http/Controllers/ProjectController.php +++ b/app/Http/Controllers/ProjectController.php @@ -22,7 +22,7 @@ class ProjectController extends Controller return Business::info($request->route('business'), true); } - public function update(Request $request,string $project) + public function update(Request $request, int $business, string $project) { permit('projectEdit', ['project_id' => $project]); $project = Project::findOrFail($project); @@ -31,7 +31,7 @@ class ProjectController extends Controller } - public function delete(Request $request, string $project) + public function delete(Request $request, int $business, string $project) { permit('businessProjects'); $project = Project::findOrFail($project); @@ -39,7 +39,7 @@ class ProjectController extends Controller return Business::info($request->route('business')); } - public function restore(Request $request, string $project) + public function restore(Request $request, int $business, string $project) { $project = Project::onlyTrashed()->findOrFail($project); $project->restore(); @@ -139,7 +139,7 @@ class ProjectController extends Controller } } - public function setAvatar(Request $request, string $project) + public function setAvatar(Request $request, int $business, string $project) { $project = Project::findOrFail($project); if ($request->hasFile('avatar')) { @@ -149,7 +149,7 @@ class ProjectController extends Controller return $project; } - public function unSetAvatar(Request $request, string $project) + public function unSetAvatar(Request $request,int $business ,string $project) { $project = Project::findOrFail($project); $project->deleteAvatar();