Friday, February 7, 2025
51 changes · saas-18.1
Enhancements to existing features
When users create a banner next to existing text, the editor now moves that text into the new banner instead of placing the banner after it. This makes page editing more intuitive and reduces extra cleanup when formatting existing content.
Original PR description
**Current behavior before PR:** - Creating a banner besides existing text will creates the banner after the current text block. **Desired behavior after PR is merged:** - Now, creating a banner besides existing text will move the current text block inside the newly created banner. task: 4214029
Subscription payments made through the customer portal now rely on the standard payment follow-up process to create invoices instead of creating draft invoices earlier in the portal step. This reduces duplicated logic and lowers the risk of inconsistent invoice handling for subscription renewals.
Original PR description
Before this commit, the /my/subscriptions/<int:order_id>/transaction route would create a draft invoice when it was called to anticipate a payment. post processing of payment.transaction is able to create the invoice and to associate it with the correct sale.order. In order to simplify the code by limiting the part of the code where subscription invoices can be created, we decided to let the _post_process do the work. taskid: 4368037
Resolved issues and error corrections
This update ensures the point-of-sale invoice toggle works reliably for Chilean and Mexican electronic invoicing. It helps prevent timing issues during payment that could affect whether an order is correctly marked for invoicing.
Original PR description
*: l10_cl, l10_mx In this commit: === - The main toggleIsToInvoice function is async, so added async and await where necessary to ensure proper execution. related-https://github.com/odoo/odoo/pull/195378 task-4517944
Miscellaneous changes
HTML content is often saved as XML (i.e. through templates) and saved as such in the database. This introduces issues when elements are written under their `self-closing` format (i.e. `<a/>` or `<br/>`) as browsers will incorrectly parse these values as HTML by adding a closing tag at an arbitrary position which may modify the initial nodes configuration. This can be prevented by post-processing untrusted content before the html parsing. This commit is an overhaul of: https://github.com/odoo
Original PR description
HTML content is often saved as XML (i.e. through templates) and saved as such in the database. This introduces issues when elements are written under their `self-closing` format (i.e. `<a/>` or…
HTML content is often saved as XML (i.e. through templates) and saved as such in the database. This introduces issues when elements are written under their `self-closing` format (i.e. `<a/>` or `<br/>`) as browsers will incorrectly parse these values as HTML by adding a closing tag at an arbitrary position which may modify the initial nodes configuration. This can be prevented by post-processing untrusted content before the html parsing. This commit is an overhaul of: https://github.com/odoo/odoo/commit/26b922ef5cad42da7e188195e919e54878d472fc https://github.com/odoo/odoo/commit/1a8a943d8373864165cb513b3767b866d626fad8 https://github.com/odoo/odoo/commit/4e547b24a323f8e59a11c5b78cbea38effc37938 in order to apply the conversion at critical entry points for editor assets: - HtmlField is an entry point for data coming from the server, stored on the record. Every access of the record data should not be trusted and go through the post-processing. - HtmlViewer is an entry point as it can be used as a standalone (see `website_knowledge`, or the HistoryDialog) for data coming from the server. - Editor is an entry point as it was developed to be useable as a standalone. task-4547973 Forward-Port-Of: odoo/odoo#196442
This fixes a typo that prevented some custom drill-down menus in financial reports from opening correctly. Businesses using customized account reports should now be able to access the expected details from report lines without interruption.
Original PR description
Currently the caret build with cutom groupby map could not work as there was a typo made during this commit: https://github.com/odoo/enterprise/commit/f8f7196030c257e3343b0725b5a0b3779d57c8ac task-4555964
Versions -------- - saas-17.4+ Steps ----- 1. Go eCommerce products page; 2. click on a product; 3. use browser's "Go back" button to go back. Issue ----- There's no going back. Cause ----- PR https://github.com/odoo/odoo/pull/157412 modified the `_setUrlHash` method used to manage product attributes. One of the changes it made is modified the current URL using `window.location.hash` instead of `window.location.replace`. While both methods can make identical changes to the
Original PR description
Versions -------- - saas-17.4+ Steps ----- 1. Go eCommerce products page; 2. click on a product; 3. use browser's "Go back" button to go back. Issue ----- There's no going back. Cause ----- PR…
Versions -------- - saas-17.4+ Steps ----- 1. Go eCommerce products page; 2. click on a product; 3. use browser's "Go back" button to go back. Issue ----- There's no going back. Cause ----- PR https://github.com/odoo/odoo/pull/157412 modified the `_setUrlHash` method used to manage product attributes. One of the changes it made is modified the current URL using `window.location.hash` instead of `window.location.replace`. While both methods can make identical changes to the URL, a key side-effect of `Location:replace()` is that the URL being replaced won't get saved in the session's `History`[^1]. As this method is called the moment the page loads, modifying the URL via `location.hash` will store the initial product page URL without attribute hashes in the session history. Then when trying to navigate back, the method will be called again immediately to apply attribute hashes, again modifying the session history, making it virtually impossible to leave the page without clicking a new URL. Solution -------- Use `history.replaceState`[^2] to update the current state, and not create any new entries. Also re-introduce early return when there are no product attributes to avoid polluting URLs, originally added in https://github.com/odoo/odoo/pull/159474 but removed via https://github.com/odoo/odoo/pull/157412. opw-4416701 [^1]: https://developer.mozilla.org/en-US/docs/Web/API/Location/replace [^2]: https://developer.mozilla.org/en-US/docs/Web/API/History/replaceState Forward-Port-Of: odoo/odoo#196858 Forward-Port-Of: odoo/odoo#194712
This commit adds the possibility to fetch attributes of a template configured on Gelato to automatically create the corresponding variants in Odoo. When such variant is included in a sales order, the order is forwarded to Gelato to trigger the printing and dropshipping of the product. task-3935688 See also: - https://github.com/odoo/enterprise/pull/77839 - https://github.com/odoo/documentation/pull/11823 Forward-Port-Of: odoo/odoo#193457
Original PR description
This commit adds the possibility to fetch attributes of a template configured on Gelato to automatically create the corresponding variants in Odoo. When such variant is included in a sales order, the order is forwarded to Gelato to trigger the printing and dropshipping of the product. task-3935688 See also: - https://github.com/odoo/enterprise/pull/77839 - https://github.com/odoo/documentation/pull/11823 Forward-Port-Of: odoo/odoo#193457
This fix prevent blank screen (when offline) & inifinte loop (when in 3G or other low connection) on order screen. - **Offline Mode:** When accessing the order screen offline, now the screen loads previously fetched orders and displays a "Limited Functionality" popup. - **Slow Connection (3G):** Infinite loop (caused by repeated call to `await this.pos.getServerOrders()`) is fixed by ensuring orders load only once, even on slow connections using the flag `loadingOrderState` task-id: 455
Original PR description
This fix prevent blank screen (when offline) & inifinte loop (when in 3G or other low connection) on order screen. - **Offline Mode:** When accessing the order screen offline, now the screen loads previously fetched orders and displays a "Limited Functionality" popup. - **Slow Connection (3G):** Infinite loop (caused by repeated call to `await this.pos.getServerOrders()`) is fixed by ensuring orders load only once, even on slow connections using the flag `loadingOrderState` task-id: 4550978 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#196810
Running the “test_workcenter_with_resource_calendar_from_another_company” without demo data occurs an error because the resource calendar. Forward-Port-Of: odoo/odoo#196656
Original PR description
Running the “test_workcenter_with_resource_calendar_from_another_company” without demo data occurs an error because the resource calendar. Forward-Port-Of: odoo/odoo#196656
Before this commit, depositing money for a customer with a zero balance could result in the creation of an empty order upon refreshing the browser. This issue arose because empty orders without payments were being synchronized, leading to unintended empty orders in the system. This commit addresses the problem by ensuring that empty orders without payments are not synchronized and prevents the creation of such empty orders during the deposit process. opw-4483049 --- I confirm I have si
Original PR description
Before this commit, depositing money for a customer with a zero balance could result in the creation of an empty order upon refreshing the browser. This issue arose because empty orders without payments were being synchronized, leading to unintended empty orders in the system. This commit addresses the problem by ensuring that empty orders without payments are not synchronized and prevents the creation of such empty orders during the deposit process. opw-4483049 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#195850 Forward-Port-Of: odoo/odoo#195468
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
Original PR description
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
Prevent subscription to undefined channel name in Self Order. Forward-Port-Of: odoo/odoo#196637
Original PR description
Prevent subscription to undefined channel name in Self Order. Forward-Port-Of: odoo/odoo#196637
Error runbot: 111972 Forward-Port-Of: odoo/odoo#196617
Original PR description
Error runbot: 111972 Forward-Port-Of: odoo/odoo#196617
Sign the CLA in name of Letzdoo https://www.letzdoo.com --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#196914
Original PR description
Sign the CLA in name of Letzdoo https://www.letzdoo.com --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#196914
### Issue: Curently, the reservation state of a production is computed from the status of the move raws that are not picked. This includes moves wihtout demands which should not infer with the reservation state at all. ### Steps to reproduce: - In the settings, Enable "Multi-Step Routes" - Go to Inventory > Configuration > Warehouse Management > Warehouses - Put your warehouse in 2 steps-manufacturing - Create a final product (FP) tracked by Serial number, and 2 storable components:
Original PR description
### Issue: Curently, the reservation state of a production is computed from the status of the move raws that are not picked. This includes moves wihtout demands which should not infer with the…
### Issue:
Curently, the reservation state of a production is computed from the status of the move raws that are not picked. This includes moves wihtout demands which should not infer with the reservation state at all.
### Steps to reproduce:
- In the settings, Enable "Multi-Step Routes"
- Go to Inventory > Configuration > Warehouse Management > Warehouses
- Put your warehouse in 2 steps-manufacturing
- Create a final product (FP) tracked by Serial number, and 2 storable components: COMP1 and COMP2
- Create a BOM for FP:
- Component lines:
- 1 x COMP1
- 0 x COMP2 !!
- Operations:
- OP1 with an instruction of type "register production"
1. Create an MO for 1 x FP > Confirm
2. Validate the pick transfer for 1 unit of COMP1
> Currently OP1 is marked as ready
3. Mark the component line of COMP1 as "picked"
#### > OP1 is in waiting status
Same result as 3:
3'. Go to the shopfloor > register production from the MO card
#### > This will pick the COMP1 raw move and OP1 will disappear because of the "ready" filter
### Cause of the issue:
Since you manufacture in 2 steps, the state of the raw move of COMP2 is waiting even though its demand is 0 (before and after you validated the pick move for COMP1). However, only non picked moves are considered to be relevant in the computation of the reservation state of the MO: https://github.com/odoo/odoo/blob/d8fc04f5875dbd3098e58f382d0cea3c7c7c38af/addons/mrp/models/mrp_production.py#L613-L621 Once you pick the COMP1 move which should be the only relevant one the reservation state of the MO becomes computed solely based on the state of the COMP2 raw move and becomes "waiting". In turns, this triggers a recomputation of the state of the workorders and flagging it as waiting: https://github.com/odoo/odoo/blob/d8fc04f5875dbd3098e58f382d0cea3c7c7c38af/addons/mrp/models/mrp_workorder.py#L148-L165
opw-4383004
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#196517
Forward-Port-Of: odoo/odoo#196388The payment post-processing cron is run every 10 minutes to ensure smooth operations, but waking up crons incurs a non-negligible performance cost. Since the `payment` module is automatically installed with the `account` module, most databases have the `payment` module installed with its cron, even if they didn't enable any provider. This commit disables the cron until a provider is enabled. task-4467217 Forward-Port-Of: odoo/odoo#196702 Forward-Port-Of: odoo/odoo#195482
Original PR description
The payment post-processing cron is run every 10 minutes to ensure smooth operations, but waking up crons incurs a non-negligible performance cost. Since the `payment` module is automatically installed with the `account` module, most databases have the `payment` module installed with its cron, even if they didn't enable any provider. This commit disables the cron until a provider is enabled. task-4467217 Forward-Port-Of: odoo/odoo#196702 Forward-Port-Of: odoo/odoo#195482
Since HS Code field is now also used in USPS connector, the help text of `hs_code` field on `product_template` needs to be updated. Also the POT file containing module titles and descriptions is updated. Task-3759325 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#196518 Forward-Port-Of: odoo/odoo#187405
Original PR description
Since HS Code field is now also used in USPS connector, the help text of `hs_code` field on `product_template` needs to be updated. Also the POT file containing module titles and descriptions is updated. Task-3759325 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#196518 Forward-Port-Of: odoo/odoo#187405
Description of the issue/feature this PR addresses: This PR aims to allow the user to create a CN in a different journal than the one the invoice has. Current behavior before PR: When a user tries to create a CN from a E-invoice with a manual journal, and then changes the journal on the CN wizard, the field "Document number" that is required for manual journals is still visible and required so the wizard can not be confirmed. Desired behavior after PR is merged: When the user creates a
Original PR description
Description of the issue/feature this PR addresses: This PR aims to allow the user to create a CN in a different journal than the one the invoice has. Current behavior before PR: When a user tries to create a CN from a E-invoice with a manual journal, and then changes the journal on the CN wizard, the field "Document number" that is required for manual journals is still visible and required so the wizard can not be confirmed. Desired behavior after PR is merged: When the user creates a CN and then change the journal on the CN wizard, the visibility and requirement of the fields should be adjusted as expected for the journal type selected. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#192728
The upgrade script is supposed to create xmlids for french banks that were already created from csv, if it matches custom records that have unusual bic, it is better to skip the whole record. Standard BIC format is a capital alphanumeric only. Replacing the spaces or unsupported characters in the xmlid will result in custom records looking like they come from standard module. alternate fix for https://github.com/odoo/odoo/pull/191970 --- I confirm I have signed the CLA and read the PR
Original PR description
The upgrade script is supposed to create xmlids for french banks that were already created from csv, if it matches custom records that have unusual bic, it is better to skip the whole record. Standard BIC format is a capital alphanumeric only. Replacing the spaces or unsupported characters in the xmlid will result in custom records looking like they come from standard module. alternate fix for https://github.com/odoo/odoo/pull/191970 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#195740
Behavior Before the Commit: Whenever you change the account type of a Cash and Bank account to a different type, please ensure that the Reconcile option is set to True. However, if you later switch the account type back to Cash and Bank, the Reconcile option will remain True and will not automatically revert to False. Fix: explicitly set reconcile to False for account_type 'Cash and Bank' in compute_reconcile method. Behavior After the commit: Reconcile will be changed to false o
Original PR description
Behavior Before the Commit:
Whenever you change the account type of a Cash and Bank account to a different type,
please ensure that the Reconcile option is set to True. However, if you later switch
the account type back to Cash and Bank, the Reconcile option will remain True and
will not automatically revert to False.
Fix: explicitly set reconcile to False for account_type 'Cash and Bank' in compute_reconcile
method.
Behavior After the commit:
Reconcile will be changed to false on changing the account type to Cash and Bank.
opw-4450088: https://www.odoo.com/odoo/my-support-tasks/4450088
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#194358In SEPA payment files, when a structured reference is used, it is put in the section `RmtInf/Strd/CdtrRefInf/Ref`. This section has a maximum length of 35 characters. Since we only use structured references that are always less that 35 characters, this should not be a problem. However, the way we validated the structured reference was by performing a `re.match()`, which only matches from the beginning of the string. So if more characters would be after the structured reference, it would still
Original PR description
In SEPA payment files, when a structured reference is used, it is put in the section `RmtInf/Strd/CdtrRefInf/Ref`. This section has a maximum length of 35 characters. Since we only use structured references that are always less that 35 characters, this should not be a problem. However, the way we validated the structured reference was by performing a `re.match()`, which only matches from the beginning of the string. So if more characters would be after the structured reference, it would still match and it would be possible to go beyond 35 characters. In this commit, we fix this by using a full match instead of a match from the beginning. [opw-4357554](https://www.odoo.com/odoo/project.task/4357554) Forward-Port-Of: odoo/odoo#196841 Forward-Port-Of: odoo/odoo#194583
### Steps to reproduce: - In the settings enable: Multi-Step Routes, Operations > Packages - Create a storable prodcut - Update the on hand quantity: - 10 units in package PK - Inventory > Configuration > Warehouse Management > Locations - Create 2 warehouse locations: WH/LOC1, WH/LOC2 - Go to the barcode app and proceed with the scans: 1. Scan the internal transfer picking type 2. Scan WH/STOCK as a source location 3. Scan the package name (PK) 4. Scan WH/LOC1 as
Original PR description
### Steps to reproduce: - In the settings enable: Multi-Step Routes, Operations > Packages - Create a storable prodcut - Update the on hand quantity: - 10 units in package PK - Inventory >…
### Steps to reproduce:
- In the settings enable: Multi-Step Routes, Operations > Packages
- Create a storable prodcut
- Update the on hand quantity:
- 10 units in package PK
- Inventory > Configuration > Warehouse Management > Locations
- Create 2 warehouse locations: WH/LOC1, WH/LOC2
- Go to the barcode app and proceed with the scans:
1. Scan the internal transfer picking type
2. Scan WH/STOCK as a source location
3. Scan the package name (PK)
4. Scan WH/LOC1 as destination location
- Leave the barcode app without validation
- Go to the barcode app and proceed with the scans: i -> iii, iv'. Scan WH/LOC2 as destination location
- Try to validate the picking
#### > Invalid operation: You cannot move the same package content more than once in the same transfer or split the same package into two location.
### Cause of the issue:
As both pickings were treated via the barcode app, they generated picked move lines related to the package. Both of these move lines have updated the reserved quantity of the stock.quant present in stock:
- WH/STOCK, quantity: 10, reserved_quantity: 20.
When you try to validate the second picking, you will launch an `_action_done` of its move line that will create a new quant in WH/LOC2 and update the quant in stock:
- WH/STOCK, quantity: 0, reserved_quantity: 10.
- WH/LOC2, quantity: 10, reserved_quantity: 0.
The error is raised just after since 2 quants with either a quantity or reserved quantity are found:
https://github.com/odoo/odoo/blob/6349fb0362d881672616bb4b800bd32be82f9a5f/addons/stock/models/stock_move.py#L1910-L1917
### Fix:
Since the check is made in order to check the consistency of result packages moved by the current validation the "reserved_quantity" should not matter.
opw-4456484
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#193214**Current behavior:** With a FIFO + real-time product, `ProductA`: Creating a sale order with multiple order lines for ProductA, processing the resulting delivery in 2 separate pickings via backorder (1st delivery for the 1st line, 2nd delivery for the 2nd line), then invoicing the delivered product separately result in an invoice with invoice lines which do not reflect the value of the product at delivery time. **Expected behavior:** The SVLs generated from the deliveries should info
Original PR description
**Current behavior:** With a FIFO + real-time product, `ProductA`: Creating a sale order with multiple order lines for ProductA, processing the resulting delivery in 2 separate pickings via backorder…
**Current behavior:** With a FIFO + real-time product, `ProductA`: Creating a sale order with multiple order lines for ProductA, processing the resulting delivery in 2 separate pickings via backorder (1st delivery for the 1st line, 2nd delivery for the 2nd line), then invoicing the delivered product separately result in an invoice with invoice lines which do not reflect the value of the product at delivery time. **Expected behavior:** The SVLs generated from the deliveries should inform the generated AccountMoves. **Steps to reproduce:** 1. `FIFO-prod`: FIFO and real-time valuation & costing 2. Receive 12 units of `FIFO-prod` @ $100 per 3. Create a sale order with order lines: * `FIFO-prod` `10 units` `price_unit=$100` * `FIFO-prod` `2 units` `price_unit=$100` 4. Confirm the sale order, on the delivery, only receive the first move for the 10 qty, backorder the other 2 qty 5. Receive the backorder, create an invoice- edit the invoice lines so that 5/10 of line 1 and 2/2 of line 2 are invoiced, then post/confirm 6. Edit the `standard_price` of `FIFO-prod` (e.g., $100 -> $50) 7. Create another invoice for the remaining quantity and post 8. Observe that the COGs lines on the invoice have been calculated with a different price unit than the other invoice & unit_price for the out SVLs **Cause of the issue:** When getting the price unit of a given anglo saxon invoice line, there is no check that all the collected COGS lines are linked to the sale order line which corresponds to the product and product_qty that we are attempting to value. This creates an imbalance in the qty calculation later here: https://github.com/odoo/odoo/blob/f2728b2fe13a355ecb301a3714639b8a07f418b4/addons/stock_account/models/stock_valuation_layer.py#L202-L211 when the valuation is actually performed. **Fix:** Only consider posted COGS lines for the sale order line with the product qty that is getting valued when calculating `qty_invoiced`. opw-4321363 Forward-Port-Of: odoo/odoo#196067 Forward-Port-Of: odoo/odoo#195046
Description of the issue/feature this PR addresses: This PR is to fix an issue encountered when copying information from an editor for a product for example, and pasting it on the product label. On Odoo the label was appearing fine but when the invoice was confirmed and sent, the XML file content is created with hidden characters.This produced the web service to return an error when trying to validate the electronic invoice. Current behavior before PR: Special or hidden characters appear o
Original PR description
Description of the issue/feature this PR addresses: This PR is to fix an issue encountered when copying information from an editor for a product for example, and pasting it on the product label. On…
Description of the issue/feature this PR addresses: This PR is to fix an issue encountered when copying information from an editor for a product for example, and pasting it on the product label. On Odoo the label was appearing fine but when the invoice was confirmed and sent, the XML file content is created with hidden characters.This produced the web service to return an error when trying to validate the electronic invoice. Current behavior before PR: Special or hidden characters appear on the XML file of an electronic invoice. Steps to reproduce: 1. Install Uruguay - Electronic Invoice module 2. Create EDI invoice, add special character to the description of the product you are using. Example used for testing (copy-paste it): 219179120011 3. Validate the invoice 4. Print and send it 5. Check "DscItem" field on the XML file created. Here is a one minute [video](https://drive.google.com/file/d/18JcnKCbaq7cH_NVyPol4CWXHdqZAxAdo/view) reproducing the error on runbot. Desired behavior after PR is merged: These characters are cleaned up at the xml level on cleanup_xml_node method to avoid them to appear and prevent errors when validating the XML on localizations web services. Related PR on v16 regarding the same issue in another context: https://github.com/odoo/odoo/pull/154509 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#193047
When AE localization extends the default invoice report, they replace the `<th name="th_taxes"><span>Taxes</span></th>` with `<th name="th_taxes"><span t-if="...">VAT</span><span t-else="">Taxes</span></th>`. Then when AR localization is installed, it will replace the first div with the t-if. We end up in a situation with a `<span/>` followed by a `<span t-else=""/>` which raise an error because it is expecting a `t-if`. task-no Forward-Port-Of: odoo/odoo#196765
Original PR description
When AE localization extends the default invoice report, they replace the `<th name="th_taxes"><span>Taxes</span></th>` with `<th name="th_taxes"><span t-if="...">VAT</span><span t-else="">Taxes</span></th>`. Then when AR localization is installed, it will replace the first div with the t-if. We end up in a situation with a `<span/>` followed by a `<span t-else=""/>` which raise an error because it is expecting a `t-if`. task-no Forward-Port-Of: odoo/odoo#196765
Before this commit, multiple requests were sent when the user changed options in the product configuration. Additionally, the on-hand quantity was displayed incorrectly when opening the product configuration. When opening the configuration popup, the product was initially set. However, once the configuration was mounted, the selected attributes could result in a different product variant. We call `computeProductProduct` to update the product. The issue occurred because, while the first reques
Original PR description
Before this commit, multiple requests were sent when the user changed options in the product configuration. Additionally, the on-hand quantity was displayed incorrectly when opening the product configuration. When opening the configuration popup, the product was initially set. However, once the configuration was mounted, the selected attributes could result in a different product variant. We call `computeProductProduct` to update the product. The issue occurred because, while the first request was still in progress, a second request was triggered to fetch the correct product information. Since the first request was not yet finished, the second request was ignored, causing the configuration to display an incorrect on-hand quantity for the selected product variant. opw-4385171 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#190469
Previously, opening the product info popup would fail if a product had multiple sellers with the same name but different prices and delays. opw-4472861 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#195682 Forward-Port-Of: odoo/odoo#195617
Original PR description
Previously, opening the product info popup would fail if a product had multiple sellers with the same name but different prices and delays. opw-4472861 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#195682 Forward-Port-Of: odoo/odoo#195617
HTML content is often saved as XML (i.e. through templates) and saved as such in the database. This introduces issues when elements are written under their `self-closing` format (i.e. `<a/>` or `<br/>`) as browsers will incorrectly parse these values as HTML by adding a closing tag at an arbitrary position which may modify the initial nodes configuration. This can be prevented by post-processing untrusted content before the html parsing. Check this commit community counterparts, which place t
Original PR description
HTML content is often saved as XML (i.e. through templates) and saved as such in the database. This introduces issues when elements are written under their `self-closing` format (i.e. `<a/>` or `<br/>`) as browsers will incorrectly parse these values as HTML by adding a closing tag at an arbitrary position which may modify the initial nodes configuration. This can be prevented by post-processing untrusted content before the html parsing. Check this commit community counterparts, which place the conversion responsibility in the `html_viewer` instead of the `html_upgrade_manager`. task-4547973 Forward-Port-Of: odoo/enterprise#78532
The aim of this commit is cleaning a weird indentation introduced by this commit [[1]]. no task id [1]: https://github.com/odoo/enterprise/commit/103369fb171654f4b0457d9b1629224def7465eb Forward-Port-Of: odoo/enterprise#78811
Original PR description
The aim of this commit is cleaning a weird indentation introduced by this commit [[1]]. no task id [1]: https://github.com/odoo/enterprise/commit/103369fb171654f4b0457d9b1629224def7465eb Forward-Port-Of: odoo/enterprise#78811
In odoo 18.0 the `journal_id` on `hr.payroll.structure` [became not required](https://github.com/odoo/enterprise/commit/fb59524a95b0f78112002d1e4d5ad3d6c301de7e#diff-761891fe4e3aa9cb1df74ffca5261004adaf8ac8c3df5857035953e5318be967L16-R16). And in the demo data for this module `action_payslip_done` is called, which [requires](https://github.com/odoo/enterprise/blob/4784d4a48d11c72afb05f2bc7c9062c5644bbf75/hr_payroll_account/models/hr_payslip.py#L53-L54) the payroll structure to have a journal.
Original PR description
In odoo 18.0 the `journal_id` on `hr.payroll.structure` [became not required](https://github.com/odoo/enterprise/commit/fb59524a95b0f78112002d1e4d5ad3d6c301de7e#diff-761891fe4e3aa9cb1df74ffca5261004adaf8ac8c3df5857035953e5318be967L16-R16). And in the demo data for this module `action_payslip_done` is called, which [requires](https://github.com/odoo/enterprise/blob/4784d4a48d11c72afb05f2bc7c9062c5644bbf75/hr_payroll_account/models/hr_payslip.py#L53-L54) the payroll structure to have a journal. `hr_payroll_structure_ken_employee_salary` is used as the structure for all the payslips in the demo error in runbot [build](https://runbot.odoo.com/runbot/build/73486292) Forward-Port-Of: odoo/enterprise#77365
When updating the module, the bank data is reloaded. When the account is already trusted (`allow_out_payment == True`), the write fails due to checks to prevent fraud. To fix this, we wrap the data in a `noupdate` to prevent further writes from happening. If ever the account number changes, a new record will be created instead of updating the existing one. Since this account is the default one stipulated on the official fps site, it can be trusted by default. Issue reported by upgrade team
Original PR description
When updating the module, the bank data is reloaded. When the account is already trusted (`allow_out_payment == True`), the write fails due to checks to prevent fraud. To fix this, we wrap the data in a `noupdate` to prevent further writes from happening. If ever the account number changes, a new record will be created instead of updating the existing one. Since this account is the default one stipulated on the official fps site, it can be trusted by default. Issue reported by upgrade team. Forward-Port-Of: odoo/enterprise#78760
Before this commit, In kanban view when selecting multiple documents while holding shift as modifier, it could happen that folders were selected too. This was due to the logic which was using document ids as the range value when looping on `root.records` but with the new UI where the folders are now displayed on top of the documents it was buggy. In list view, we would like to keep the same behavior as in other list views. This commit fixes those issues. Task-4532046 Forward-Port-Of: o
Original PR description
Before this commit, In kanban view when selecting multiple documents while holding shift as modifier, it could happen that folders were selected too. This was due to the logic which was using document ids as the range value when looping on `root.records` but with the new UI where the folders are now displayed on top of the documents it was buggy. In list view, we would like to keep the same behavior as in other list views. This commit fixes those issues. Task-4532046 Forward-Port-Of: odoo/enterprise#78196
### Before this commit: Clicking on a budgetary position opened the list view showing all budget lines, regardless of the selected budgetary position. ### After this commit: Now, clicking on a budgetary position will open the list view filtered to show only the budget lines associated with that specific budgetary position. ### Technical: In `doActionButton`, we use the `args` if the action type is object. so, `domain` is irrelevant in this context. **task-4195738** Forward-Port-Of:
Original PR description
### Before this commit: Clicking on a budgetary position opened the list view showing all budget lines, regardless of the selected budgetary position. ### After this commit: Now, clicking on a budgetary position will open the list view filtered to show only the budget lines associated with that specific budgetary position. ### Technical: In `doActionButton`, we use the `args` if the action type is object. so, `domain` is irrelevant in this context. **task-4195738** Forward-Port-Of: odoo/enterprise#78708 Forward-Port-Of: odoo/enterprise#73785
The override of `_action_launch_stock_rule` was passing its `previous_product_uom_qty` keyword argument as a positional parameter to the `super` call, preventing other overrides from passing it with its key name. This commit ensures that the argument is now passed correctly with its key name. It also makes the override kwargs-agnostic by packing and unpacking them with `**`, thus preventing future issues related to signature changes in the parent method. See also: - https://github.com/odo
Original PR description
The override of `_action_launch_stock_rule` was passing its `previous_product_uom_qty` keyword argument as a positional parameter to the `super` call, preventing other overrides from passing it with its key name. This commit ensures that the argument is now passed correctly with its key name. It also makes the override kwargs-agnostic by packing and unpacking them with `**`, thus preventing future issues related to signature changes in the parent method. See also: - https://github.com/odoo/enterprise/pull/77839 - https://github.com/odoo/documentation/pull/11823 Forward-Port-Of: odoo/enterprise#77839
## Description Following odoo/enterprise@c9ceba2cf5982c244fe1ad3054d1463d9eca0e8c, the set of suitable_partners used to determine which products can be associated with a ticket is based on the `commercial_partner_id` of `self`. This works well for form views, where `self` is a singleton. However, since the field `product_id` is present in the list view, which has a domain depending on `suitable_product_ids`, the computation is triggered for all tickets in the list view, making `self` not a sing
Original PR description
## Description Following odoo/enterprise@c9ceba2cf5982c244fe1ad3054d1463d9eca0e8c, the set of suitable_partners used to determine which products can be associated with a ticket is based on the…
## Description Following odoo/enterprise@c9ceba2cf5982c244fe1ad3054d1463d9eca0e8c, the set of suitable_partners used to determine which products can be associated with a ticket is based on the `commercial_partner_id` of `self`. This works well for form views, where `self` is a singleton. However, since the field `product_id` is present in the list view, which has a domain depending on `suitable_product_ids`, the computation is triggered for all tickets in the list view, making `self` not a singleton. This causes the set of suitable partners to be larger than necessary, as it becomes the collective set for *all* tickets referenced in `self`, leading to false positives where products associated with a specific partner's sales/delivery history might appear suitable for another ticket with a different partner. To address this, we split `self` by `commercial_partner`, as the set of products that could be suitable depends on the partner's sales/delivery history, not on individual tickets. ## Reference opw-4444078 Forward-Port-Of: odoo/enterprise#78765 Forward-Port-Of: odoo/enterprise#78087
**Current behavior:** When a user wants to upload its VAT return to the French Government, they receive the following error message: ``` report_line_code = report_lines_code_per_id[report_line_id] ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^ KeyError: None ``` **Expected behavior:** The user should be able to upload their VAT return without any error message. **Steps to reproduce:** 1. Create a French company, using French Accounting. (`l10n_fr_reports`, `l10n
Original PR description
**Current behavior:** When a user wants to upload its VAT return to the French Government, they receive the following error message: ``` report_line_code = report_lines_code_per_id[report_line_id]…
**Current behavior:**
When a user wants to upload its VAT return to the French Government, they receive the following error message:
```
report_line_code = report_lines_code_per_id[report_line_id]
~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^
KeyError: None
```
**Expected behavior:**
The user should be able to upload their VAT return without any error message.
**Steps to reproduce:**
1. Create a French company, using French Accounting. (`l10n_fr_reports`, `l10n_fr_account`).
2. In the Settings, activate the Analytics option "Add totals below sections".
3. Go to Tax reports > Actions > EDI TVA > Send Report
**Cause of the issue:**
When the "Add totals below sections" parameter is enabled, the system will add new total lines on the report for each group of report lines. In the case of the Standard French VAT report, a single total line is added.
The issue is that before sending the report, the values are formatted by `_get_formatted_edi_values`. Each line to format is mapped to its corresponding line ID in line [255](https://github.com/odoo/enterprise/blob/0c32410b50b0edc2bc68c3199f741756b49600a2/l10n_fr_reports/wizard/l10n_fr_send_vat_report.py#L255): `report_line_id = self.report_id._get_model_info_from_id(line['id'])[-1]` Alas, for the new total lines, the line ID and its corresponding model are both None, which leads to an error on the next line. In version 17.0, there was a check for the model of the line, which was removed in version 18.0.
**Fix:**
- Add a check on the model of the line before formatting its values, to prevent the total lines from being formatted and sent.
opw-4496692
Forward-Port-Of: odoo/enterprise#77964Before this commit, depositing money for a customer with a zero balance could result in the creation of an empty order upon refreshing the browser. This issue arose because empty orders without payments were being synchronized, leading to unintended empty orders in the system. This commit addresses the problem by ensuring that empty orders without payments are not synchronized and prevents the creation of such empty orders during the deposit process. opw-4483049 Forward-Port-Of: odoo/ente
Original PR description
Before this commit, depositing money for a customer with a zero balance could result in the creation of an empty order upon refreshing the browser. This issue arose because empty orders without payments were being synchronized, leading to unintended empty orders in the system. This commit addresses the problem by ensuring that empty orders without payments are not synchronized and prevents the creation of such empty orders during the deposit process. opw-4483049 Forward-Port-Of: odoo/enterprise#78217 Forward-Port-Of: odoo/enterprise#78085
The issue occurs because the query does not apply an offset or limit, causing the same lines to be loaded repeatedly. This results in duplicate keys on the client side. To fix this, we add a query tail and mimic the ordering of account_move_line, ensuring consistency when loading additional lines. This fix is related to an earlier patch in older versions, but due to the refactoring of the Intrastat report, it had to be implemented differently. Old Fix: https://github.com/odoo/enterprise
Original PR description
The issue occurs because the query does not apply an offset or limit, causing the same lines to be loaded repeatedly. This results in duplicate keys on the client side. To fix this, we add a query tail and mimic the ordering of account_move_line, ensuring consistency when loading additional lines. This fix is related to an earlier patch in older versions, but due to the refactoring of the Intrastat report, it had to be implemented differently. Old Fix: https://github.com/odoo/enterprise/pull/76543 Forward-Port-Of: odoo/enterprise#78628
Issue ===== The view is not inserted into the article, or the view link results in a traceback error. Steps ====== 1. Create a custom menu with its configuration using the model (Create a Menu). 2. Navigate to the custom menu action via the parent menu's route. 3. Use the actions to navigate to Knowledge > Insert view/link in article, then select an article (either existing or new). Technical ========= Due to a recent change introduced in this [commit](https://github.com/odoo/enter
Original PR description
Issue ===== The view is not inserted into the article, or the view link results in a traceback error. Steps ====== 1. Create a custom menu with its configuration using the model (Create a Menu). 2. Navigate to the custom menu action via the parent menu's route. 3. Use the actions to navigate to Knowledge > Insert view/link in article, then select an article (either existing or new). Technical ========= Due to a recent change introduced in this [commit](https://github.com/odoo/enterprise/commit/30c71b1fee8c91df5342b2b1ef5f6e888e84571d) the issue arises from the function 'this.actionService.loadAction' requiring either an actionxmlid or actWindow to process the action. Previously, only the actionxmlid was available, which caused the problem. The provided fix resolves this issue by ensuring both identifiers are correctly handled. Task-4437944 Forward-Port-Of: odoo/enterprise#76918
There might be little value in re-creating a template that a user has deleted. This can also trigger the model constraint, specially in smaller databases with only one Whatsapp account and one language installed when a standard template is deleted and a new one with the same name is created. To reproduce: - Install `whatsapp_account` - Delete the `Invoice` template - Create a Whatsapp account - Create a new template, call it `Invoice` and link to the account. - Upgrade the module T
Original PR description
There might be little value in re-creating a template that a user has deleted. This can also trigger the model constraint, specially in smaller databases with only one Whatsapp account and one language installed when a standard template is deleted and a new one with the same name is created. To reproduce: - Install `whatsapp_account` - Delete the `Invoice` template - Create a Whatsapp account - Create a new template, call it `Invoice` and link to the account. - Upgrade the module This will trigger the constraint: ``` psycopg2.errors.UniqueViolation: duplicate key value violates unique constraint "whatsapp_template_unique_name_account_template" DETAIL: Key (template_name, lang_code, wa_account_id)=(invoice, en, 1) already exists. ``` Forward-Port-Of: odoo/enterprise#78501
Steps to Reproduce: 1. Enable the Rental Transfers option in Configuration > Settings. 2. Create a rental order with one rental product and one sales product. 3. Confirm the order. 4. Validate the delivery order. Issue: - The delivered quantity is updated for the rental product but not for the sales product. Cause: - This behavior arises because the assign_picking method reuses an existing picking_id if the domain matches, updating subsequent moves' location_dest_id to match
Original PR description
Steps to Reproduce: 1. Enable the Rental Transfers option in Configuration > Settings. 2. Create a rental order with one rental product and one sales product. 3. Confirm the order. 4. Validate the delivery order. Issue: - The delivered quantity is updated for the rental product but not for the sales product. Cause: - This behavior arises because the assign_picking method reuses an existing picking_id if the domain matches, updating subsequent moves' location_dest_id to match the reused picking. Fix: - Override _compute_location_dest_id and update the location_dest_id if conditions are fulfilled. opw-4298443 Forward-Port-Of: odoo/enterprise#78729 Forward-Port-Of: odoo/enterprise#73895
This new module should replace the existing implementation for USPS integration which uses XML which is not the recommended API currently by USPS. The new integration uses USPS's latest RESTful APIs: https://developer.usps.com/apis. Task-3759325 Forward-Port-Of: odoo/enterprise#78560 Forward-Port-Of: odoo/enterprise#73906
Original PR description
This new module should replace the existing implementation for USPS integration which uses XML which is not the recommended API currently by USPS. The new integration uses USPS's latest RESTful APIs: https://developer.usps.com/apis. Task-3759325 Forward-Port-Of: odoo/enterprise#78560 Forward-Port-Of: odoo/enterprise#73906
This PR aims to prevent showing outdated error messages on an uruguayan electronic invoice that has already been amended. When a user creates a CFE invoice with invalid information (for example, the unit price of the product detailed in the invoice is equal to 0.0), the webservice returns an error that is captured on Odoo and shown as a pop-up and added as a banner on the move header. If the user resets the move to draft, corrects the error and for some reason introduces another one (like lea
Original PR description
This PR aims to prevent showing outdated error messages on an uruguayan electronic invoice that has already been amended. When a user creates a CFE invoice with invalid information (for example, the…
This PR aims to prevent showing outdated error messages on an uruguayan electronic invoice that has already been amended. When a user creates a CFE invoice with invalid information (for example, the unit price of the product detailed in the invoice is equal to 0.0), the webservice returns an error that is captured on Odoo and shown as a pop-up and added as a banner on the move header. If the user resets the move to draft, corrects the error and for some reason introduces another one (like leaving the "tax" column empty), then confirm and send the invoice again to DGI, a new pop up is raised showing a new error message accordingly but the banner of the header remains showing the same error as before (saying the product unit price is 0). This leads to confusion about what is the current error to be amended to properly send the invoice to DGI. Steps to reproduce the error: - Create an uruguayan electronic invoice on a testing enviroment. - Select a product and change its unit price to 0. - Try to send & print the invoice, creating the CFE. - An error like this will be shown:  - Go back to the move and check that a banner with the error has been added at the top.  - Reset to draft, add a valid unit price and delete the "Taxes" column value. - Confirm, Send&Print the invoice. - A new pop up like this should raise:  - Go back to the invoice and check that the banner remains as before, showing an outdated error message. Forward-Port-Of: odoo/enterprise#77710
This commit avoids calling the toggle cron function with journal_ids recordset after an online account has been unlinked. Previously, this caused an error because the record was already deleted. The journal_ids model is now retrieved from the environment instead of the potentially stale recordset. The bug was introduced by this commit [[1]]. no task id [1]: https://github.com/odoo/enterprise/commit/bc3b9136d4d62fbc1d09267f73cac7ca29f1ba3a Forward-Port-Of: odoo/enterprise#78680
Original PR description
This commit avoids calling the toggle cron function with journal_ids recordset after an online account has been unlinked. Previously, this caused an error because the record was already deleted. The journal_ids model is now retrieved from the environment instead of the potentially stale recordset. The bug was introduced by this commit [[1]]. no task id [1]: https://github.com/odoo/enterprise/commit/bc3b9136d4d62fbc1d09267f73cac7ca29f1ba3a Forward-Port-Of: odoo/enterprise#78680
During the upgrade to the "new" headless mode of Chrome (default for v128+), an issue with the tours "hr_contract_salary_tour" and "hr_contract_salary_tour_2" was detected. In a nutshell, in those tours, during the signing of the contract, the "street" field wasn't pre-filled and leaving it empty. The step-by-step filling system (e.g. the "Next" button on the left) was confused and put the date in the street field (sic). For some reason, the "old" Chrome headless mode - while encountering the
Original PR description
During the upgrade to the "new" headless mode of Chrome (default for v128+), an issue with the tours "hr_contract_salary_tour" and "hr_contract_salary_tour_2" was detected. In a nutshell, in those…
During the upgrade to the "new" headless mode of Chrome (default for v128+), an issue with the tours "hr_contract_salary_tour" and "hr_contract_salary_tour_2" was detected. In a nutshell, in those tours, during the signing of the contract, the "street" field wasn't pre-filled and leaving it empty. The step-by-step filling system (e.g. the "Next" button on the left) was confused and put the date in the street field (sic). For some reason, the "old" Chrome headless mode - while encountering the same issue - didn't complained with it... But the "new" mode (which is actually closer to the actual GUI behavior of Chrome) got stuck at those steps. This commit fixes this issue by using the `private_street` field (which contains the actual street name) instead of the `private_street2` field (which is often empty). Once done, a second issue was detected as the step filling the computation of "58/4" didn't match (even wrongly) any empty field anymore. This commit simply removes those unused steps. Forward-Port-Of: odoo/enterprise#78626 Forward-Port-Of: odoo/enterprise#78397
Users with the ability to see the button 'Report in next payslip' should be able to use it even if they don't have Payroll access rights. task-4481091 Forward-Port-Of: odoo/enterprise#77193
Original PR description
Users with the ability to see the button 'Report in next payslip' should be able to use it even if they don't have Payroll access rights. task-4481091 Forward-Port-Of: odoo/enterprise#77193
The mapping that is currently used can lead to a constraint on accout types being triggered, blocking the import procedure. This commit aims at fixing this by removing the account code range for the recievable and payable types. From now on, these will only be applied when the corresponding 'CENTRALID' matches respectively 'S' for payables and 'C' for receivable. task-4465663 Forward-Port-Of: odoo/enterprise#78700 Forward-Port-Of: odoo/enterprise#77103
Original PR description
The mapping that is currently used can lead to a constraint on accout types being triggered, blocking the import procedure. This commit aims at fixing this by removing the account code range for the recievable and payable types. From now on, these will only be applied when the corresponding 'CENTRALID' matches respectively 'S' for payables and 'C' for receivable. task-4465663 Forward-Port-Of: odoo/enterprise#78700 Forward-Port-Of: odoo/enterprise#77103
We uncomment the subtotals because there was an error about withhold subtotals dict. Now the error has been resolved related: https://github.com/odoo/enterprise/pull/76330 Forward-Port-Of: odoo/enterprise#77592
Original PR description
We uncomment the subtotals because there was an error about withhold subtotals dict. Now the error has been resolved related: https://github.com/odoo/enterprise/pull/76330 Forward-Port-Of: odoo/enterprise#77592
This PR aims to fix an error on PDF reports on UY invoices, that occurs when copy-pasting the addenda text from an editor in Odoo. It happens that sometimes the text has hidden characters inside and those are printed as ? in the pdf. Steps to reproduce: 1) Install l10n_uy_edi 2) Create or duplicate an e-invoice 3) Copy-paste the following text in the "Terms and conditions" section: Estimated Net Weight: 84.000,00 Kg Estimated Gross Weight: 84.240,00 BL Nº: HLCUPN4240969947
Original PR description
This PR aims to fix an error on PDF reports on UY invoices, that occurs when copy-pasting the addenda text from an editor in Odoo. It happens that sometimes the text has hidden characters inside and those are printed as ? in the pdf. Steps to reproduce: 1) Install l10n_uy_edi 2) Create or duplicate an e-invoice 3) Copy-paste the following text in the "Terms and conditions" section: Estimated Net Weight: 84.000,00 Kg Estimated Gross Weight: 84.240,00 BL Nº: HLCUPN4240969947 BANK DETAILS: TEST12344 4) Confirm, print and send the invoice. 5) Check the pdf is created like this:  Expected behavior after this PR: The text on the "Adenda" section of the pdf should not print hidden characters. Forward-Port-Of: odoo/enterprise#76972
Prior to this commit, undoing auto plan results in having the shifts remaining in the searchBar, and therefore still highlighted. This commit aims to reset the selection and the highlight after undo auto plan. To reproduce the bug: 1. In planning, clcik auto plan and then undo. 2. Auto planned shifts which are now in unassigned are still highlighted and the search bar contains these shifts. task: 3999600 Forward-Port-Of: odoo/enterprise#73821
Original PR description
Prior to this commit, undoing auto plan results in having the shifts remaining in the searchBar, and therefore still highlighted. This commit aims to reset the selection and the highlight after undo auto plan. To reproduce the bug: 1. In planning, clcik auto plan and then undo. 2. Auto planned shifts which are now in unassigned are still highlighted and the search bar contains these shifts. task: 3999600 Forward-Port-Of: odoo/enterprise#73821