2017-08-24 9 views
2

これは私のコードです。 Odoo10でOdoo10の不思議な警告

<span t-esc="o.amount_total * (o.type in 'out_refund' and -1 or 1)" t-esc-options='{"widget": monetary, "display_currency": o.currency_id}'/> 

は、私は私のコードで何が間違っている、この警告

WARNING db odoo.addons.base.ir.ir_qweb.ir_qweb: Use new syntax for '<span t-esc="o.amount_total * (o.type in 'out_refund' and -1 or 1)" t-tag="span"/> 
widget monetary 
      ' monetary widget t-options (python dict instead of deprecated JSON syntax). 

を取得していますか?

答えて

0

これを試してください。

問題は、あなたはjsonとしてオプションを与えていますか? Python辞書として渡す必要があります。

<span t-esc="o.amount_total * (o.type in 'out_refund' and -1 or 1)" t-esc-options="{'widget': 'monetary', 'display_currency': o.currency_id}"/>