Skip to content
Snippets Groups Projects
Commit 58c64558 authored by Nicolas Lempereur's avatar Nicolas Lempereur
Browse files

[FIX] web: checkbox readonly is RO in list editable


Since f4fbaf1e the structure of checkboxes has been improved, now we
have something like:

```
 <input type="checkbox" id="checkbox-18" class="custom-control-input">
 <label for="checkbox-18" class="custom-control-label">&#8203;</label>
```

With the first input invisible (whilst before it was visible and the
clickable element).

This cause an issue in an editable list view:

- we have a boolean readonly field in a cell
- we are on focused on a line (not in the boolean field cell)
- we click on the boolean field

=> the check mark is toggled

This is because when we switch cell, we try to activate the widget of
the other cell. Before f4fbaf1e this issue did not happen since the
browser do not generate a click event when clicking a disabled checkbox.

With this changeset, a disabled FieldBoolean is not focusable as is the
case for other fields, so we can't "activate" it.

Without the fix, the added test fails with:

 [clicking disabled checkbox did not work]

opw-1958433
closes #32652

Signed-off-by: default avatarAaron Bohy (aab) <aab@odoo.com>
parent 385342b5
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment