diff --git a/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php b/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php index 2cd9324..9c9b08e 100644 --- a/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php +++ b/app/Modules/Plan7/Http/Livewire/Plan7SelectorLivewire.php @@ -83,19 +83,19 @@ public function render() if (count($this->filter)) { foreach ($this->allObjects['data'] as $key => $room) { if ($room['access'] != 0) { - if (array_key_exists('id', $this->filter) && $this->filter['id'] && $room['id'] != $this->filter['id']) { + if (array_key_exists('id', $this->filter) && $this->filter['id'] !== null && $room['id'] != $this->filter['id']) { continue; } - if (array_key_exists('bs', $this->filter) && $this->filter['bs'] && $room['bs'] != $this->filter['bs']) { + if (array_key_exists('bs', $this->filter) && $this->filter['bs'] !== null && $room['bs'] != $this->filter['bs']) { continue; } if (array_key_exists('type', $this->filter) && $this->filter['type'] !== null && $room['type'] != $this->filter['type']) { continue; } - if (array_key_exists('min_area', $this->filter) && $room['area'] < $this->filter['min_area']) { + if (array_key_exists('min_area', $this->filter) && $this->filter['min_area'] !== null && $room['area'] < $this->filter['min_area']) { continue; } - if (array_key_exists('max_area', $this->filter) && $room['area'] > $this->filter['max_area']) { + if (array_key_exists('max_area', $this->filter) && $this->filter['max_area'] !== null && $room['area'] > $this->filter['max_area']) { continue; } $room['mode'] = 'room';