İçereği Atla
Menü
Bu soru işaretlendi
2 Cevaplar
3223 Görünümler

I have the decimal precision in Price to five 0. The problem is that in Sales Orders is so ugly to see 5 zero because we only use max. 2. Is there any widget or code to put in the reports to say that in the uni price and total price only two 0  as decimal?

Avatar
Vazgeç
En İyi Yanıt

Hi,

try this,

  <span t-esc="'%.2f'% field_name"/>

Thanks !!!  


Aswini @ iWesabe

Avatar
Vazgeç

itharappa

Üretici

Am I able to change the dot for a coma?

please check this,

<span t-esc="str('%.2f'%obj.field_name).replace('.', ',')"/>

En İyi Yanıt
On reports you can set:
​<t t-esc="'%.2f' % (o.amount)"/>

for example, if o is the object and amount the field


Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
2
Oca 24
5914
0
Haz 23
2431
1
Ara 22
3812
0
Nis 22
2926
1
Nis 19
6604