Regression of #380089?
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo GTK Client (MOVED TO GITHUB) |
New
|
Undecided
|
Unassigned |
Bug Description
When a binary field has default 'readonly' state but conditionaly another, like
_columns {
...
field.binary(..., readonly=True, states={'init', [('readonly', False)]}, ...)
...
Then in an osv.memory wizard on state 'init', the widget has 'readonly=False' when opening the view, but after selecting the file, the widget switches to 'readonly=True', causing the widget to grey out and the loaded file to get lost in network traffic.
Weird enough, after changing the content of any other non-readonly field in the same view, the readonly-flag switches back again.
When de readonly flag in the model is dropped, and replaced with a 'attrs=' construct in the view, all things work as expected.
Expected behavior: a non-readonly binary widget should not switch state to readonly after selecting a file.
This bug or something very similar was reported once before and fixed in the 5.0 series under number #380089.
I'm using openerp-client 6.0.4 branched from launchpad at revno 1948 under Fedora 16 latest patch level.