Patch no image data final

This commit is contained in:
jleroy
2024-05-02 13:55:56 +02:00
parent 6cd102603e
commit 71bdd65ae2
3 changed files with 642 additions and 2 deletions

View File

@@ -18,7 +18,8 @@
<div class="card-body">
<div class="row">
<div class="col-12 col-md-4">
<img th:src="@{'/images/articles/' + ${article.id} + '.jpg'}" alt="image-vente" class="img-thumbnail" style="width: 100%; height: auto;">
<img th:if="${fileService.fileExists('/images/articles/' + article.id + '.jpg')}" th:src="'/images/articles/' + ${article.id} + '.jpg'" alt="Image de l'article" class="img-fluid rounded">
<img th:unless="${fileService.fileExists('/images/articles/' + article.id + '.jpg')}" th:src="@{/images/articles/no-data.jpg}" alt="Image de l'article" class="img-fluid rounded">
</div>
<div class="col-12 col-md-8">
<div class="mt-2 d-flex flex-column align-items-center">