services = collect([]); $this->parameters = get_route_parameters(); $this->query = request()->query(); $this->service = Service::whereUuid($this->parameters['service_uuid'])->firstOrFail(); $service = $this->service->applications()->whereName($this->parameters['service_name'])->first(); if ($service) { $this->serviceApplication = $service; } else { $this->serviceDatabase = $this->service->databases()->whereName($this->parameters['service_name'])->first(); } } public function generateDockerCompose() { $this->service->parse(); } public function render() { return view('livewire.project.service.show'); } }