add if else for default image

This commit is contained in:
Maria Ozamiz
2021-03-26 09:06:24 +01:00
parent d6593188ef
commit 1399e9ac6e

View File

@@ -457,7 +457,18 @@
<img
alt=""
height="auto"
src="{{ product.image }}"
{%
if
product.image
%}
src="{{product.image.url}}"
{%
else
%}
src="DEFAULT_PRODUCT_IMAGE"
{%
endif
%}
style="
border: none;
display: block;
@@ -509,6 +520,16 @@
producto</span
>
<br />
<span
style="
font-size: 15px;
display: inline-block;
margin-top: 5px;
"
>Nombre del
producto</span
>
<br />
<span
style="
font-size: 15px;