Message 64243

Author
manish
Date
2021-02-03.07:53:59
Message id
64243

Content

While using on_change_with, the one2many is not updating automatically.
It is getting updated after saving.

@fields.depends(
    'test',
)
def on_change_with_critearea(self):
    vals = []
    if self.test:
        for test_critearea in self.test.critearea:
            vals.append({
                'name': test_critearea.name,
                'lower_limit': test_critearea.lower_limit,
                'upper_limit': test_critearea.upper_limit,
            })
    return vals

The one2many should update after selecting the test type (in screenshot attached).
Only blank spaces are showing.

Note- The same is working fine in gtk-client.

Files

File name Uploaded Type Details
before_saving.png manish, 2021-02-03.07:53:59 image/png view
History
Date User Action Args
2021-02-03 07:54:00manishsetmessageid: <1612335240.3716686.HJ7OWOIYQ4O2FO3K.issue10057@tryton.org>
2021-02-03 07:54:00manishlinkissue10057 messages
2021-02-03 07:53:59manishcreate

Showing 10 items. Show all history (warning: this could be VERY long)