selected = Location::where('id', $locationId)->first(); $this->locations = Location::whereNotNull('display_name') ->whereNot('display_name', '=', '') ->orderBy('display_name') ->get(); } /** * Get the view/contents that represent the component. */ public function render(): View { return view('components.location-selector'); } }