Thursday, June 18, 2020
3 changes · master
Enhancements to existing features
Odoo now handles placeholders in translated messages more safely, reducing the chance that a bad translation breaks a workflow. Many existing messages were updated to the clearer format, improving translation quality and flexibility across languages.
Original PR description
Support two new syntaxes with `_()` method:
```py
_("This is so %s") % 2019
_("Text with %s placeholders", 42)
_("Text with %(num)s placeholders %(symbol)s", num=42, symbol="🧀")
```
The main benefit is to have a fallback on the source string if formating the
translated string fails (e.g. `"Foo %s"` translated `"Foo s%"`).
This PR converted most (but not all) calls to _ using placeholders to use the
new syntax. Hopefully, the remaining ones will be converted in the future and
avoid technical debt.
Use named placeholders when needed. If more than one placeholder is present in a
string, using named placeholder can be beneficial to reorder the placehodler
position (for languages like Japanese that do not use the same phrase
construction). On some sentences, it also brings clarity on the meaning of the
placeholders.
Task-id: 1853119Planning users can now start or open a chat by clicking an employee's avatar in the Gantt schedule. This makes it faster for managers and teams to contact the right person directly from the planning view.
Products created from the Barcode app during operations or inventory adjustments now default to Storable Product instead of Consumable. This better matches inventory workflows, helping ensure newly scanned or added products are tracked in stock correctly from the start.
Original PR description
This commit makes it so the default "Product Type" = "Storable
Product" ('type'='product') when creating a new product in the
barcode app's Operations or Inventory Adjustments. Previously the
default was "Consumable".
Specification 1 of Inventory Onboarding task.
Task: 2220129
Community PR: odoo/odoo#51676