related field on odoo?

后端 未结 2 1972
轻奢々
轻奢々 2020-12-17 23:43

how to add a field related on odoo
I would like to add a text field on stock.move related to stock.picking origin field
I tried this :

_columns={         


        
2条回答
  •  感动是毒
    2020-12-17 23:52

    You can find more information here : Link

    In the new API, there is not anymore fields.related. You should define your related field like this :

       sourcebl = fields.Char(string='Class Description', related='picking_id.origin')
    

提交回复
热议问题