Tuesday, July 23, 2024
36 changes · saas-17.4
Resolved issues and error corrections
Inventory locations will now be sorted by their full location path instead of an unused sequence value. This makes location lists and dropdowns more predictable and easier to scan, especially when working with parent and sublocations.
Original PR description
The sequence field was added to `stock_location` for incorrect reasons. Because of this, the field has no value and results in potentially incorrect ordering of the locations (e.g. in field dropdown) and also potentially results in unexpected ordering since ordering by `complete_name` typically results in easier grouping by location > sublocation, e.g.: parent parent > child 1 parent > child 1 > subchild 1 parent > child 2 parent > child 2 > subchild 2 Task: 4013661 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
This fix prepares Odoo to load dark mode styling correctly for screens that are loaded only when needed. It helps ensure a consistent dark mode experience as this capability is rolled out in Enterprise and later Community editions.
Original PR description
In https://github.com/odoo/odoo/commit/f1749d3299957e2949e0b78653266a5397bb213c, we forgot to prepare a bundle for the dark mode. Here we add a bundle 'web.assets_backend_lazy_dark'. It will be first used in enterprise and soon in community.
Dark mode styling is now correctly applied to lazy-loaded backend views, including the grid view and Studio. This ensures users get a consistent visual experience when working in dark mode.
Original PR description
In https://github.com/odoo/odoo/commit/f1749d3299957e2949e0b78653266a5397bb213c, we forgot to prepare a bundle for the dark mode. As a consequence, the grid view does not have the style it should have in dark mode. Here we use the newly introduced bundle 'web.assets_backend_lazy_dark' in https://github.com/odoo/odoo/pull/173620 to fix that and make studio use that bundle too in dark mode.
The close button in the planning slot portal pop-up has been repositioned so it appears correctly. This improves the visual polish and makes the modal easier for users to understand and close.
Original PR description
The button is misaligned in the modal of the planning slot's portal view. This PR will realign it correctly. task-3943384
Miscellaneous changes
Before this commit, when debug mode was activated, and we wanted to deactivate (by the debug menu, the command pallet or the settings links), the debug mode wasn't completely and correctly deactivated. The debug mode was removed from the URL and the debug menu wasn't accessible anymore, but not everything was deactivated. For instance : the settings were still there (Translations, Gamification Tools and Technical), the link tracker app is still visible, all the user technical rights and extra ri
Original PR description
Before this commit, when debug mode was activated, and we wanted to deactivate (by the debug menu, the command pallet or the settings links), the debug mode wasn't completely and correctly…
Before this commit, when debug mode was activated, and we wanted to deactivate (by the debug menu, the command pallet or the settings links), the debug mode wasn't completely and correctly deactivated. The debug mode was removed from the URL and the debug menu wasn't accessible anymore, but not everything was deactivated. For instance : the settings were still there (Translations, Gamification Tools and Technical), the link tracker app is still visible, all the user technical rights and extra rights are still shown. The issue occurs, because we just remove it from the URL (to setting the debug to `undefined`); this will remove the debug menu, but won't deactivate correctly the debug mode. To deactivate correctly the debug mode, the debug should be set to `0`; Note that, this commit will also solve a minor issue, that when activate the assets debugging, or test assets debugging from the debug menu, the rest of the query string was lost. This could lead to some errors, when reloading do to lost information. opw-4042335 opw-4047116 Forward-Port-Of: odoo/odoo#174155
A company that is carrying out a project financed with public money has the obligation to have the CUP code (and also the CIG) indicated on the purchase invoices. For non-PA customers, those fields are visible but not required and when filled in, will be presented in the XML. task-4032771 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173682
Original PR description
A company that is carrying out a project financed with public money has the obligation to have the CUP code (and also the CIG) indicated on the purchase invoices. For non-PA customers, those fields are visible but not required and when filled in, will be presented in the XML. task-4032771 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173682
Have a partner with district filled Create a Sale Order Print report Issue: District is missing opw-4020494 Forward-Port-Of: odoo/odoo#173166 Forward-Port-Of: odoo/odoo#172323
Original PR description
Have a partner with district filled Create a Sale Order Print report Issue: District is missing opw-4020494 Forward-Port-Of: odoo/odoo#173166 Forward-Port-Of: odoo/odoo#172323
Currently, when website snippets were translated and they had special characters in them, they would be escaped before adding them as the `data-name` attribute of the snippet, which escaped them again. When the snippet would be selected, the sidebar would get that `data-name` attribute and use it as the title, resulting in the characters still being escaped. This commit fixes that by not escaping the name beforehand, but only when used in raw HTML. Example of the problem (Mur d'images): !
Original PR description
Currently, when website snippets were translated and they had special characters in them, they would be escaped before adding them as the `data-name` attribute of the snippet, which escaped them again. When the snippet would be selected, the sidebar would get that `data-name` attribute and use it as the title, resulting in the characters still being escaped. This commit fixes that by not escaping the name beforehand, but only when used in raw HTML. Example of the problem (Mur d'images):  Forward-Port-Of: odoo/odoo#174018 Forward-Port-Of: odoo/odoo#173808
Steps to reproduce: ------------------- * Activate discount on lines on user parameters * Change the pricelist config to show discount to the customers * Open a PoS session with the modified pricelist * Create an order and apply some discount on the lines * Invoice and pay the order > Observation: On the invoice pdf you should have a line saying "Price discount from X -> X" but it's not there Why the fix: ------------ Before the fix we were comparing the `price_unit` on the line and
Original PR description
Steps to reproduce: ------------------- * Activate discount on lines on user parameters * Change the pricelist config to show discount to the customers * Open a PoS session with the modified pricelist * Create an order and apply some discount on the lines * Invoice and pay the order > Observation: On the invoice pdf you should have a line saying "Price discount from X -> X" but it's not there Why the fix: ------------ Before the fix we were comparing the `price_unit` on the line and the `lst_price` of the product. But if a discount was applied on the line the price unit is not affected, and so the line was never shown. To fix this we compare the `total_price` of the line with the `lst_price` multiplied by the quantity on the line. opw-4019107 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173687 Forward-Port-Of: odoo/odoo#172754
Current behavior: In hr_expenses, list and kanban views have different buttons being shown: list view displays 'New', 'Scan' and 'Create Report', while kanban view displays only 'New' and 'Upload'. In mobile, list view shows only 'New', and kanban shows 'Scan' and 'New'. Expected behavior: 'Create Report' button should be displayed in both list and kanban view, in mobile or desktop. In mobile list view, 'Scan' should also be displayed. Cause of the issue: The static view for list includ
Original PR description
Current behavior: In hr_expenses, list and kanban views have different buttons being shown: list view displays 'New', 'Scan' and 'Create Report', while kanban view displays only 'New' and 'Upload'.…
Current behavior: In hr_expenses, list and kanban views have different buttons being shown: list view displays 'New', 'Scan' and 'Create Report', while kanban view displays only 'New' and 'Upload'. In mobile, list view shows only 'New', and kanban shows 'Scan' and 'New'. Expected behavior: 'Create Report' button should be displayed in both list and kanban view, in mobile or desktop. In mobile list view, 'Scan' should also be displayed. Cause of the issue: The static view for list includes only button 'Scan' with display utility classes that hide the button in mobile. Similarly for 'Create Report' button in list. In Kanban, the button 'Create Report' has not been added. Fix: In the list view, 'Upload' button was added for desktop view, and the classes of the 'Scan' button were changed to display it in mobile view. The display utility classes for 'Create Report' were removed, so the button is displayed in mobile. In kanban view, button 'Create Report' was added. The main div of web.KanbanView.Buttons is replaced to ensure that the mobile view buttons are also displayed correctly. Without replacing it, the buttons 'New' and 'Scan' do not match the height of 'Create Report'. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#172442 Forward-Port-Of: odoo/odoo#169396
Steps to reproduce: - Install `l10n_fr_invoice_addr` - Switch to french company - Change "Colors" in "Document Layout" settings - Go to an invoice and click the "Preview" button Because of the inconsistent HTML tags used, the invoice styling wouldn't get applied to the columns added by `l10n_fr_invoice_addr`. This commit improves consistency with the pre-existing HTML hence fixing that issue See: #172497 task-4056046 Forward-Port-Of: odoo/odoo#174071 Forward-Port-Of: odoo/odoo#1732
Original PR description
Steps to reproduce: - Install `l10n_fr_invoice_addr` - Switch to french company - Change "Colors" in "Document Layout" settings - Go to an invoice and click the "Preview" button Because of the inconsistent HTML tags used, the invoice styling wouldn't get applied to the columns added by `l10n_fr_invoice_addr`. This commit improves consistency with the pre-existing HTML hence fixing that issue See: #172497 task-4056046 Forward-Port-Of: odoo/odoo#174071 Forward-Port-Of: odoo/odoo#173299
Users without administrative rights were unable to refund transactions because the call to `_send_refund_request` was made without `sudo`. This commit adds both the necessary `sudo` to bypass the access rights check on the transaction's payment acquirer and a manual access rights check on the transaction itself to prevent abusing RPC calls. opw-4033356 Forward-Port-Of: odoo/odoo#173953 Forward-Port-Of: odoo/odoo#173663
Original PR description
Users without administrative rights were unable to refund transactions because the call to `_send_refund_request` was made without `sudo`. This commit adds both the necessary `sudo` to bypass the access rights check on the transaction's payment acquirer and a manual access rights check on the transaction itself to prevent abusing RPC calls. opw-4033356 Forward-Port-Of: odoo/odoo#173953 Forward-Port-Of: odoo/odoo#173663
EAS codes 0037 and 0215 have been deprecated as of OpenPeppol eDEC codelists v8.9 https://docs.peppol.eu/edelivery/codelists/changelog.html We will place a warning in stable and remove it in master. no task Forward-Port-Of: odoo/odoo#173316
Original PR description
EAS codes 0037 and 0215 have been deprecated as of OpenPeppol eDEC codelists v8.9 https://docs.peppol.eu/edelivery/codelists/changelog.html We will place a warning in stable and remove it in master. no task Forward-Port-Of: odoo/odoo#173316
Problem: When attempting to paste text (either via right-click -> paste or using CTRL-V) into the chatter of a shared project, the action fails. This issue was caused by the addition of `event.preventDefault()` in the `ProjectSharingFormController` form. This does not affect the description field as it is also managed by `OdooEditor`. Steps to reproduce: 1. Share a project with a user. 2. Impersonate the user and navigate to the project from the portal. 3. Select a task. 4. Attempt to
Original PR description
Problem: When attempting to paste text (either via right-click -> paste or using CTRL-V) into the chatter of a shared project, the action fails. This issue was caused by the addition of `event.preventDefault()` in the `ProjectSharingFormController` form. This does not affect the description field as it is also managed by `OdooEditor`. Steps to reproduce: 1. Share a project with a user. 2. Impersonate the user and navigate to the project from the portal. 3. Select a task. 4. Attempt to paste something into the chatter. opw-4046529 Forward-Port-Of: odoo/odoo#173329
Currently, when using a company with french localization, if you try deleting lines on a draft order in the session, a new line is created to make the correction. Steps to reproduce: ------------------- * Switch to a company with french localisation * Open Pos shop session * Add products to the cart * Go to the backend * Go back to the session * Try deleting a line > Observations: A new line is added with negative quantity to cancel out the line we wanted to delete. Instead of just re
Original PR description
Currently, when using a company with french localization, if you try deleting lines on a draft order in the session, a new line is created to make the correction. Steps to reproduce:…
Currently, when using a company with french localization, if you try deleting lines on a draft order in the session, a new line is created to make the correction. Steps to reproduce: ------------------- * Switch to a company with french localisation * Open Pos shop session * Add products to the cart * Go to the backend * Go back to the session * Try deleting a line > Observations: A new line is added with negative quantity to cancel out the line we wanted to delete. Instead of just removing the first line. Why the fix: ------------ The line correction of the POS certification for the French localization is too restrictive. The law says that correction on validated orders should be made on new lines. For the order that are not validated, the lines can be changed normally. This is a backport of what will be merged in master as it is a compatible change in stable versions. This should not break the inalterability chain as you only pass through the functions `disallowLineQuantityChange()` and `can_be_merged_with()` with orders that are not locked (i.e. they have not been paid yet). Related ongoing task-id: 3874373 opw-3865724 Forward-Port-Of: odoo/odoo#173728 Forward-Port-Of: odoo/odoo#165468
As observed in https://github.com/odoo/odoo/pull/173442, the commit https://github.com/odoo/odoo/commit/6336366f772b18cd3731cc03f7ff3fc1eeca204a has introduced a bug for search panel filters that are based on many2many that are not groupable. Indeed, the computation of the domain image is done via _search_panel_domain_image that uses read_group and for many2many that are not groupable it is not allowed to use read_group. We fix that bug by computing the domain image via a search_read when the ma
Original PR description
As observed in https://github.com/odoo/odoo/pull/173442, the commit https://github.com/odoo/odoo/commit/6336366f772b18cd3731cc03f7ff3fc1eeca204a has introduced a bug for search panel filters that are based on many2many that are not groupable. Indeed, the computation of the domain image is done via _search_panel_domain_image that uses read_group and for many2many that are not groupable it is not allowed to use read_group. We fix that bug by computing the domain image via a search_read when the many2many is not groupable. opw-4055494 Forward-Port-Of: odoo/odoo#173977 Forward-Port-Of: odoo/odoo#173538
Steps to reproduce: - Install planning and switch to calendar view - try resizing the pill that is already resizable (pills that span for multiple days) Issue: pill resizing is not working as expected. Cause: the end date wasn't being calculated correctly for this. Fix: after this commit, the end date is calculated correctly. task-3326281 Forward-Port-Of: odoo/odoo#172276 Forward-Port-Of: odoo/odoo#139893
Original PR description
Steps to reproduce: - Install planning and switch to calendar view - try resizing the pill that is already resizable (pills that span for multiple days) Issue: pill resizing is not working as expected. Cause: the end date wasn't being calculated correctly for this. Fix: after this commit, the end date is calculated correctly. task-3326281 Forward-Port-Of: odoo/odoo#172276 Forward-Port-Of: odoo/odoo#139893
Currently, if you create a combo product, or modify an existing product into a combo product, the previous tax field is saved. Steps to reproduce: ------------------- * Create a new storable product with a tax set * Modify the product type to `Consumable` * Save > Observation: Next to the price we see "(=... tax incl) Why the fix: ------------ Combo products are not meant to have taxes set. It is confirmed by the fact that the field becomes invisible when we have combo products. Tax
Original PR description
Currently, if you create a combo product, or modify an existing product into a combo product, the previous tax field is saved. Steps to reproduce: ------------------- * Create a new storable product with a tax set * Modify the product type to `Consumable` * Save > Observation: Next to the price we see "(=... tax incl) Why the fix: ------------ Combo products are not meant to have taxes set. It is confirmed by the fact that the field becomes invisible when we have combo products. Taxes are computed once the product is added to the cart depending on the taxes of the products chosen. opw-4004978 Forward-Port-Of: odoo/odoo#172358
revert of https://github.com/odoo/odoo/commit/95abe082c27525c0a22a07c6457ea408163f339f it's not supposed to reach saas-17.1 and higher Forward-Port-Of: odoo/odoo#173994
Original PR description
revert of https://github.com/odoo/odoo/commit/95abe082c27525c0a22a07c6457ea408163f339f it's not supposed to reach saas-17.1 and higher Forward-Port-Of: odoo/odoo#173994
The adaptation for 3.12 broke some of the 3.11 packages compatibility This commit should fix them. See #173788 for more info Forward-Port-Of: odoo/odoo#173913
Original PR description
The adaptation for 3.12 broke some of the 3.11 packages compatibility This commit should fix them. See #173788 for more info Forward-Port-Of: odoo/odoo#173913
We compute the discount amount by calculating the amount before the discount first, and then computing the discount amount from there. If the discount is 100%, we get division by 0 error. If the discount is 100%, we should compute the amount before the discount using price_unit and quantity. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173871
Original PR description
We compute the discount amount by calculating the amount before the discount first, and then computing the discount amount from there. If the discount is 100%, we get division by 0 error. If the discount is 100%, we should compute the amount before the discount using price_unit and quantity. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173871
Steps to reproduce the bug: - Create a storable product “P1” - Go to Operation Type > Return > Enable "Create repair from return" - Create a delivery order with one unit of "P1" and validate it - Return the delivered "P1" - Create a repair order from this return - Select "P1" as the product to repair - Save (important step) - Add any product as a part of the repair, e.g., "Part 1” - Save - Go back to the return picking Problem: The product “Part 1” is linked to the return-picking.
Original PR description
Steps to reproduce the bug: - Create a storable product “P1” - Go to Operation Type > Return > Enable "Create repair from return" - Create a delivery order with one unit of "P1" and validate it -…
Steps to reproduce the bug: - Create a storable product “P1” - Go to Operation Type > Return > Enable "Create repair from return" - Create a delivery order with one unit of "P1" and validate it - Return the delivered "P1" - Create a repair order from this return - Select "P1" as the product to repair - Save (important step) - Add any product as a part of the repair, e.g., "Part 1” - Save - Go back to the return picking Problem: The product “Part 1” is linked to the return-picking. When the "repair" button is clicked to create the repair order, the function `action_repair_return` is triggered, adding `default_picking_id` in the context to link the repair to the picking. https://github.com/odoo/odoo/blob/bee32f88d42d9b945ec7216e2496e0167d3904b4/addons/repair/models/stock_picking.py#L40 However, this context is not cleared after the creation of the repair, therefore, when creating the stock move, this picking is added to the values of the moves due to the `_add_missing_default_values` function. Despite attempting to set `default_picking_id = False` for these moves, this will be ignored because the field `picking_id` is not present in this list view. **Solution:** Using `default_picking_id` in the context to create the repair order does not seem to be a good idea. This is the third issue related to this problem; two other fixes have already been made to address the propagation of these default keys. Therefore, it seems more logical to use the `default_get` function instead to avoid bugs related to this. https://github.com/odoo/odoo/commit/e822ec35c37237a9c137771d1d7266188a1877e8 https://github.com/odoo/odoo/commit/a32fb7b3e12ddae1ef7ebd78fa4877b2dbdbe6b1 opw-[4029460](https://www.odoo.com/web#id=4029460&view_type=form&model=project.task) Forward-Port-Of: odoo/odoo#172786
Currently if there are no IR rules preventing a low right user to write on a record, no error notification will appear when the user tries to add a property field to the child model since no error is raised in the checkDefinitionWriteAccess method. If this user does not have access rights on the model of the parent record an unwanted traceback will appear since nothing prevents him from trying to add a property field to the model Here we're using the canChangeDefinition which is loaded
Original PR description
Currently if there are no IR rules preventing a low right user to write on a record, no error notification will appear when the user tries to add a property field to the child model since no error is raised in the checkDefinitionWriteAccess method. If this user does not have access rights on the model of the parent record an unwanted traceback will appear since nothing prevents him from trying to add a property field to the model Here we're using the canChangeDefinition which is loaded by checkingAccessRight on the user at the start of the component startup Task-3815748 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#173028 Forward-Port-Of: odoo/odoo#158165
Before this commit, serializing a record would omit x2many and many2one fields if their related models were not loaded into the PoS. opw-3998097 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#172664
Original PR description
Before this commit, serializing a record would omit x2many and many2one fields if their related models were not loaded into the PoS. opw-3998097 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#172664
Current Behavior: Computation of the field `pos_order_count` on model `loyalty.program` is slow when there is a large number of `pos.order.line` records with `reward_id` set on them. Cause of the issue: The list comprehension done here --> https://github.com/odoo/odoo/blob/27ff3e0f64f53caa62c3022bd3b7c41e29a8e721/addons/pos_loyalty/models/loyalty_program.py#L59 The complexity is `O(len(self) * ((len(read_group_res) * len(program_reward_ids)) + len(read_group_res<sum method>)))` which pe
Original PR description
Current Behavior: Computation of the field `pos_order_count` on model `loyalty.program` is slow when there is a large number of `pos.order.line` records with `reward_id` set on them. Cause of the…
Current Behavior: Computation of the field `pos_order_count` on model `loyalty.program` is slow when there is a large number of `pos.order.line` records with `reward_id` set on them. Cause of the issue: The list comprehension done here --> https://github.com/odoo/odoo/blob/27ff3e0f64f53caa62c3022bd3b7c41e29a8e721/addons/pos_loyalty/models/loyalty_program.py#L59 The complexity is `O(len(self) * ((len(read_group_res) * len(program_reward_ids)) + len(read_group_res<sum method>)))` which performs slowly if the `self` and `read_group_res` are large. Improvement: Delegate the computation to Postgres and assign the values obtained from the result. Benchmark: In method `_compute_pos_order_count` Number of `pos.order.line` records eligible in computation --> 17803 Where `self` is a a `loyalty.program` recordset len(self)| Before (in seconds) | After PR (in seconds) | |---------|--------|--------| |1000| 177.28 s | 6.43 s | |212| 29.73 s| 0.5 s | Improvement by about 98% on average opw-3903159 Forward-Port-Of: odoo/odoo#172556 Forward-Port-Of: odoo/odoo#167386
Update Cla for Openforce --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#168681
Original PR description
Update Cla for Openforce --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#168681
When stock is not installed, the override of _fsm_ensure_sale_order in industry_fsm_stock doesn't auto-confirm sale order, so the test `test_qty_to_invoice_from_fsm` failed because the `qty_to_invoice` was set to 0 if the order was not confirmed. With this PR, the order is confirmed in the test flow if stock is not installed. opw-[4061485](https://www.odoo.com/web#id=4061485&view_type=form&model=project.task) Forward-Port-Of: odoo/enterprise#67116
Original PR description
When stock is not installed, the override of _fsm_ensure_sale_order in industry_fsm_stock doesn't auto-confirm sale order, so the test `test_qty_to_invoice_from_fsm` failed because the `qty_to_invoice` was set to 0 if the order was not confirmed. With this PR, the order is confirmed in the test flow if stock is not installed. opw-[4061485](https://www.odoo.com/web#id=4061485&view_type=form&model=project.task) Forward-Port-Of: odoo/enterprise#67116
Currently, log level error message occur when no company is found during scheduled actions run at line [1]. This commit changes 'logger.error' to 'logger.warning' to log a message instead of an error since this is not an actual error in the code base. [1]-https://github.com/odoo/enterprise/blob/ddc81ed35a6738739647db868c13236673695cff/l10n_ke_edi_oscu/models/res_company.py#L437-L438 sentry-5608113473 Forward-Port-Of: odoo/enterprise#66799
Original PR description
Currently, log level error message occur when no company is found during scheduled actions run at line [1]. This commit changes 'logger.error' to 'logger.warning' to log a message instead of an error since this is not an actual error in the code base. [1]-https://github.com/odoo/enterprise/blob/ddc81ed35a6738739647db868c13236673695cff/l10n_ke_edi_oscu/models/res_company.py#L437-L438 sentry-5608113473 Forward-Port-Of: odoo/enterprise#66799
## Issue: - When adjusting inventory for a product with packages from the barcode app, quantities that are not whole numbers will be rounded to the nearest whole number. ## Steps To Reproduce: - Create a product and include two other products in its packaging, specifying a non-whole number for the contained quantity. - In the barcode app, adjust the inventory by adding the created product and then save the changes. - Click on the small pen icon to modify the product's details. - Observe
Original PR description
## Issue: - When adjusting inventory for a product with packages from the barcode app, quantities that are not whole numbers will be rounded to the nearest whole number. ## Steps To Reproduce: -…
## Issue: - When adjusting inventory for a product with packages from the barcode app, quantities that are not whole numbers will be rounded to the nearest whole number. ## Steps To Reproduce: - Create a product and include two other products in its packaging, specifying a non-whole number for the contained quantity. - In the barcode app, adjust the inventory by adding the created product and then save the changes. - Click on the small pen icon to modify the product's details. - Observe that when adding the quantities with decimal values, they get rounded up to the nearest whole number. ## Solution: - In the `_increment` function, when the initial `value` is not a decimal (it does not contain a '.'), the fraction variable is not set, and the rounding defaults to 0. It's important to note that this issue does not occur when the `value` is a decimal, as the split function operates correctly. - To resolve this issue, instead of relying on the number of digits after the '.' in the `value`, we set the precision based on what is defined in the 'decimal.precision' model. This approach not only addresses the current issue but also resolves the underlying problem initially discussed in this PR https://github.com/odoo/enterprise/pull/53378 opw-3896929 Forward-Port-Of: odoo/enterprise#66535 Forward-Port-Of: odoo/enterprise#62505
Before, when the subscription cron create recurring invoices, it might create a credit note in case some already invoiced non recurring product had his ordered quantity set back to zero. The payment transaction created for this credit note will take the absolute total without taking into account the type of the entry process. This leads to a transaction charging the amount to the client instead of refunding him. As we don't want to allow automatic refund because it could lead to catastrophe
Original PR description
Before, when the subscription cron create recurring invoices, it might create a credit note in case some already invoiced non recurring product had his ordered quantity set back to zero. The payment transaction created for this credit note will take the absolute total without taking into account the type of the entry process. This leads to a transaction charging the amount to the client instead of refunding him. As we don't want to allow automatic refund because it could lead to catastrophe if a bug occurs, we decide to prevent the payment request if the amount is negative. In that case, we keep the draft invoice and keep the "payment_exception" flag to avoid running the subscription invoice cron again on that contract. opw-3874964 Forward-Port-Of: odoo/enterprise#66951 Forward-Port-Of: odoo/enterprise#64098
Steps: - Install l10n_nl_reports - Open GL for the year 2024 - Export XAF -> Period numbers are displayed from 401 to 412, instead of 01 to 12 in the exported file opw-3999985 Forward-Port-Of: odoo/enterprise#67127 Forward-Port-Of: odoo/enterprise#67098
Original PR description
Steps: - Install l10n_nl_reports - Open GL for the year 2024 - Export XAF -> Period numbers are displayed from 401 to 412, instead of 01 to 12 in the exported file opw-3999985 Forward-Port-Of: odoo/enterprise#67127 Forward-Port-Of: odoo/enterprise#67098
…ights The setup of the password from a related field would throw errors to user with accountant rights but no administration (settings) rights. This showed other access rights problems with the SBR implementation. The way we want to work with this is: an accountant without settings rights can set up the password through the wizard if no password is stored on the company (for databases that didn't start SBR with the status info module). Once the password is set and is correct (it is the ri
Original PR description
…ights The setup of the password from a related field would throw errors to user with accountant rights but no administration (settings) rights. This showed other access rights problems with the SBR implementation. The way we want to work with this is: an accountant without settings rights can set up the password through the wizard if no password is stored on the company (for databases that didn't start SBR with the status info module). Once the password is set and is correct (it is the right one for the certificate), it shouldn't ask the user to put it again and is thus hidden in the wizard. ticket-4024344 Forward-Port-Of: odoo/enterprise#66096
Moved iot.box view technical information to "Technical Information" tab. Task: 4033301 Forward-Port-Of: odoo/enterprise#66306
Original PR description
Moved iot.box view technical information to "Technical Information" tab. Task: 4033301 Forward-Port-Of: odoo/enterprise#66306
Only a few templates are fetched when the user tries to sync all the templates from the `WhatsApp Business Account` form view. Problem: The API request used to fetch all templates incorporates pagination. In the current scenario, the next URL to the subsequent page is included in the response, but we are not using it. Also, the limit parameter is not utilized in our API request to restrict the number of templates on a single page. Consequently, by default, 25 templates are received on the
Original PR description
Only a few templates are fetched when the user tries to sync all the templates from the `WhatsApp Business Account` form view. Problem: The API request used to fetch all templates incorporates pagination. In the current scenario, the next URL to the subsequent page is included in the response, but we are not using it. Also, the limit parameter is not utilized in our API request to restrict the number of templates on a single page. Consequently, by default, 25 templates are received on the first page. As a result, only templates received on the first page are being created or updated(i.e. 25). Solution: The limit to fetch 200 templates on a single page is added to obtain 200 templates in the first request. However, if there are more than 200 templates, the remaining ones will be fetched from the next page. This process will continue in a loop until all templates are received. Task-3903321 Forward-Port-Of: odoo/enterprise#62460
Steps to reproduce: - Start the tour and continue till the worksheet step - Click on worksheet stat button in the tour - Click on the worksheet name field Issue: - The tour continues. - An input fields needs to be inputted with something before moving on. Reason: - Incorrect configuration of trigger for this step Fix: - Re-target the trigger on input field and fix the run function task-3709542 Forward-Port-Of: odoo/enterprise#66956 Forward-Port-Of: odoo/enterprise#649
Original PR description
Steps to reproduce: - Start the tour and continue till the worksheet step - Click on worksheet stat button in the tour - Click on the worksheet name field Issue: - The tour continues. - An input fields needs to be inputted with something before moving on. Reason: - Incorrect configuration of trigger for this step Fix: - Re-target the trigger on input field and fix the run function task-3709542 Forward-Port-Of: odoo/enterprise#66956 Forward-Port-Of: odoo/enterprise#64956
Steps to reproduce: - Create a shipping method with sendcloud as provider. - In the field 'Default package type' create a package type and set 'Max Weight'(e.g 1kg). - Create a sales order, Add shipping, and select sendcloud. - Add 'Total order weight'(e.g 0.5kg) - Click 'Get rate' Returned rate for shipping is unusually big ammout. Before this commit: For sendcloud shipping if sendcloud_default_package_type_id is set, max_weight is stored in kilograms. When checking if the pack
Original PR description
Steps to reproduce: - Create a shipping method with sendcloud as provider. - In the field 'Default package type' create a package type and set 'Max Weight'(e.g 1kg). - Create a sales order, Add…
Steps to reproduce: - Create a shipping method with sendcloud as provider. - In the field 'Default package type' create a package type and set 'Max Weight'(e.g 1kg). - Create a sales order, Add shipping, and select sendcloud. - Add 'Total order weight'(e.g 0.5kg) - Click 'Get rate' Returned rate for shipping is unusually big ammout. Before this commit: For sendcloud shipping if sendcloud_default_package_type_id is set, max_weight is stored in kilograms. When checking if the package needs to be splitted, the target_weight is not being converted whereas the total_weight is.(check link at the bottom for details) Also in shipping rate request for sendcloud `max_weight` was sent in kilograms with `unit` being 'gram'. After this commit: `max_weight` is converted into grams before adding to the shipping rate request. split shipping code: https://github.com/odoo/enterprise/blob/d3b39fe78bc0ae366d32e80e325e89d2a4bb353c/delivery_sendcloud/models/sendcloud_service.py#L160-L162 opw-4035569 Forward-Port-Of: odoo/enterprise#66594