From df088b56eb056ad33226612868b3a07b769dae55 Mon Sep 17 00:00:00 2001 From: Frank Schubert Date: Tue, 18 Apr 2023 15:44:03 +0200 Subject: [PATCH] Fixed always setting unit_count filter to 0 --- Layout/default/Preorder/Index.php | 2 +- application/Preorder/PreorderModel.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Layout/default/Preorder/Index.php b/Layout/default/Preorder/Index.php index 3644b4203..4b3b3a097 100644 --- a/Layout/default/Preorder/Index.php +++ b/Layout/default/Preorder/Index.php @@ -130,7 +130,7 @@ diff --git a/application/Preorder/PreorderModel.php b/application/Preorder/PreorderModel.php index 039b694a6..6854b4e21 100644 --- a/application/Preorder/PreorderModel.php +++ b/application/Preorder/PreorderModel.php @@ -474,7 +474,7 @@ class PreorderModel { $where .= " AND adb_hausnummer.unit_count = 1"; } elseif(intval($unit_count) === 2) { $where .= " AND adb_hausnummer.unit_count > 1"; - } elseif(intval($unit_count) === 0) { + } elseif(strlen($unit_count) && intval($unit_count) === 0) { $where .= " AND adb_hausnummer.unit_count = 0 OR adb_hausnummer.unit_count IS NULL"; } }