From de52191313bc6ad0d5edbac28cd5be7c52b5806f Mon Sep 17 00:00:00 2001 From: Luca Haid Date: Tue, 25 Feb 2025 14:47:23 +0100 Subject: [PATCH] Fixed Filter for ADB Street in ConstructionConsent.php --- application/ConstructionConsent/ConstructionConsent.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/application/ConstructionConsent/ConstructionConsent.php b/application/ConstructionConsent/ConstructionConsent.php index 0320726e4..2c482f44d 100644 --- a/application/ConstructionConsent/ConstructionConsent.php +++ b/application/ConstructionConsent/ConstructionConsent.php @@ -412,6 +412,7 @@ class ConstructionConsent extends mfBaseModel { FROM ConstructionConsent LEFT JOIN ConstructionConsentOwner cwo ON ConstructionConsent.id = cwo.constructionconsent_id LEFT JOIN addressdb.view_hausnummer vh ON ConstructionConsent.adb_hausnummer_id = vh.hausnummer_id + LEFT JOIN addressdb.Strasse vs ON ConstructionConsent.adb_strasse_id = vs.id WHERE $where GROUP BY ConstructionConsent.id $having @@ -491,7 +492,7 @@ class ConstructionConsent extends mfBaseModel { if(array_key_exists("address", $filter)) { $address = FronkDB::singleton()->escape($filter["address"]); if($address) { - $where .= " AND (vh.strasse LIKE '%$address%' OR vh.hausnummer LIKE '%$address%' OR vh.plz LIKE '%$address%' OR vh.ortschaft LIKE '%$address%' OR vh.gemeinde LIKE '%$address%')"; + $where .= " AND (vs.name LIKE '%$address%' OR vh.strasse LIKE '%$address%' OR vh.hausnummer LIKE '%$address%' OR vh.plz LIKE '%$address%' OR vh.ortschaft LIKE '%$address%' OR vh.gemeinde LIKE '%$address%')"; } }