-
app/Traits/FilterTeamMembersTrait.php
Open in GitHubuse App\Models\Teams\Team; trait FilterTeamMembersTrait { public function filterTeamMembers ($team_id) { $query = Team::query()->find($team_id); return $query; } }
-
app/Http/Controllers/Teams/TeamsController.php#L175
Open in GitHubuse App\Traits\FilterTeamMembersTrait; use App\Http\Controllers\Controller; class TeamsController extends Controller { // public function members () { $query = $this->filterTeamMembers(request()->team_id); // } // }