Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
2 Antwoorden
3972 Weergaven

Hi, I have a binary field (widget: image) but neither oth the two method work:


<img t-if="p.plato_ids.icono" t-att-src="'data:image/png;base64,%s' % p.plato_ids.icono"/>

(appears empty square)

  

<span t-field="p.plato_ids.icono" t-field-options='{"widget": "image"}'/>

(appears:  iVBORw0KGgoAAAANSUhEUgAAAH gAAAB3C.............)


anyone knows any other method? Thank you

Avatar
Annuleer
Auteur Beste antwoord

Finaly that worked form me:

<img t-attf-src="data:image/*;base64,{{p.plato_ids.icono}}"/>

Avatar
Annuleer
Beste antwoord

Hi,

Please check this,

<img t-att-src="'data:image/png;base64,%s' % to_text(object.name)"/>

Thanks
Aswini iWesabe 
Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
0
okt. 16
3674
1
mei 15
13934
1
jul. 25
1526
1
jul. 25
1810
1
mei 25
1508