Saturday, January 13, 2024
66 changes · master
Enhancements to existing features
Exporting translation files no longer prompts users to create a module as part of the process. This removes an unnecessary step, making translation exports clearer and faster for users who only need the files.
Original PR description
Description of the issue/feature this PR addresses: Disable module creation when exporting translation files Current behavior before PR: <img width="821" alt="image" src="https://user-images.githubusercontent.com/5561864/103731790-eff63e00-5020-11eb-962d-ff939357533b.png"> Desired behavior after PR is merged: <img width="804" alt="image" src="https://user-images.githubusercontent.com/5561864/103731840-161bde00-5021-11eb-84f6-d4986dc2e2be.png"> -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The view scale selector now disables the "show weekends" option when users choose a daily view, where that setting has no effect. This prevents confusion by making unavailable options clearer in calendar and grid views.
Original PR description
Currently, the ViewScaleSelector has the show weekends button enabled even when using a daily scale. Since both in calendar and in grid views, the daily scale makes the show weekend feature be ignored, it makes sense to disable it when the feature is not taken into account. task-3628487 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
Hovering over a stage in the project task kanban view no longer triggers an error. The change removes a broken hover tooltip that did not show useful information, improving reliability for project users.
Original PR description
Issue: When the user hovers the stage in a project task kanban view, a traceback appears. Reason: In the task kanban view, there is a groupby tooltip description. That is supposed to display a tooltip on stage hover with the description of the stage. However, the field description is not present on the project.task.type, which then triggers a traceback. Solution: Remove to tooltip on hover (which was already not displaying anything) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Features or functions removed from Odoo
The website forum module has had outdated back button code removed because it is no longer used. This is a low-impact cleanup that reduces unnecessary code without changing the forum experience for users.
Original PR description
This PR removes the forum back button code which is irrelevant as it is not used anywhere after the merge of https://github.com/odoo/odoo/commit/4bb00c2e838342260274fc73a1c5e11284f29dbf Task-3613078
Code cleanup and technical improvements
The Point of Sale online payment module's internal files were reorganized to match the project's standard structure. This does not introduce new customer-facing behavior, but it makes the module easier to maintain and evolve reliably.
Original PR description
In this commit we rearange the static files of the `pos_online_payment` module such that they respect the pattern established in e216528 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
In v16 the configuration of a pos.config got moved from Point of Sale to Settings, with new settings fields related to pos_config fields. The create method got overriden in point_of_sale to write values on the current pos_config after the creation of the new settings. The side-effect of doing so is that each creation of a res.config.setting, i.e. after changing any given setting (pos-related or not), triggers a write on ~50 fields of the current pos.config. Among those fields there are `modi
Original PR description
In v16 the configuration of a pos.config got moved from Point of Sale to Settings, with new settings fields related to pos_config fields. The create method got overriden in point_of_sale to write…
In v16 the configuration of a pos.config got moved from Point of Sale to Settings, with new settings fields related to pos_config fields. The create method got overriden in point_of_sale to write values on the current pos_config
after the creation of the new settings.
The side-effect of doing so is that each creation of a res.config.setting, i.e. after changing any given setting (pos-related or not), triggers a write on ~50 fields of the current pos.config. Among those fields there are `modifying_relations` fields that trigger recomputes on pos.order. Because pos.order can grow quite big in some databases (> 200.000 pos.orders), it makes it almost impossible to change any setting in these database. They reach a TimeoutError on SaaS/SH.
To fix this, this commit filter `pos_fields_vals` to only write new values on pos.config. If no value got changed since the last settings creation, no write is triggered, and no recompute happens.
Because we are in the context of res.config.settings create, and all the pos.config settings fields are related fields, everything should be in cache and no (or very few) query should be executed when doing this filtering.
This is done for res_config_settings in general in https://github.com/odoo/odoo/blob/3b24a13ee217b2d3846ad0953ccf8885d7b1f15a/odoo/addons/base/models/res_config.py
```python
old_value = field0.convert_to_record(
field0.convert_to_cache(vals[fname0], self), self)
for fname in fnames:
old_value = next(iter(old_value), old_value)[fname]
# determine the new value
new_value = field.convert_to_record(
field.convert_to_cache(vals[field.name], self), self)
# drop if the value is the same
if old_value == new_value:
vals.pop(field.name)
```
opw-3547106
opw-3508239
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#148756
Forward-Port-Of: odoo/odoo#139634This fixes a test setup issue that could occur when Luxembourg payroll accounting is installed without the Luxembourg reports module. It prevents automated report generation tests from failing due to missing Luxembourg-specific company fields, improving reliability without changing user-facing behavior.
Original PR description
We're trying to assign ecdf_prefix field and matr_number on a LU company in the test setup but these only exist if the l10n_lu_reports module is installed. Without that module, the test fails. With [11f7389](https://github.com/odoo/odoo/commit/11f73899ef60d56f9e4258d8d9732c8954b288fb) it is possible to have a situation where l10n_lu and account_reports are installed without the l10n_lu_reports module if there is no LU company. That happens when installing `l10n_lu_hr_payroll_account` for example.
Mobile push notifications now follow the same scheduled delivery timing as inbox, email, and web push notifications. This prevents messages from being sent too early when a business process needs to wait for user input or a later step before notifying users.
Current behavior: When adding a product with a variant, the variant page is not displayed correctly, it's missing the add to cart button. Steps to reproduce: - Create a product with a multi checkbox variant - Open self order menu on iOS - Click on the product - The "Add to cart" button is missing from the page opw-3614337 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148861
Original PR description
Current behavior: When adding a product with a variant, the variant page is not displayed correctly, it's missing the add to cart button. Steps to reproduce: - Create a product with a multi checkbox variant - Open self order menu on iOS - Click on the product - The "Add to cart" button is missing from the page opw-3614337 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148861
**[FIX] payment: show the payment methods buttons only on active providers** When the payment provider was disabled, the "Enabled Payment Buttons" was shown, although it was not possible to enable them yet. The button is now hidden until the provider's state is set to either 'enabled' or 'test'. ---- **[FIX] payment_custom: hide payment methods buttons on custom providers** Custom-flow payment providers should not allow assigning a different payment method than the one that was set.
Original PR description
**[FIX] payment: show the payment methods buttons only on active providers** When the payment provider was disabled, the "Enabled Payment Buttons" was shown, although it was not possible to enable them yet. The button is now hidden until the provider's state is set to either 'enabled' or 'test'. ---- **[FIX] payment_custom: hide payment methods buttons on custom providers** Custom-flow payment providers should not allow assigning a different payment method than the one that was set. --- **[FIX] payment: allow creating new payment methods from the provider** When browsing a payment provider's payment methods, the "New" button was disabled because the action did not allow Kanban views. Forward-Port-Of: odoo/odoo#148865
In this PR ------------- Before this commit: - The taxes column on invoice preview were displayed abit congested due to inherited attributes After this commit: - We have removed inherited attributes which resolves the above mentioned issue #### Before  #### After  --- I conf
Original PR description
In this PR ------------- Before this commit: - The taxes column on invoice preview were displayed abit congested due to inherited attributes After this commit: - We have removed inherited attributes which resolves the above mentioned issue #### Before  #### After  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148433
Since milk redesign the kanbancard lost their outline bottom on focus state. Previous fixes where applied to solve this issue in commit d8fcc218bc70caff4f4368309d7aa3be8b8ddaa5 and commit 2495bfa7259dcbd482b10c95a55313f86d594fcb. These fixes were a Catch-22: fixing a behavior here, creating an issue there (double borders, issue on drag..) which lead to more custom code. In this PR, we remove the code added by the previous fixes and apply a solution used in version 16.0 and prior. Relying
Original PR description
Since milk redesign the kanbancard lost their outline bottom on focus state. Previous fixes where applied to solve this issue in commit d8fcc218bc70caff4f4368309d7aa3be8b8ddaa5 and commit 2495bfa7259dcbd482b10c95a55313f86d594fcb. These fixes were a Catch-22: fixing a behavior here, creating an issue there (double borders, issue on drag..) which lead to more custom code. In this PR, we remove the code added by the previous fixes and apply a solution used in version 16.0 and prior. Relying on a negative margin to hide the border of the following `kanban_record` and applying an outline effect and a greater `z-index` on focus to make it appear on top of the border. This z-index is set to 2 to compensate the `z-index-1` on the kanban column when a card is focused and dragged. task-3580229 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#143345
Steps to reproduce: 1. Install a localization. For example l10n_ee. 2. Delete some tags to mimic an outdated module `DELETE FROM account_account_tag WHERE name->>'en_US' SIMILAR TO '(\+|-)1_1%';` 3. Click the reload button in accounting settings => Traceback This happens because we didn't update the localization module first, thus the tag is not yet created in the database. We now raise a UserError telling the user he probably needs to update the module. Forward-Port-Of: odoo/odoo#1489
Original PR description
Steps to reproduce: 1. Install a localization. For example l10n_ee. 2. Delete some tags to mimic an outdated module `DELETE FROM account_account_tag WHERE name->>'en_US' SIMILAR TO '(\+|-)1_1%';` 3. Click the reload button in accounting settings => Traceback This happens because we didn't update the localization module first, thus the tag is not yet created in the database. We now raise a UserError telling the user he probably needs to update the module. Forward-Port-Of: odoo/odoo#148956 Forward-Port-Of: odoo/odoo#148866
Uploadable modules latest_version is not fully defined (ex: 1.0 instead of 15.0.1.0), which lead to issues in the MigrationManager. **Steps to reproduce (in 17.0):** - make sure you have the industry repository in the addons-path and the upgrade one in the upgrade-path - create an empty database - On 'Hair Salon', click 'Activate' - On the 'Install an App' popup window, click 'Install' - Wait for the Hair Salon Industry to install > Once finished, go to the Website - Click 'Edit' to op
Original PR description
Uploadable modules latest_version is not fully defined (ex: 1.0 instead of 15.0.1.0), which lead to issues in the MigrationManager. **Steps to reproduce (in 17.0):** - make sure you have the industry…
Uploadable modules latest_version is not fully defined (ex: 1.0 instead of 15.0.1.0), which lead to issues in the MigrationManager. **Steps to reproduce (in 17.0):** - make sure you have the industry repository in the addons-path and the upgrade one in the upgrade-path - create an empty database - On 'Hair Salon', click 'Activate' - On the 'Install an App' popup window, click 'Install' - Wait for the Hair Salon Industry to install > Once finished, go to the Website - Click 'Edit' to open the website editor - Click 'Theme' - Next to the 'Theme' field under the 'Website' section, click 'Switch Theme' - Click 'Ok' on the Confirmation popup window - Click 'Use this theme' for the BEAUTY them - The 'Building your website...' animation begins ``` An error is thrown File "/home/odoo/src/odoo/17.0/odoo/addons/base/maintenance/migrations/theme_common/9.saas~13.1.1/pre-views.py", line 4, in <module> from openerp.addons.base.maintenance.migrations import util ModuleNotFoundError: No module named 'openerp' ``` opw-3589376 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148955 Forward-Port-Of: odoo/odoo#144393
Current behavior: When you create a new company branch, and setup a user that only have access to this branch. Then try to open the PoS app, you get an access error. This was happening because we try to read the company of the journal that is not accessible by the user when we do the `_compute_currency` Steps to reproduce: - Create a new company branch - Change demo user to only have access to this branch - Login as demo user - Open PoS app - Get access error opw-3640468 --- I con
Original PR description
Current behavior: When you create a new company branch, and setup a user that only have access to this branch. Then try to open the PoS app, you get an access error. This was happening because we try to read the company of the journal that is not accessible by the user when we do the `_compute_currency` Steps to reproduce: - Create a new company branch - Change demo user to only have access to this branch - Login as demo user - Open PoS app - Get access error opw-3640468 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148625
Have a fieldWidget using useRecordObserver. In its callback, have a line that will throw an error. Before this commit, the Promise created by the hook was not rejected, leaving the error untreated and popping until the window's onunhandledrejection event handler. After this commit, the error appears on the owl errors stack, catchable with the hook onError. opw-3667395 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is me
Original PR description
Have a fieldWidget using useRecordObserver. In its callback, have a line that will throw an error. Before this commit, the Promise created by the hook was not rejected, leaving the error untreated and popping until the window's onunhandledrejection event handler. After this commit, the error appears on the owl errors stack, catchable with the hook onError. opw-3667395 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148887
Steps to reproduce the bug: - Create a storable product “P1”: - Product category > Costing method: AVCO - Purchase tab: - Vendor: Azure interior - 190$ - Control Policy: On Ordered quantities - Create a Purchase order with P1: - Confirm - Create a bill and don’t post it - Try to validate the transfer Problem: A traceback is triggered: ``` File "/home/odoo/src/odoo/saas-16.4/addons/purchase_stock/models/stock_move.py", line 76, in _get_price_
Original PR description
Steps to reproduce the bug:
- Create a storable product “P1”:
- Product category > Costing method: AVCO
- Purchase tab:
- Vendor: Azure interior - 190$
- Control Policy: On Ordered quantities
- Create a Purchase order with P1:
- Confirm
- Create a bill and don’t post it
- Try to validate the transfer
Problem:
A traceback is triggered:
```
File "/home/odoo/src/odoo/saas-16.4/addons/purchase_stock/models/stock_move.py", line 76, in _get_price_unit
price_unit = float_round(remaining_value / remaining_qty, precision_digits=price_unit_prec)
ZeroDivisionError: float division by zero
```
opw-3667533
Forward-Port-Of: odoo/odoo#148911
Forward-Port-Of: odoo/odoo#148721Steps to reproduce: - Install Accounting and l10n_sa_edi - Connect with a non-admin user (e.g. Marc Demo) - Switch to a SA company - Create an invoice - Click on "SEND & PRINT" => A traceback is raised when trying to access the attachment linked to the ZATCA document. Cause: Since this commit https://github.com/odoo/odoo/commit/44a4cdb3944a4b722dcfbca5e2947a4372b8501d the attachment of an EDI document is restricted to users with "Administration: Settings" rights. opw-3663305
Original PR description
Steps to reproduce: - Install Accounting and l10n_sa_edi - Connect with a non-admin user (e.g. Marc Demo) - Switch to a SA company - Create an invoice - Click on "SEND & PRINT" => A traceback is raised when trying to access the attachment linked to the ZATCA document. Cause: Since this commit https://github.com/odoo/odoo/commit/44a4cdb3944a4b722dcfbca5e2947a4372b8501d the attachment of an EDI document is restricted to users with "Administration: Settings" rights. opw-3663305 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148892
Steps to reproduce: - Install Accounting - Configure an Email alias for Vendor Bills journal - Send an email to the alias with an PDF containing an embedded EDI XML and the EDI XML corresponding to the PDF as attachments Issue: - 2 bills are created (one with the PDF as attachment and one with the XML), instead of one with both PDF and XML as attachments - The PDF with the embedded XML is linked to the invoice created by the attached XML file and not the embedded one - The embedded X
Original PR description
Steps to reproduce: - Install Accounting - Configure an Email alias for Vendor Bills journal - Send an email to the alias with an PDF containing an embedded EDI XML and the EDI XML corresponding to the PDF as attachments Issue: - 2 bills are created (one with the PDF as attachment and one with the XML), instead of one with both PDF and XML as attachments - The PDF with the embedded XML is linked to the invoice created by the attached XML file and not the embedded one - The embedded XML is decoded before the attached XML file. Cause: The order in which the documents are decoded. opw-3604697 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#144243
Steps to reproduce ================== 1. Install event 2. Go to Events 3. Configuration > Event Templates 4. Click on any event 5. Click on Communication 6. Add a line, change type to SMS 7. Type anything in Template 8. Click on Create "..." 9. The operation cannot be completed Cause of the issue ================== For many2one and many2many editable fields, the server sets the can_create and can_write attributes on the field nodes. [1] [2] In some cases [3], those attribu
Original PR description
Steps to reproduce ================== 1. Install event 2. Go to Events 3. Configuration > Event Templates 4. Click on any event 5. Click on Communication 6. Add a line, change type to SMS 7. Type…
Steps to reproduce ================== 1. Install event 2. Go to Events 3. Configuration > Event Templates 4. Click on any event 5. Click on Communication 6. Add a line, change type to SMS 7. Type anything in Template 8. Click on Create "..." 9. The operation cannot be completed Cause of the issue ================== For many2one and many2many editable fields, the server sets the can_create and can_write attributes on the field nodes. [1] [2] In some cases [3], those attributes are missing even though the fields are actually editable. They are also absent for reference fields. The `canQuickCreate` props was set to the following value: `canCreate && !noQuickCreate`. When canCreate was absent, this was evaluated to undefined, thus ignoring the noQuickCreate option. Solution ======== When the permission attributes are missing, we have to assume that the user has the appropriate permissions. We also have to cast the extracted props to booleans as if you have an props with a value of undefined, it will fall back to the default value. In the test `no_quick_create option on a many2one when can_create is absent`, we set the field as readonly and then cancel the readonly on the view. This reproduces one of the bug of [3] which causes the permission attributes to be missing. ----- [1]: https://github.com/odoo/odoo/blob/fa6da3d63a3a4cce4e8ca788a49772925d318764/odoo/addons/base/models/ir_ui_view.py#L1296-L1297 [2]: https://github.com/odoo/odoo/blob/fa6da3d63a3a4cce4e8ca788a49772925d318764/odoo/addons/base/models/ir_ui_view.py#L1080-L1086 [3]: https://github.com/odoo/odoo/pull/138032 opw-3609799 Forward-Port-Of: odoo/odoo#148163 Forward-Port-Of: odoo/odoo#145433
Commit 8889a896f introduced the state in the address format for spain between parentheses, however if the state is unset this leads to weird values like ``` Isabella López Navarro () Spain ``` which is bad. This commit instead formats spanish addresses by adding the state below the Zip+City line and above the Country, as suggested here: https://en.wikipedia.org/wiki/Address#Spain This avoids empty parentheses. Task-3679058 Forward-Port-Of: odoo/odoo#149012
Original PR description
Commit 8889a896f introduced the state in the address format for spain between parentheses, however if the state is unset this leads to weird values like ``` Isabella López Navarro () Spain ``` which is bad. This commit instead formats spanish addresses by adding the state below the Zip+City line and above the Country, as suggested here: https://en.wikipedia.org/wiki/Address#Spain This avoids empty parentheses. Task-3679058 Forward-Port-Of: odoo/odoo#149012
Steps to reproduce the bug: -Go to /@/jobs/apply/experienced-developer-4 -Click on "Edit" button -Click anywhere in the form -Try to add a field -> Nothing happens Expected behavior: You should be able to add a field without any problem Explaination of the bug: A dynamic element is in the form (csrf_token) and it's preventing the form to be modified correctly. This was an articfact of a mistake made in the commit 9c7174589184c533e238defbbb0bcbd979092692 Behavior after the fix:
Original PR description
Steps to reproduce the bug: -Go to /@/jobs/apply/experienced-developer-4 -Click on "Edit" button -Click anywhere in the form -Try to add a field -> Nothing happens Expected behavior: You should be able to add a field without any problem Explaination of the bug: A dynamic element is in the form (csrf_token) and it's preventing the form to be modified correctly. This was an articfact of a mistake made in the commit 9c7174589184c533e238defbbb0bcbd979092692 Behavior after the fix: You can add a field without any problem task-3593111 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#143456
If the addons path does not contain enterprise, the industry module cannott be installed since all of them rely on knowledge. The same applies if there is a theme in the industry and that the design-themes repository is not in the addons-path. This commit raises a UserError in case the installation would fail due to a missing repository. Forward-Port-Of: odoo/odoo#147138
Original PR description
If the addons path does not contain enterprise, the industry module cannott be installed since all of them rely on knowledge. The same applies if there is a theme in the industry and that the design-themes repository is not in the addons-path. This commit raises a UserError in case the installation would fail due to a missing repository. Forward-Port-Of: odoo/odoo#147138
Description of the issue/feature this PR addresses: Before this commit there was a duplicate inheritance of report template `account.report_invoice_document` in files: `l10n_rs/views/account_move.xml` -> https://github.com/odoo/odoo/blob/16.0/addons/l10n_rs/views/account_move.xml#L15 `l10n_rs/views/report_invoice` -> https://github.com/odoo/odoo/blob/16.0/addons/l10n_rs/views/report_invoice.xml#L4 Current behavior before PR: This commit cleans the views and leaves only one template
Original PR description
Description of the issue/feature this PR addresses: Before this commit there was a duplicate inheritance of report template `account.report_invoice_document` in files: `l10n_rs/views/account_move.xml` -> https://github.com/odoo/odoo/blob/16.0/addons/l10n_rs/views/account_move.xml#L15 `l10n_rs/views/report_invoice` -> https://github.com/odoo/odoo/blob/16.0/addons/l10n_rs/views/report_invoice.xml#L4 Current behavior before PR: This commit cleans the views and leaves only one template Desired behavior after PR is merged: No visible difference, but removes confusion for future implementation/fixes. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148651
Prior to this commit, the date search was hardcoded to "yyyy-MM-dd HH:mm a", inconsistent with the system's date format display. This commit adjusts the date search to align with the system date format. opw-3677157 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148827
Original PR description
Prior to this commit, the date search was hardcoded to "yyyy-MM-dd HH:mm a", inconsistent with the system's date format display. This commit adjusts the date search to align with the system date format. opw-3677157 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148827
Previously, product attributes were not displaying correctly due to image retrieval from "product.attribute.value" conflicting with searches based on "product.template.attribute.value" IDs. This commit resolves the issue by ensuring the correct image display. opw-3666883 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148913
Original PR description
Previously, product attributes were not displaying correctly due to image retrieval from "product.attribute.value" conflicting with searches based on "product.template.attribute.value" IDs. This commit resolves the issue by ensuring the correct image display. opw-3666883 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148913
Steps to reproduce: ------------------- - install the "hr" module; - remove access rights for "Employees"; - change language on the user profile. Issue: ------ There's an Access Error because we can't read the `private_street` field on the employee that corresponds to the user. Cause: ------ The new version of onchange fetches the record values on the server side, unlike the old version which used the values in the view. In the old version, as we were using view values, this d
Original PR description
Steps to reproduce: ------------------- - install the "hr" module; - remove access rights for "Employees"; - change language on the user profile. Issue: ------ There's an Access Error because we…
Steps to reproduce: ------------------- - install the "hr" module; - remove access rights for "Employees"; - change language on the user profile. Issue: ------ There's an Access Error because we can't read the `private_street` field on the employee that corresponds to the user. Cause: ------ The new version of onchange fetches the record values on the server side, unlike the old version which used the values in the view. In the old version, as we were using view values, this didn't cause any problems, as the values came from a read that which took into account `SELF_READABLE_FIELDS`. Note: We do not have access to the value of the `private_street` field because it is a related field with the attribute `related_sudo=False` and we do not have access rights for the `hr.employee` model. Solution: --------- Use the cache and place the values of the fields in `SELF_READABLE_FIELDS` in it before performing the onchange logic. opw-3664929 Forward-Port-Of: odoo/odoo#148997
Before this commit when the user creates a task with a subtask and save the form view and then go to the form view of the subtask and set as project the same than the one set on the parent task, he cannot save the form view. The reason is because the framework JS considers there is nothing to save since in fact , the project set is the same than the parent by default, it is just not displayed in the interface thanks to the value of `display_in_project` field. The reason is to be able to let the
Original PR description
Before this commit when the user creates a task with a subtask and save the form view and then go to the form view of the subtask and set as project the same than the one set on the parent task, he…
Before this commit when the user creates a task with a subtask and save the form view and then go to the form view of the subtask and set as project the same than the one set on the parent task, he cannot save the form view. The reason is because the framework JS considers there is nothing to save since in fact , the project set is the same than the parent by default, it is just not displayed in the interface thanks to the value of `display_in_project` field. The reason is to be able to let the user choose if he wants to see the subtask in the main views (list/kanban) of tasks linked to the project or just below the parent task. This commit fixes the issue by forcing to update the `display_in_project` field even if it is not in the active fields since it is invisible in the interface and only the widget set on the project field will read and update it. Steps to reproduce: ================== - Install Project app - Go to the project app - Create project A - Create a task inside that Project A - Go to the form view of that task - Create a subtask - Save the form view - Go to the form view of the subtask - Set the project A as project for that subtask - Save the form view Current Behavior: ================ The form view cannot be saved because the framework JS considered there is in fact, nothing to save since `display_in_project` is not in the active fields and there is no force_save="1" set on the field in the view definition. Expected behavior: ================= The form view should be saved. Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149035
The ListRenderer disables the checkbox of all lines corresponding to a record which cannot be selected. Unfortunately, because `canSelectRecord` is a getter, it is invoked once per line, and this getter in turns invokes the `editedRecord` getter which scans all record to find which record is selected. This operation is O(n²), so it's very slow when there are a lot of records. This commit fixes that by computing the value once per render. Time to render the list view of views (technical > U
Original PR description
The ListRenderer disables the checkbox of all lines corresponding to a record which cannot be selected. Unfortunately, because `canSelectRecord` is a getter, it is invoked once per line, and this getter in turns invokes the `editedRecord` getter which scans all record to find which record is selected. This operation is O(n²), so it's very slow when there are a lot of records. This commit fixes that by computing the value once per render. Time to render the list view of views (technical > User Interface > views) with 600 records visible: - before: ~1800ms - after: ~250ms Forward-Port-Of: odoo/odoo#149051
Steps: 1. Install the Accounting module. 2. Enable cash rounding for Customer Invoices in the settings. 3. Activate Developer mode. 4. Navigate to Accounting > Configuration > Management > Cash Rounding. 5. Create a Cash Rounding rule with the following settings: a. Rounding Precision = 1 b. Rounding Method = UP c. Rounding Strategy = Add a rounding line. 6. Create a bill and apply the rounding rule. Add invoice lines with products priced at $99.5 and a tax rate of 15%. 7.
Original PR description
Steps: 1. Install the Accounting module. 2. Enable cash rounding for Customer Invoices in the settings. 3. Activate Developer mode. 4. Navigate to Accounting > Configuration > Management > Cash…
Steps: 1. Install the Accounting module. 2. Enable cash rounding for Customer Invoices in the settings. 3. Activate Developer mode. 4. Navigate to Accounting > Configuration > Management > Cash Rounding. 5. Create a Cash Rounding rule with the following settings: a. Rounding Precision = 1 b. Rounding Method = UP c. Rounding Strategy = Add a rounding line. 6. Create a bill and apply the rounding rule. Add invoice lines with products priced at $99.5 and a tax rate of 15%. 7. Confirm the invoice. 8. Access the cash rounding settings and change the Rounding Method to Down. 9. Open the bill, navigate to the "Other Info" page, and select the "To Check" option. This will result in a UserError: "You cannot modify the taxes related to a posted journal item, you should reset the journal entry to draft to do so." Reason: If there is any change in the rounding method after the journal entry is confirmed, the compute method of tax_totals is triggered when some field of that record is modified. This may lead to the creation of another journal item or changes to existing ones based on the new rounding configuration. However, performing this on a confirmed entry is restricted so it will raise UserError. Solution: Don't compute rounding according to the amount_total after its conformation. Instead, count it using journal items for type-rounding Task - 3468308 Forward-Port-Of: odoo/odoo#139422
To reproduce ============ - Website > Shipping methods > Pick-up in store - Add a description displayed on the eCommerce - add at least 3 or 4 lines with "enter" in between the lines. - from the shop select Pick-up in store, the payment button will be locked Problem ======= - The method `_disablePayButtonNoPickupPoint` checks if there are pickup points in a shipping method based on the count of children in the selected method - The description will be counted as child which breaks the
Original PR description
To reproduce ============ - Website > Shipping methods > Pick-up in store - Add a description displayed on the eCommerce - add at least 3 or 4 lines with "enter" in between the lines. - from the shop select Pick-up in store, the payment button will be locked Problem ======= - The method `_disablePayButtonNoPickupPoint` checks if there are pickup points in a shipping method based on the count of children in the selected method - The description will be counted as child which breaks the checking Solution ======== check the existence of `.o_list_pickup_locations` instead opw-3628025 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#146606
The user associated to an employee doesn't need to be in the same company of the employee. When this happens, we could get a multi company issue when trying to _only_ display the employee form. One way this issue is triggered is when the partner of the associated user is marked as partner_share=True. We may get an access error due to the rule `base.res_partner_rule`. Steps to reproduce: 1. Install HR module 2. Create an extra company with a user (U) on it. Ensure the partner of U is also se
Original PR description
The user associated to an employee doesn't need to be in the same company of the employee. When this happens, we could get a multi company issue when trying to _only_ display the employee form. One…
The user associated to an employee doesn't need to be in the same company of the employee. When this happens, we could get a multi company issue when trying to _only_ display the employee form. One way this issue is triggered is when the partner of the associated user is marked as partner_share=True. We may get an access error due to the rule `base.res_partner_rule`. Steps to reproduce: 1. Install HR module 2. Create an extra company with a user (U) on it. Ensure the partner of U is also set as belonging to this second company. 3. Create an employee in the first company with associated user U. 4. Archive U (this makes the partner of U get partner_share=True) 5. Try to access the employee form from the first company. We get an error: ``` Due to security restrictions, you are not allowed to access 'User' (res.users) records. Records: U (id=11, company=COMP2) User: Mitchell Admin (id=2) This restriction is due to the following rules: - user rule Note: this might be a multi-company issue. Contact your administrator to request access if necessary. Implicitly accessed through 'User' (res.users). ``` Since we allow hr.employee records to keep the associated archived user, to avoid this issue (potentially triggered differently) we opt to compute the avatar placeholder as sudo. The issue has been observed in multiple upgrade requests. Forward-Port-Of: odoo/odoo#148726 Forward-Port-Of: odoo/odoo#148325
Ngrok will be officially ending support for all ngrok agent versions 3.1 and older starting on January 15th, 2024. So with this commit we install the latest version of ngrok 3.5.0 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148829
Original PR description
Ngrok will be officially ending support for all ngrok agent versions 3.1 and older starting on January 15th, 2024. So with this commit we install the latest version of ngrok 3.5.0 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148829
Label of guest name on public discuss welcome page was gramatically incorrect. It should be "Logged in as" rather than "Logged as". Forward-Port-Of: odoo/odoo#148943 Forward-Port-Of: odoo/odoo#147984
Original PR description
Label of guest name on public discuss welcome page was gramatically incorrect. It should be "Logged in as" rather than "Logged as". Forward-Port-Of: odoo/odoo#148943 Forward-Port-Of: odoo/odoo#147984
Problem: The description of a down payment SOL does not recompute for a locked SO when an invoice is confirmed. Solution: Trigger the compute before it gets skipped due to the SO being locked. Purpose: The down payment line should include its reference to the invoice name despite the SO being locked or not. Steps to Reproduce on Runbot: 1. Install Sales 2. Enable "Lock Confirmed Sales" in Settings > Sale 3. Create a sales order and confirm 4. Create an invoice with down payment and
Original PR description
Problem: The description of a down payment SOL does not recompute for a locked SO when an invoice is confirmed. Solution: Trigger the compute before it gets skipped due to the SO being locked. Purpose: The down payment line should include its reference to the invoice name despite the SO being locked or not. Steps to Reproduce on Runbot: 1. Install Sales 2. Enable "Lock Confirmed Sales" in Settings > Sale 3. Create a sales order and confirm 4. Create an invoice with down payment and confirm 5. Refer back to the sales order and the down payment line's description does not contain the invoice name opw-3612298 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#148983
Issue: - when attempting to download the Picking Operations report for a product with packaging, the report generation fails with an error. Steps to Reproduce: - Configure a product to include packaging details. - Create a new quotation with the packaged product, and confirm it. - Proceed to validate the delivery. - In actions click on 'Print' > 'Picking Operations'. - Notice the error. Solution: - Update the field product_packaging_quantity to the correct field name product_packagi
Original PR description
Issue: - when attempting to download the Picking Operations report for a product with packaging, the report generation fails with an error. Steps to Reproduce: - Configure a product to include packaging details. - Create a new quotation with the packaged product, and confirm it. - Proceed to validate the delivery. - In actions click on 'Print' > 'Picking Operations'. - Notice the error. Solution: - Update the field product_packaging_quantity to the correct field name product_packaging_qty. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#147692
Before this commit: =================== If by-product is updated in mo after confirm then the initial by-product is considered and the new one is ignored in stock_move_line(Product moves). After this commit: ================== If by-product is updated in mo then the initial by-product will updated with new one in stock_move_line(Product moves). task: 3534703 Forward-Port-Of: odoo/odoo#149074 Forward-Port-Of: odoo/odoo#143779
Original PR description
Before this commit: =================== If by-product is updated in mo after confirm then the initial by-product is considered and the new one is ignored in stock_move_line(Product moves). After this commit: ================== If by-product is updated in mo then the initial by-product will updated with new one in stock_move_line(Product moves). task: 3534703 Forward-Port-Of: odoo/odoo#149074 Forward-Port-Of: odoo/odoo#143779
Issue: - The course filtering feature was consistently providing incorrect results, showing courses that were not related to the selected tags. This issue did not appear when logged in as an admin user. Steps to reproduce: - Install the eLearning app. - Navigate to the 'Courses' section on the website. - Click on a tag to filter the displayed courses. - Select additional tags to further filter the courses. - Observe that the results may not correspond to the selected tags. Soluti
Original PR description
Issue: - The course filtering feature was consistently providing incorrect results, showing courses that were not related to the selected tags. This issue did not appear when logged in as an admin user. Steps to reproduce: - Install the eLearning app. - Navigate to the 'Courses' section on the website. - Click on a tag to filter the displayed courses. - Select additional tags to further filter the courses. - Observe that the results may not correspond to the selected tags. Solution: - This inconsistency was caused by the t-cache directive in the template, which cached parts of the page and didn't always reflect the latest user interactions, like changing the selected tags. - Modify the t-cache directive so that it caches the content only when there are no search tags. opw-3636565 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#147106
Since [1], an error is raised when no app is detected on the clickbot. The issue with this is that it's possible for a user to no have access to any app. This occurs when we test single apps (web for instance) with demo user. The aim of the error is to detect if we are stuck on a tablet mode page. Now, we change the test on the ensureHomeMenu function, to don't have false positives, and detect correctly if we are stuck on a tablet mode page. Fixes runbot issue 52675 opw-3649047 [1]
Original PR description
Since [1], an error is raised when no app is detected on the clickbot. The issue with this is that it's possible for a user to no have access to any app. This occurs when we test single apps (web for instance) with demo user. The aim of the error is to detect if we are stuck on a tablet mode page. Now, we change the test on the ensureHomeMenu function, to don't have false positives, and detect correctly if we are stuck on a tablet mode page. Fixes runbot issue 52675 opw-3649047 [1] : 8f365824c9dddacf1b3a40688a30c8498df3d5d4 Forward-Port-Of: odoo/odoo#149044
Currently, the price difference amls are currently using today's date (so the date the bill is confirmed) for the exchange rate. It is weird, as the balance of those price difference amls then depends on the confirmation date of the bill. It is also weird, as they may also then use a different exchange rate than the other amls (that are using the bill date exchange rate). The fix is to use the bill date exchange rate. opw-3596209 Forward-Port-Of: odoo/odoo#149159 Forward-Port-Of: odoo/od
Original PR description
Currently, the price difference amls are currently using today's date (so the date the bill is confirmed) for the exchange rate. It is weird, as the balance of those price difference amls then depends on the confirmation date of the bill. It is also weird, as they may also then use a different exchange rate than the other amls (that are using the bill date exchange rate). The fix is to use the bill date exchange rate. opw-3596209 Forward-Port-Of: odoo/odoo#149159 Forward-Port-Of: odoo/odoo#146840
Commit [1] replaced all uses of env._t by calling the _t function directly, and removed _t from the env. This commit adapts a forgotten occurrence. c07181b20bf4f06b783136ffdb3b7a304be6b136 opw 3664779 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149176
Original PR description
Commit [1] replaced all uses of env._t by calling the _t function directly, and removed _t from the env. This commit adapts a forgotten occurrence. c07181b20bf4f06b783136ffdb3b7a304be6b136 opw 3664779 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149176
Before this commit user was able to archive the language used by superuser Odoobot by activating different language. Because of which whenever odoobot was in action then the user faced error. Steps to produce: - Install `contacts`. - Settings > Translations > Languages > Choose a language eg: English (UK). - Activate that language and switch to it. - In `contacts` change the language of each contact in the contacts to the newly selected language. - Settings > Translations > Language
Original PR description
Before this commit user was able to archive the language used by superuser Odoobot by activating different language. Because of which whenever odoobot was in action then the user faced error. Steps to produce: - Install `contacts`. - Settings > Translations > Languages > Choose a language eg: English (UK). - Activate that language and switch to it. - In `contacts` change the language of each contact in the contacts to the newly selected language. - Settings > Translations > Languages > Choose English (US) and archive it. - Settings > User & Companies > User, Apply the filter of Inactive Users. After this commit user would not be able to archive the language used by superuser or the language in which there db was installed. Task-2896526 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149147 Forward-Port-Of: odoo/odoo#143095
A model can specify a preferred company (cid) when redirecting someone from a mail link. Before this commit, this cid was taken into account when redirecting only if the user is logged in. This raises an AccessError when trying to access a record only visible from a certain company. With this commit, even if the user is not logged in, the redirect link will take that preferred cid into account. opw-3613144 Forward-Port-Of: odoo/odoo#149115 Forward-Port-Of: odoo/odoo#147913
Original PR description
A model can specify a preferred company (cid) when redirecting someone from a mail link. Before this commit, this cid was taken into account when redirecting only if the user is logged in. This raises an AccessError when trying to access a record only visible from a certain company. With this commit, even if the user is not logged in, the redirect link will take that preferred cid into account. opw-3613144 Forward-Port-Of: odoo/odoo#149115 Forward-Port-Of: odoo/odoo#147913
Currently, if account_peppol module is installed on a non-verified database, it is not possible to register on `l10n_it_edi`, even on the test server. That happens because we do not limit the demo mode to peppol. This commit adds an additional check for the proxy_type when handling demo. We wrap `make_request` in the decorator because it's used in many places in account_peppol, so the condition has to be added inside the decorator. --- I confirm I have signed the CLA and read the P
Original PR description
Currently, if account_peppol module is installed on a non-verified database, it is not possible to register on `l10n_it_edi`, even on the test server. That happens because we do not limit the demo mode to peppol. This commit adds an additional check for the proxy_type when handling demo. We wrap `make_request` in the decorator because it's used in many places in account_peppol, so the condition has to be added inside the decorator. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149016
Description of the issue/feature this PR addresses: - Update a module category to reference itself as parent OR - Update multiple module categories to create a circular dependency (A -> B -> A) Current behavior before PR: - Upgrade a module is impossible - Un/Install a module is impossible - Infinite loop: https://github.com/odoo/odoo/blob/15.0/odoo/addons/base/models/ir_module.py#L900 Desired behavior after PR is merged: - Circular dependencies not possible - Module can be upgrade
Original PR description
Description of the issue/feature this PR addresses: - Update a module category to reference itself as parent OR - Update multiple module categories to create a circular dependency (A -> B -> A) Current behavior before PR: - Upgrade a module is impossible - Un/Install a module is impossible - Infinite loop: https://github.com/odoo/odoo/blob/15.0/odoo/addons/base/models/ir_module.py#L900 Desired behavior after PR is merged: - Circular dependencies not possible - Module can be upgrade and un/install Retarget of: https://github.com/odoo/odoo/pull/134485 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#141820
Reduce spacing in product document form and align content in product document kanban details. task-3512072 Forward-Port-Of: odoo/odoo#140901
Original PR description
Reduce spacing in product document form and align content in product document kanban details. task-3512072 Forward-Port-Of: odoo/odoo#140901
...for orders made through Sales with loyalty programs that uses websites Problem: For loyalty & gift card programs that has sales and website enabled along with a specified website, the loyalty points will not accrue and gift card codes will generates for products if the SO was created with the Sales app. Solution: The SO ordered through the website should filter based on the website_id. SOs created through Sales will not have a website_id, thus, no need to add an extra filter for websit
Original PR description
...for orders made through Sales with loyalty programs that uses websites Problem: For loyalty & gift card programs that has sales and website enabled along with a specified website, the loyalty…
...for orders made through Sales with loyalty programs that uses websites Problem: For loyalty & gift card programs that has sales and website enabled along with a specified website, the loyalty points will not accrue and gift card codes will generates for products if the SO was created with the Sales app. Solution: The SO ordered through the website should filter based on the website_id. SOs created through Sales will not have a website_id, thus, no need to add an extra filter for website_id. Gift card codes will generate and loyalty points will accrue for orders made through Sales even if the program has a website specified. Steps to Reproduce on Runbot 16: Create a new product of the type consumable Go to Sales > Products > Gift cards & eWallet and click on NEW For the Gift Card Products field add the previously created product For the website field specify a specific website (e.g. My Website) Create a new sale order for the originally created product Confirm the sale order Click on the Customer Preview smart button You won’t see a gift card code anywhere when it should have been generated & Loyalty points are not accrued opw-3550278 opw-3587226 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#149112 Forward-Port-Of: odoo/odoo#146753
Before This PR: -------------------- If the username and password are wrong, then it only displays the error "108". After This PR: ------------------ If the username and password are wrong, then it displays the error. "[108] Invalid login credentials." task - 3304862 Forward-Port-Of: odoo/odoo#149305 Forward-Port-Of: odoo/odoo#120901
Original PR description
Before This PR: -------------------- If the username and password are wrong, then it only displays the error "108". After This PR: ------------------ If the username and password are wrong, then it displays the error. "[108] Invalid login credentials." task - 3304862 Forward-Port-Of: odoo/odoo#149305 Forward-Port-Of: odoo/odoo#120901
Create an Invoice with 2 lines of product Save Delete one Change currency Save Traceback will occur becasue of a ValueError ``` for command, line_id, line_vals in vals['invoice_line_ids'] ValueError: not enough values to unpack (expected 3, got 2) ``` opw-3672799 Forward-Port-Of: odoo/odoo#149261
Original PR description
Create an Invoice with 2 lines of product
Save
Delete one
Change currency
Save
Traceback will occur becasue of a ValueError
```
for command, line_id, line_vals in vals['invoice_line_ids']
ValueError: not enough values to unpack (expected 3, got 2)
```
opw-3672799
Forward-Port-Of: odoo/odoo#149261Peppol and Italian edi both uses a proxy user. We should only use Italian proxy users when checking demo mode otherwise Peppol production proxy users can interfere and trigger an error like 'Company already have prod connection'. Also we don't want to delete demo Peppol connections. opw-3675908 Forward-Port-Of: odoo/odoo#149173
Original PR description
Peppol and Italian edi both uses a proxy user. We should only use Italian proxy users when checking demo mode otherwise Peppol production proxy users can interfere and trigger an error like 'Company already have prod connection'. Also we don't want to delete demo Peppol connections. opw-3675908 Forward-Port-Of: odoo/odoo#149173
This commit fixes an annoying issue when using Odoo on a tablet or a PC when using the touch screen primarly. The virtual keyboard popped way too much when navigating in between views and screens, since the focus is often set on inputs (mostly the search bar with useAutofocus). To fix the useAutofocus hook, hasTouch is now being used instead of relying on the size of the screen. Autofocus test with isSmall has been adapted to specify that touch isn't modified, and that the autofocus is sti
Original PR description
This commit fixes an annoying issue when using Odoo on a tablet or a PC when using the touch screen primarly. The virtual keyboard popped way too much when navigating in between views and screens, since the focus is often set on inputs (mostly the search bar with useAutofocus). To fix the useAutofocus hook, hasTouch is now being used instead of relying on the size of the screen. Autofocus test with isSmall has been adapted to specify that touch isn't modified, and that the autofocus is still present. And another test has been added asserting the behavior on a touch device. task-3627697 Forward-Port-Of: odoo/odoo#148925 Forward-Port-Of: odoo/odoo#145207
This commit fixes a crash occuring when editing the 'effect' attribute being set on a button. task-3613476 Forward-Port-Of: odoo/enterprise#53354 Forward-Port-Of: odoo/enterprise#52679
Original PR description
This commit fixes a crash occuring when editing the 'effect' attribute being set on a button. task-3613476 Forward-Port-Of: odoo/enterprise#53354 Forward-Port-Of: odoo/enterprise#52679
This commit fixes the behavior of the focus on the home menu when using a touch oriented device. Before this commit, only the OS was considered, and touch screen PCs always displayed the virtual keyboard when accessing the home menu, since an invisible input was focused. Now, this input is no longer focused, and the user is not annoyed by the keyboard popping up on the screen. The hasTouch helper is used, since it can differentiate whether the laptop is currently using the touch screen or
Original PR description
This commit fixes the behavior of the focus on the home menu when using a touch oriented device. Before this commit, only the OS was considered, and touch screen PCs always displayed the virtual keyboard when accessing the home menu, since an invisible input was focused. Now, this input is no longer focused, and the user is not annoyed by the keyboard popping up on the screen. The hasTouch helper is used, since it can differentiate whether the laptop is currently using the touch screen or the physical inputs. task-3627697 Forward-Port-Of: odoo/enterprise#54074 Forward-Port-Of: odoo/enterprise#52221
Steps to reproduce ================== - Install hr,web_studio - Login with admin - Go to "My Profile" (top right) - Open studio - Add a field - Close studio - Login with demo - Go to "My profile" => There is an access error Cause of the issue ================== On the profile view, there are some fields that are present and the user has read access to using a whitelist SELF_READABLE_FIELDS. If we add another field with studio, it will not be in the whitelist and this wi
Original PR description
Steps to reproduce ================== - Install hr,web_studio - Login with admin - Go to "My Profile" (top right) - Open studio - Add a field - Close studio - Login with demo - Go to "My profile" => There is an access error Cause of the issue ================== On the profile view, there are some fields that are present and the user has read access to using a whitelist SELF_READABLE_FIELDS. If we add another field with studio, it will not be in the whitelist and this will fail the permission check. We cannot simply add a check to whitelist any manual fields, because this could cause some security issues. The res_users.get_view is also read called with sudo when the record is matching the current user. This means groups applied to custom fields from within studio won't restrict the field. Solution ======== Disable the edition of that view. opw-3598600 Forward-Port-Of: odoo/enterprise#53996 Forward-Port-Of: odoo/enterprise#53635
The `l10n_pe_edi_cancel_cdr_number` field undergoes cleaning during the cancellation process, making it inappropriate to rely on it as a confirmation of invoice cancellation. The recent update involves utilizing the EDI state to validate both the cancellation status and the prior signature of an invoice. Additionally, SUNAT requires all amounts to be set to 0 for canceled invoices in *SIRE* reports. Extra: Considering the Odoo option to show all entries, now the draft entries are added
Original PR description
The `l10n_pe_edi_cancel_cdr_number` field undergoes cleaning during the cancellation process, making it inappropriate to rely on it as a confirmation of invoice cancellation. The recent update involves utilizing the EDI state to validate both the cancellation status and the prior signature of an invoice. Additionally, SUNAT requires all amounts to be set to 0 for canceled invoices in *SIRE* reports. Extra: Considering the Odoo option to show all entries, now the draft entries are added on the preview, but ignored on the TXT file X-original-commit: 10f9d60f5ba8394b1a121b828f940518fca70ce9 Forward-Port-Of: odoo/enterprise#54270
client_order_ref The customer reference is needed to fill this value in "email_payment_reminder" template. ```xml Your subscription <t t-out="ctx.get('code') or ''">CODE</t> is still valid but will be <strong>suspended</strong> ``` Forward-Port-Of: odoo/enterprise#54124 Forward-Port-Of: odoo/enterprise#53319
Original PR description
client_order_ref
The customer reference is needed to fill this value in "email_payment_reminder" template.
```xml
Your subscription <t t-out="ctx.get('code') or ''">CODE</t> is still valid but will be <strong>suspended</strong>
```
Forward-Port-Of: odoo/enterprise#54124
Forward-Port-Of: odoo/enterprise#53319This commit adds email address to the data sent for the `Shipper`, `ShipFrom` and `ShipTo`. opw-3487959 Forward-Port-Of: odoo/enterprise#53759 Forward-Port-Of: odoo/enterprise#53578
Original PR description
This commit adds email address to the data sent for the `Shipper`, `ShipFrom` and `ShipTo`. opw-3487959 Forward-Port-Of: odoo/enterprise#53759 Forward-Port-Of: odoo/enterprise#53578
Companion of https://github.com/odoo/odoo/pull/148947. Forward-Port-Of: odoo/enterprise#54148
Original PR description
Companion of https://github.com/odoo/odoo/pull/148947. Forward-Port-Of: odoo/enterprise#54148
Commit [1] replaced all uses of env._t by calling the _t function directly, and removed _t from the env. This commit adapts forgotten occurrences. c07181b20bf4f06b783136ffdb3b7a304be6b136 opw 3664779 Forward-Port-Of: odoo/enterprise#54195
Original PR description
Commit [1] replaced all uses of env._t by calling the _t function directly, and removed _t from the env. This commit adapts forgotten occurrences. c07181b20bf4f06b783136ffdb3b7a304be6b136 opw 3664779 Forward-Port-Of: odoo/enterprise#54195
TO REPRODUCE 1. Create appt_type A with one resource R 2. Set work hours to 40h/week on resource R 3. Set max scheduled days on A to 14 days 4. Have a slot on A from 10.00 to 23.00 on the same weekday as now. (Let us say it's monday) 5. Go to front-end: the last available day (monday) will have slots until 23.00, despite the working hours restricting them to max 17.00. FIX As the last day's slots are computed for the whole day, the unavailabilities should also be computed. At the mo
Original PR description
TO REPRODUCE 1. Create appt_type A with one resource R 2. Set work hours to 40h/week on resource R 3. Set max scheduled days on A to 14 days 4. Have a slot on A from 10.00 to 23.00 on the same weekday as now. (Let us say it's monday) 5. Go to front-end: the last available day (monday) will have slots until 23.00, despite the working hours restricting them to max 17.00. FIX As the last day's slots are computed for the whole day, the unavailabilities should also be computed. At the moment, they are only We add one day to the checked range to ensure the unavailabilities of those slots. Task-3612857 Forward-Port-Of: odoo/enterprise#51589
Do not use main company in tests as it leads to issues if a localization is installed. This is also the opportunity to use AccountTestInvoicingCommon instead of creating accounting records manually. **steps to reproduce:** - install l10n_cz,partner_commission - run test test_commission_plan_assignation **before this commit:** - AssertionError: 5.76 != 18 : Commission is wrong **after this commit:** - tests do not use the localizations opw-3590037 Forward-Port-Of: odoo/enterprise
Original PR description
Do not use main company in tests as it leads to issues if a localization is installed. This is also the opportunity to use AccountTestInvoicingCommon instead of creating accounting records manually. **steps to reproduce:** - install l10n_cz,partner_commission - run test test_commission_plan_assignation **before this commit:** - AssertionError: 5.76 != 18 : Commission is wrong **after this commit:** - tests do not use the localizations opw-3590037 Forward-Port-Of: odoo/enterprise#54092 Forward-Port-Of: odoo/enterprise#53475
Currently, users may not know that the /clipboard command exists, may not know what they can do with it and may not know how to use it. To improve the onboarding experience and showcase the /clipboard command, we will integrate a demonstration video in the demo article. After watching this demonstration video, people should better understand the purpose of the /clipboard command and should know how to use it. task-3595599 Forward-Port-Of: odoo/enterprise#54122
Original PR description
Currently, users may not know that the /clipboard command exists, may not know what they can do with it and may not know how to use it. To improve the onboarding experience and showcase the /clipboard command, we will integrate a demonstration video in the demo article. After watching this demonstration video, people should better understand the purpose of the /clipboard command and should know how to use it. task-3595599 Forward-Port-Of: odoo/enterprise#54122
Steps(small device): - Install hr_timesheet - Go to timesheet > My timesheet - Hover on data in grid view - Daily overtime and weekly overtime is displayed Issue: - In mobile view, we don't have any indication that elements is clickable and overtime hours are shown. Improvement: - For mobile view, the overtime hours are kept constant rather than on hovering them. task-3429433 Forward-Port-Of: odoo/enterprise#50489
Original PR description
Steps(small device): - Install hr_timesheet - Go to timesheet > My timesheet - Hover on data in grid view - Daily overtime and weekly overtime is displayed Issue: - In mobile view, we don't have any indication that elements is clickable and overtime hours are shown. Improvement: - For mobile view, the overtime hours are kept constant rather than on hovering them. task-3429433 Forward-Port-Of: odoo/enterprise#50489
In Studio, creating a many2many field towards a model containing a group restricted field causes a crash. The group restricted field in the arch is tagged with the `studio_no_fetch` attribute to avoid studio from fetching it. However, this attribute is not parsed when placed in subviews. This commit prevents the group restricted field in subviews from being fetched by studio. Steps to reproduce: - Install CRM, Studio and Project - Go to CRM, open a record - Open Studio - Creat
Original PR description
In Studio, creating a many2many field towards a model containing a group restricted field causes a crash. The group restricted field in the arch is tagged with the `studio_no_fetch` attribute to avoid studio from fetching it. However, this attribute is not parsed when placed in subviews. This commit prevents the group restricted field in subviews from being fetched by studio. Steps to reproduce: - Install CRM, Studio and Project - Go to CRM, open a record - Open Studio - Create a new Many2many field with a relation to Project - Crash -> Studio read stage_id which is group protected opw-3603635 Forward-Port-Of: odoo/enterprise#54015
Steps to reproduce: (tested with l10n_be : sepa country) - set up SEPA Credit/debit Transfer - Create a bill with payment ref "Wynand & Olivier sont de joyeux drilles!" - Make a payment (for a belgian customer with an iban account set) - Go to Payment: slect the payment - Create a Batch Issue: The generated xml has the tag InstrId with a text of 39 characters instead of 35 Cause: We trim and sanitize the text https://github.com/odoo/enterprise/blob/6fae2c1a728e167120967743b5413bda
Original PR description
Steps to reproduce: (tested with l10n_be : sepa country) - set up SEPA Credit/debit Transfer - Create a bill with payment ref "Wynand & Olivier sont de joyeux drilles!" - Make a payment (for a…
Steps to reproduce: (tested with l10n_be : sepa country) - set up SEPA Credit/debit Transfer - Create a bill with payment ref "Wynand & Olivier sont de joyeux drilles!" - Make a payment (for a belgian customer with an iban account set) - Go to Payment: slect the payment - Create a Batch Issue: The generated xml has the tag InstrId with a text of 39 characters instead of 35 Cause: We trim and sanitize the text https://github.com/odoo/enterprise/blob/6fae2c1a728e167120967743b5413bda5a12d92e/account_sepa/models/account_journal.py#L350 But we don't convert the "&". And in https://github.com/odoo/enterprise/blob/ca40a44463f18181b687cf431dc18a5c2593775e/account_sepa/models/account_journal.py#L175 the `&` seems to be converted to `&` -> 39 characters instead of 35 Solution: if a trim is necessary (length is important) 1) replace &<> 2) trim 3) unescape So when etree does its "popote" the length is respected opw-3628530 Forward-Port-Of: odoo/enterprise#53859 Forward-Port-Of: odoo/enterprise#52770
Steps to reproduce: - Go on Accounting > Dashboard > Bank: running balance - Set "6000" > unfold lines - Go back on the accounting dashboard and comes back on running balance Issue: The default filter is overriden and the report has erratic behaviour Cause: previous option is selected after https://github.com/odoo/enterprise/pull/47669 solution: Make sure no default filter is existing opw-3628605 Forward-Port-Of: odoo/enterprise#53083
Original PR description
Steps to reproduce: - Go on Accounting > Dashboard > Bank: running balance - Set "6000" > unfold lines - Go back on the accounting dashboard and comes back on running balance Issue: The default filter is overriden and the report has erratic behaviour Cause: previous option is selected after https://github.com/odoo/enterprise/pull/47669 solution: Make sure no default filter is existing opw-3628605 Forward-Port-Of: odoo/enterprise#53083