Fix model images not showing on the brand's model-select page
BrandController::modelsForBrand() (used by /fahrzeuge/{brand}) never
selected image_path from car_models, so an image set on a model never
reached the public page regardless of the frontend rendering added
earlier - the API response simply didn't include it. index()'s equivalent
query for /brands already had the column; this one was missed.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
parent
a3767b1c0f
commit
b690f7ef33
1 changed files with 1 additions and 1 deletions
|
|
@ -126,7 +126,7 @@ class BrandController
|
|||
}
|
||||
|
||||
$stmt = $db->prepare(
|
||||
'SELECT id, name, slug, sort_order FROM car_models WHERE brand_id = ? ORDER BY sort_order, name'
|
||||
'SELECT id, name, slug, image_path, sort_order FROM car_models WHERE brand_id = ? ORDER BY sort_order, name'
|
||||
);
|
||||
$stmt->execute([$brand['id']]);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue