How to get product thumbnail image in jinja

Hello,

I am customizing quotation print format… For that, I need to show the thumnail of product image. I tried it with:

<img src="{{ row.image}}" style="width: 54px !important" alt="{{ row.item_name }}" class="img-responsive" />

But when comparing with the default quotation template, it seems the image is resized in server.

How can I do it?

Furthermore, how can I check if product has image before using IMG tag?

Thanks

Jaime

{{ if row.image }}
<img src="{{ row.image}}" style="width: 54px !important" alt="{{ row.item_name }}" class="img-responsive" />
{{ endif }}

Hello… and is there a way to get the image thumbnail?

I’ve checked the default quotation, it’s not thumbnail. It’s the same photo, it’s just applied style max-width: 100%, so its size based on parent element (td).