/** @param array $args */ public function onProductFilterBaseQuery(array &$args): void { if (!Shop::isFrontend()) { return; } try { $selection = VehicleSelectionService::getSelectionFromSessionOrCookie($this->getPlugin()); if (!$selection->hasAny()) { return; } $db = Shop::Container()->getDB(); $config = $this->getPlugin()->getConfig(); $svc = new VehicleProductFilterService( $db, (string)$config->getValue('merkmal_make'), (string)$config->getValue('merkmal_model'), (string)$config->getValue('merkmal_type'), (string)$config->getValue('merkmal_year'), (int)$config->getValue('include_no_vehicle_features') === 1 ); $conditionSql = $svc->buildConditionSql($selection); if ($conditionSql === '') { return; } // ✅ HOOK 253 liefert arrays – wir müssen in &conditions einhängen if (isset($args['conditions']) && \is_array($args['conditions'])) { $args['conditions'][] = $conditionSql; return; } // Fallback (falls je nach Version anders übergeben) foreach (['where', 'cWhere', 'whereSQL'] as $k) { if (isset($args[$k]) && \is_string($args[$k])) { $args[$k] = $this->appendWhere($args[$k], $conditionSql); return; } } foreach (['sql', 'cQuery', 'query'] as $k) { if (isset($args[$k]) && \is_string($args[$k]) && $args[$k] !== '') { $args[$k] = $this->appendWhereToSqlString($args[$k], $conditionSql); return; } } } catch (\Throwable $e) { // still } } Fahrzeugmarke: Audi ab 2019 T-Roc T-Roc R A1, R ab 2017 Seat 5FP Q2 K
Robin kaufte gerade
Maxton Design Heck Ansatz Flaps Diffusor für Peugeot 208 Mk2 schwarz Hochglanz
aus Wendisch Evern
Philipp kaufte gerade
Maxton Design Spoiler CAP für Seat Leon FR ST Mk4 schwarz Hochglanz
aus Heinsberg