Fix service loading issue in project select page

This commit is contained in:
Andras Bacsai
2023-11-23 11:49:49 +01:00
parent 16261fc36e
commit 1cb6d594d0
2 changed files with 5 additions and 4 deletions

View File

@@ -47,6 +47,7 @@ class Select extends Component
}
public function render()
{
if ($this->search) $this->loadServices();
return view('livewire.project.new.select');
}
@@ -68,10 +69,10 @@ class Select extends Component
// }
// }
public function loadServices(bool $force = false)
public function loadServices()
{
try {
if (count($this->allServices) > 0 && !$force) {
if (count($this->allServices) > 0) {
if (!$this->search) {
$this->services = $this->allServices;
return;