Skip to Content
Меню
Вам необхідно зареєструватися, щоб взаємодіяти зі спільнотою.
Це запитання позначене
1660 Переглядів

I have this in my qweb report

 <span t-esc="formatLang(get_routing_data(o)[-1]['total'] , digits=3)"/>

it works ok, but sometimes it returns an empty list and then i get error index tuple out of range. how can i avoid it?

Аватар
Відмінити

Hello,

You have try if else condition in qweb ?

Related Posts Відповіді Переглядів Дія
1
груд. 24
4179
0
лист. 24
1692
2
лип. 24
3500
0
квіт. 24
2230
3
бер. 24
2665