Hi, i have a problem with a many2one field, when I create a new record and hit save the field on the form view is not filled with the record created.
Its happening with some many2one fields but others work as expected.
Field defined as folows:
treatment_id = fields.Many2one('hms.treatment',
string='Treatment', help="Treatment Id", states=READONLY_STATES)
I could not load an image of the form.
thanks, any help would be appreciatted.
Hi Jay:
I found the problem, its because the name field of the m2o model is generated via a sequence on the create function. It seems that as the name comes empty to the create nothing is show on the m2o field on the form after using "create and edit" on the dropdown. Any clues how to solve it? The name is like CASE0001.
Hello Reynaldo Ramirez,
When you get the data for this m2o field via onchnage or something ?
and this m2o is readonly field?