Friday, March 3, 2023
7 changes
Resolved issues and error corrections
The Knowledge app now correctly keeps the Add Cover button responsive after interface updates. This prevents intermittent failures when users try to add a cover image, improving reliability without changing the feature itself.
Original PR description
Before this commit, and with the last version of owl [1], the knowledge_cover_selector_tour tour failed almost all the time, because at some point, the "Add cover" button had no mousedown event on it. This is because the useEffect used to add the event handler didn't correctly defined its dependencies: when the button changes, the handler must be re-added. It has been highlighted by the update of owl because it slightly changes the way refs are handled, and something that was luckily working before (whereas it shouldn't have) wasn't anymore. [1] odoo/odoo@abaf9d0e70a480252afcf0e08f2a3c68fbbafa00
Miscellaneous changes
Steps to reproduce ================== - Install CRM, Studio - Go to CRM - Open studio - Click on New Model - Complete the wizard -> Nothing happens visually Cause of the issue ================== The old controller state is kept when creating a new model opw-3058363 Forward-Port-Of: odoo/enterprise#37341
Original PR description
Steps to reproduce ================== - Install CRM, Studio - Go to CRM - Open studio - Click on New Model - Complete the wizard -> Nothing happens visually Cause of the issue ================== The old controller state is kept when creating a new model opw-3058363 Forward-Port-Of: odoo/enterprise#37341
Impacted versions: - 16.0+ ## Instanciate Behavior components after a collaborative step How to reproduce: - Edit a collaborative html_field in a form view with 2 users (in 2 distinct windows simultaneously) (i.e. a task in Project, there should be at least 2 tasks) - Be sure to click on the field with both user_1 and user_2 so the collaboration starts - Add one /article command block with user_1 - Click right of the received /article command block with user_2 Current beha
Original PR description
Impacted versions: - 16.0+ ## Instanciate Behavior components after a collaborative step How to reproduce: - Edit a collaborative html_field in a form view with 2 users (in 2 distinct windows…
Impacted versions: - 16.0+ ## Instanciate Behavior components after a collaborative step How to reproduce: - Edit a collaborative html_field in a form view with 2 users (in 2 distinct windows simultaneously) (i.e. a task in Project, there should be at least 2 tasks) - Be sure to click on the field with both user_1 and user_2 so the collaboration starts - Add one /article command block with user_1 - Click right of the received /article command block with user_2 Current behavior: - Sometimes, the cursor appears inside the /article command block, while it should be contenteditable=false (like a button) Issue: - The issue is that the Article Behavior was not properly instanciated, thus the contentEditable=false attribute could not be set. Fix: - trigger a `refresh_behaviors` event when the editor is reset (`resetEditor`) ## Ignore locks from Behavior components rendering in wysiwyg `setValue` How to reproduce: - Edit an html_field in a form view (on a model with at least 2 accessible records). i.e. in Project with at least 2 tasks and edit a task. - Add a lot of /article command blocks (i.e. 10) - Switch back and forth to and from the next record in the form view (button "next") Current behavior: - Traceback (may or may not happen, asynchronous "randomness") Issue: - Knowledge Behavior have asynchronous rendering which happens with the mutationObserver of the editor disconnected (because mutations should not be registered). If the resetContent happens before the lock is lifted, then the mutations for the content reset would not be registered Fix: - allow the `setValue` method to remove locks coming from Behavior components, and restart the observer if there is no lock left. Note: - When the "oe-protected" feature is fully implemented, Knowledge behaviors won't have to disconnect the mutationObserver of the editor, and this fix will be reverted. see odoo/odoo#113813 Task-3208896 Forward-Port-Of: odoo/enterprise#37589
From BS4 to BS5, the `form-control-file` class has disappeared and became `form-control`. This commit replaces the occurrences of the old class by the new one. It is necessary because by letting the old class, it is impossible to place a form label above a `File Upload` field. Indeed, since the `.form-control-file` CSS rule setting the `display` property to `block` has been removed, the file input now has `display: inline-block` by default, which is why the label would end up on the sam
Original PR description
From BS4 to BS5, the `form-control-file` class has disappeared and became `form-control`. This commit replaces the occurrences of the old class by the new one. It is necessary because by letting the…
From BS4 to BS5, the `form-control-file` class has disappeared and became `form-control`. This commit replaces the occurrences of the old class by the new one. It is necessary because by letting the old class, it is impossible to place a form label above a `File Upload` field. Indeed, since the `.form-control-file` CSS rule setting the `display` property to `block` has been removed, the file input now has `display: inline-block` by default, which is why the label would end up on the same line as the input, instead of on top. With `.from-control`, this rule is back, allowing to place the label on top again. After this commit, the look of the file input will change. This is because in BS4, with the `form-control-file` class, the input was the browser native one. It could be customized using `.custom-file` (and the associated `custom-file-*` classes). But in BS5, the file input is directly a custom one, thanks to custom styles added on top of `.form- control`. task-3071151 See [1] for the associated PR. [1]: https://github.com/odoo/odoo/pull/105872 Forward-Port-Of: odoo/enterprise#34495
Steps to reproduce the bug: - Go to any storable product - Click on ECO widget: - Type: New product introduction - Apply on: Product only - start revision and validate the changes - The version of the product becomes “2” - duplicate the product Problem: The new product keeps version “2” instead of starting from 1 opw-3179587 Forward-Port-Of: odoo/enterprise#37367 Forward-Port-Of: odoo/enterprise#37333
Original PR description
Steps to reproduce the bug:
- Go to any storable product
- Click on ECO widget:
- Type: New product introduction
- Apply on: Product only
- start revision and validate the changes
- The version of the product becomes “2”
- duplicate the product
Problem:
The new product keeps version “2” instead of starting from 1
opw-3179587
Forward-Port-Of: odoo/enterprise#37367
Forward-Port-Of: odoo/enterprise#37333Use case to reproduce: - Create a BoM with a step to fill a worksheet - Fill the worksheet and save Traceback. It uses `call` on `this.model.ormService`. However in web, only `this.model.orm` is define. With the fix, the call to server is correctly made but `self.super` is present and trigger another traceback. opw-3056872 Forward-Port-Of: odoo/enterprise#34033
Original PR description
Use case to reproduce: - Create a BoM with a step to fill a worksheet - Fill the worksheet and save Traceback. It uses `call` on `this.model.ormService`. However in web, only `this.model.orm` is define. With the fix, the call to server is correctly made but `self.super` is present and trigger another traceback. opw-3056872 Forward-Port-Of: odoo/enterprise#34033
The SEPA field was squeezed on the same line as the dates, which made it difficult to use. task-3169032 Forward-Port-Of: odoo/enterprise#37677
Original PR description
The SEPA field was squeezed on the same line as the dates, which made it difficult to use. task-3169032 Forward-Port-Of: odoo/enterprise#37677