Arsalan Sherwani
Arsalan Sherwani

Reputation: 560

How to store data to dynamic fields in openerp?

I have created a dynamic field through field_view_get function. The problem is that when I try to store data to this field it does not get stored. The field is not showing anything. I am confused because I think I will have to make an entry for this field in my database.

  1. How can this be done ?
  2. Second thing is how can we set a button to fields_view_get function ? If I want to create dynamic fields through a button click then will it be possible through fields_view_get or not?

    Please help. Thanks

Upvotes: 1

Views: 271

Answers (1)

TimoSolo
TimoSolo

Reputation: 7325

Make sure you have a store=True in the field definition, eg:

'level': fields.function(_get_level, string='Level', store=True, type='integer'),

for more help use the openerp forum: https://www.odoo.com/forum/Help-1

Upvotes: 1

Related Questions