跳至內容
選單
此問題已被標幟
7 回覆
28312 瀏覽次數

See image for better idea.

<span t-field="o.amount_total"/> 

Image is not display here so I have putted shareable link.


see link: https://drive.google.com/file/d/0B763E4hoUk59QjI0S0pqMG5CakE/view?usp=sharing

頭像
捨棄
最佳答案

Hello Jaydeep bhai...

I have done same thing in sale order report with monetary field.

<span t-field="doc.amount_total" t-field-options="{&quot;widget&quot;: &quot;False&quot;}"/>


Hope this will help you...

頭像
捨棄
最佳答案

Try this,

<span t-esc="float(o.amount_total)"/>

頭像
捨棄
作者

Hello CatsandDogs, Is it possible through ?

作者

<span t-field="o.amount_total"/>

I think, is not possible way to achieve that

最佳答案

Try, this one

In .py

_columns = {
    'amount' : fields.float("amount", digits_compute=dp.get_precision('Account'))
    'company_id': fields.many2one('res.company', 'Company', required=True),
    'company_currency_id': fields.related('company_id','currency_id',type="many2one",
         relation="res.currency",string="Company Currency",readonly=True,store=True),
}

In .xml,


<field name="company_currency_id" invisible="1"/>
<field name="amount" widget="monetary" options="{'currency_field': 'company_currency_id'}"/>





頭像
捨棄
作者

thanks

相關帖文 回覆 瀏覽次數 活動
1
1月 24
1804
1
6月 23
4240
1
4月 22
9422
1
11月 21
6084
2
3月 24
11364