[FIX] web: owl_compatibility: force status 1 on attach callback

When a widget is detached form the DOM, we manually set the owl status of
the corresponding node to 0 (new), but we before this commit, we didn't reset it
to 1 (mounted) when the widget was re-attached. As a consequence, event handlers
were not bound anymore.

Steps to reproduce:
  - Open Inventory
  - Click on Products > Lots/Serial Numbers
  - Open a product
  - Click on the Traceability smart button
  - Click on a reference (eg: Inventory Adjustment)
  - Click on the Traceability Report breadcrumb
  -> Breadcrumbs are not working anymore

opw-2838994

closes odoo/odoo#95375

X-original-commit: 7945f7c40045def5e46e8a2f91bdfcc3a42d9f78
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
This commit is contained in:
Hubert Van de Walle (huvw)
2022-07-06 09:30:43 +02:00
parent 4e67c4adeb
commit 91d58bd260
@@ -689,6 +689,7 @@ odoo.define('web.OwlCompatibility', function (require) {
cb();
}
});
this.node.status = 1;
this.status = "mounted";
}