Wednesday, June 26, 2024
31 changes · saas-17.1
Miscellaneous changes
Steps: - Install l10n_fr and make sure fr company has tax id filled - Go to bank journal and set a bank account number - Go to Customer invoice journal and check `Factur-X` in the Advenced Settings tab - Create a french customer F with an email address - Open a pos session, and make an invoice forF for a product with tax, select Bank payment method and confirm - Go to invoices and select the newly created invoice -> "Error occured while creating the EDI document" Cause: The field `partner
Original PR description
Steps: - Install l10n_fr and make sure fr company has tax id filled - Go to bank journal and set a bank account number - Go to Customer invoice journal and check `Factur-X` in the Advenced Settings tab - Create a french customer F with an email address - Open a pos session, and make an invoice forF for a product with tax, select Bank payment method and confirm - Go to invoices and select the newly created invoice -> "Error occured while creating the EDI document" Cause: The field `partner_bank_id` is not set from the pos order to the invoice cbe1cf5b1044827a058a4cde5d0492a545ac6da4 added a condition specifically for swiss localisation. Fix: Movr the condition to a bridge module for swiss localisation opw-3992498 Forward-Port-Of: odoo/odoo#170762
**Steps to reproduce:** - Install Accounting, website_sale_subscription and l10n_es_edi_facturae - Switch to a Spanish company (e.g. ES Company) - Install a payment provider (e.g. Demo) - Create a 1-year recurring service product - Go to the Shop page as a public user - Add the recurring service to the cart - Process checkout without entering a VAT number - Process payment **Issue:** An Internal server error is raised while trying to generate Facturae EDI because no VAT has been ente
Original PR description
**Steps to reproduce:** - Install Accounting, website_sale_subscription and l10n_es_edi_facturae - Switch to a Spanish company (e.g. ES Company) - Install a payment provider (e.g. Demo) - Create a…
**Steps to reproduce:** - Install Accounting, website_sale_subscription and l10n_es_edi_facturae - Switch to a Spanish company (e.g. ES Company) - Install a payment provider (e.g. Demo) - Create a 1-year recurring service product - Go to the Shop page as a public user - Add the recurring service to the cart - Process checkout without entering a VAT number - Process payment **Issue:** An Internal server error is raised while trying to generate Facturae EDI because no VAT has been entered. **Cause:** After a transaction is done for a subscription, an invoice is created and sent automatically. As "l10n_es_edi_facturae" module is installed, it tries to generate the EDI document when sending the invoice, but it fails because the partner has no VAT. **Solution:** The Facturae EDI xml is not a mandatory document. It should not block any flow when not generated manually. Just ignore any UserError from the generation of Facturae EDI when the invoice has been forced-created. opw-936227 Linked enterprise PR: https://github.com/odoo/enterprise/pull/65086 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#170144
Purpose ======= Fix the display of the quiz comment line: - the trash icon is displayed under the line instead of next to it. - the comment input is too large and should be aligned with the answers inputs. Specification ============= The comment input is too large because the "form-control" class has a "width: 100%" style that overwrites the "width: 66.66666667%" one applied by the "col-8" class. The good fix would be to create a new parent for the input and apply the "col-8" class
Original PR description
Purpose ======= Fix the display of the quiz comment line: - the trash icon is displayed under the line instead of next to it. - the comment input is too large and should be aligned with the answers inputs. Specification ============= The comment input is too large because the "form-control" class has a "width: 100%" style that overwrites the "width: 66.66666667%" one applied by the "col-8" class. The good fix would be to create a new parent for the input and apply the "col-8" class to limit its width accordingly while still keeping the good row gutters and margins. However as changing the xml structure is not recommended in stable, the fix is to add the "col-8" on the current "row" parent and forcing the trash icon to be next to by using the "flex-nowrap" class. Task-3986982 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#169237
backport of: https://github.com/odoo/odoo/pull/128821/commits/733eccd37a2f303aa8a6f894625f3ae73a6a1cc3 Steps to reproduce the bug: - Create a storable product “P1” with BoM - Operation: OP1 - Component: C1, consumed in: OP1 - Navigate to Mrp > Configuration > Operations - Select OP1 and select another BoM - return to the BoM of “P1” Problem: The BoM line for component "P1" is still linked to OP1, And a traceback when attempting to duplicate the BoM. Solution: Remove t
Original PR description
backport of: https://github.com/odoo/odoo/pull/128821/commits/733eccd37a2f303aa8a6f894625f3ae73a6a1cc3
Steps to reproduce the bug:
- Create a storable product “P1” with BoM
- Operation: OP1
- Component: C1, consumed in: OP1
- Navigate to Mrp > Configuration > Operations
- Select OP1 and select another BoM
- return to the BoM of “P1”
Problem:
The BoM line for component "P1" is still linked to OP1,
And a traceback when attempting to duplicate the BoM.
Solution:
Remove the operation from the initial BOM lines
opw-3948817
Forward-Port-Of: odoo/odoo#170265
Forward-Port-Of: odoo/odoo#166884Increased delay between every request to iot_devices. Requests were performed every 10ms, now every minute. Forward-Port-Of: odoo/odoo#170557
Original PR description
Increased delay between every request to iot_devices. Requests were performed every 10ms, now every minute. Forward-Port-Of: odoo/odoo#170557
We assert a hardcoded string with the name of the base.partner_root data inside test_onchange_one2many_default(). Without mail this name is "System", with the mail module it becomes "OdooBot". Then the test works if we have mail installed Forward-Port-Of: odoo/odoo#170777
Original PR description
We assert a hardcoded string with the name of the base.partner_root data inside test_onchange_one2many_default(). Without mail this name is "System", with the mail module it becomes "OdooBot". Then the test works if we have mail installed Forward-Port-Of: odoo/odoo#170777
PURPOSE One-click unsubscribe headers are becoming required in order to avoid having marketing emails being qualified as spam. This change adds those headers in various modules: digest (backport of changes done for v17), mailing lists (mail_group module) and improve unsubscribe in mass mailing by supporting one-click unsubscribe (as current portal page is not one-click available). Modules * mass mailing * digest * mail group SUMMARY To ease the way people can unsubscribe from
Original PR description
PURPOSE One-click unsubscribe headers are becoming required in order to avoid having marketing emails being qualified as spam. This change adds those headers in various modules: digest (backport of…
PURPOSE One-click unsubscribe headers are becoming required in order to avoid having marketing emails being qualified as spam. This change adds those headers in various modules: digest (backport of changes done for v17), mailing lists (mail_group module) and improve unsubscribe in mass mailing by supporting one-click unsubscribe (as current portal page is not one-click available). Modules * mass mailing * digest * mail group SUMMARY To ease the way people can unsubscribe from a digest, we have followed the advice of RFC8058 by adding the following header to the email: * List-Unsubscribe: unsubscribe route; * List-Unsubscribe-Post: List-Unsubscribe=One-Click The unsubscribe route * must work with the POST method but not the GET. The GET version is disabled to avoid unintended unsubscrbe that could be triggered by an anti-spam accessing the URLs in the headers. Email readers are supposed to do POST requests as described in the RFC; * must unsubscribe the user without any additional steps (one click) * should contain an opaque identifier hard-to-forge to identify the list and the user (our token fulfills that goal). The goal is to avoid that someone is allowed to unregister someone else easily. * must fulfill other conditions like no cookie, no redirection, ... hence those routes return a 200 status. MISC Also fix various issues in digest, notably improve tone down computation and fix issues when computing the new timespan. Task-3741195 (Digest: Make It Quality Spam) Task-3717213 (Mail: Ensure Unsubscribe Headers) Task-3741203 (Digest: Investigate tone down / reminder) Forward-Port-Of: odoo/odoo#170694 Forward-Port-Of: odoo/odoo#153864
Linked enterprise PR: https://github.com/odoo/enterprise/pull/63589 ### Steps to reproduce: - Create a company and a branch - Create a contact and assign him to the company created - Switch to the branch and go to the Contact app - You can't see the contact created ### Cause: The rule 'res.partner company' does not allow branches to see partners from the parent company. ### Solution: Change the rule to make partners accessible to branches. This solution implies changing access ru
Original PR description
Linked enterprise PR: https://github.com/odoo/enterprise/pull/63589 ### Steps to reproduce: - Create a company and a branch - Create a contact and assign him to the company created - Switch to the branch and go to the Contact app - You can't see the contact created ### Cause: The rule 'res.partner company' does not allow branches to see partners from the parent company. ### Solution: Change the rule to make partners accessible to branches. This solution implies changing access rules defined in base to use the 'parent_of' operator. By changing it, I removed a performance improvement introduced in this commit: https://github.com/odoo/odoo/commit/c18b9f44be3d666ca1e082807a2fdfc7ef2049d2. So I needed to change performance tests counting queries to make them pass. opw-3927295 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#166965
When using a cover page with a duplex letter, it would print the content of the letter behind the cover page due to an extra blank page missing. Using Unicode characters in the address would result in black boxes. This is fixed by using the Lato font provided by the web module. Forward-Port-Of: odoo/odoo#170282 Forward-Port-Of: odoo/odoo#155752
Original PR description
When using a cover page with a duplex letter, it would print the content of the letter behind the cover page due to an extra blank page missing. Using Unicode characters in the address would result in black boxes. This is fixed by using the Lato font provided by the web module. Forward-Port-Of: odoo/odoo#170282 Forward-Port-Of: odoo/odoo#155752
Description of the Issue/Feature Addressed by This PR: This pull request addresses translation issues related to a string defined in JavaScript code. Previously, the string was incorrectly formatted, making it unlocatable for the translation files. The proposed solution ensures that Odoo can now accurately translate the string. Current Behavior Before PR: In the point of sale, when attempting to close a session with a closing difference exceeding the maximum, a popup displays two sentence
Original PR description
Description of the Issue/Feature Addressed by This PR: This pull request addresses translation issues related to a string defined in JavaScript code. Previously, the string was incorrectly formatted,…
Description of the Issue/Feature Addressed by This PR: This pull request addresses translation issues related to a string defined in JavaScript code. Previously, the string was incorrectly formatted, making it unlocatable for the translation files. The proposed solution ensures that Odoo can now accurately translate the string. Current Behavior Before PR: In the point of sale, when attempting to close a session with a closing difference exceeding the maximum, a popup displays two sentences. Unfortunately, these sentences couldn’t be translated due to an improperly formatted string in the JavaScript. The translation files were unable to identify the string. Desired Behavior After PR Is Merged: The corrected string enables Odoo to perform accurate translations. The change has been implemented following an example from another well-formed string in the code.  Now the text displayed in the pop up will be translated without problems.  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#168952 Forward-Port-Of: odoo/odoo#160303
### [FIX] calendar: public user no attachment When public user will create an appointment, the attachments attached to the related mail template will filtered out by a `_process_attachments_for_post` method (ref.1) I happens because attachment's `res_model` is not set to `mail.compose.message`. Instead it's set to `mail.template` also `create_uid` isn't set to public user, but to the user creating the template). With this commit attachments will get copied on send with corrected `res_mode
Original PR description
### [FIX] calendar: public user no attachment When public user will create an appointment, the attachments attached to the related mail template will filtered out by a `_process_attachments_for_post`…
### [FIX] calendar: public user no attachment When public user will create an appointment, the attachments attached to the related mail template will filtered out by a `_process_attachments_for_post` method (ref.1) I happens because attachment's `res_model` is not set to `mail.compose.message`. Instead it's set to `mail.template` also `create_uid` isn't set to public user, but to the user creating the template). With this commit attachments will get copied on send with corrected `res_model`. ### [Reproduce] - Install modules: appointment,website - Add an attachment A to email templates: (in Settings/Email_Templates): - "Appointment Booked" - On Website/Appointment: book an appointment (from an incognito window) - BUG: no attachments are added to the emails (Settings/ Technical/ Email/ Emails) - no .ics attachment - no A attachment (ref.1) https://github.com/odoo/odoo/blob/312b0365e26e1578c5995d55f357b8aec14e5a5b/addons/mail/models/mail_thread.py#L2207C1-L2210 opw-[3685871](https://www.odoo.com/web#id=3685871&view_type=form&model=project.task) Forward-Port-Of: odoo/odoo#160518
Steps: - Install the Project module > Create a new project - Open Project > Create task stage(s) - Delete all task stages Issue: - If all the stages are deleted then blank screen appears instead of shadow data(example data). Cause: - Incorrect active_model was passed. Fix: - Issue is been fixed by removing active_model. task-3744319 Forward-Port-Of: odoo/odoo#154682
Original PR description
Steps: - Install the Project module > Create a new project - Open Project > Create task stage(s) - Delete all task stages Issue: - If all the stages are deleted then blank screen appears instead of shadow data(example data). Cause: - Incorrect active_model was passed. Fix: - Issue is been fixed by removing active_model. task-3744319 Forward-Port-Of: odoo/odoo#154682
Steps: - Install Project - Inside project task list view, select all task - Print timesheets Issues: - Header of some tables appears double Cause: - Missing grouping container css inside table header Fix: - Proper css was added to group container inside table header task-3744319 Forward-Port-Of: odoo/odoo#154840
Original PR description
Steps: - Install Project - Inside project task list view, select all task - Print timesheets Issues: - Header of some tables appears double Cause: - Missing grouping container css inside table header Fix: - Proper css was added to group container inside table header task-3744319 Forward-Port-Of: odoo/odoo#154840
### Steps to reproduce - Install project. - Create 2 projects one with timesheets and the second without timesheets. - Open the project without time sheets. - Observe that there are timesheet filters even if the timesheets are disabled. ### Issue: Timesheet filters are available for project tasks even though the project is not using the timesheets. ### Cause: Filters were missing some conditions to enable only when timesheets are available. ### Solution: Corrected the timesheet
Original PR description
### Steps to reproduce - Install project. - Create 2 projects one with timesheets and the second without timesheets. - Open the project without time sheets. - Observe that there are timesheet filters even if the timesheets are disabled. ### Issue: Timesheet filters are available for project tasks even though the project is not using the timesheets. ### Cause: Filters were missing some conditions to enable only when timesheets are available. ### Solution: Corrected the timesheet-related filters so they are only available for the project tasks which use the timesheets. Note: When we refresh the page, filters become visible because the context is lost. task-3754591 Forward-Port-Of: odoo/odoo#170001 Forward-Port-Of: odoo/odoo#155186
Before this commit, when images are added to an Image Wall or to an Image Gallery, they remained in their original format. After this commit, images added to an Image Wall or an Image Gallery are converted to webp. Thanks to [1], the Image Gallery dataset entries related to the conversion are preserved. [1]: https://github.com/odoo/odoo/commit/e73a1a96dcf8786c01205ae0a97b10e38ab9afeb task-3666894 Forward-Port-Of: odoo/odoo#170037 Forward-Port-Of: odoo/odoo#148068
Original PR description
Before this commit, when images are added to an Image Wall or to an Image Gallery, they remained in their original format. After this commit, images added to an Image Wall or an Image Gallery are converted to webp. Thanks to [1], the Image Gallery dataset entries related to the conversion are preserved. [1]: https://github.com/odoo/odoo/commit/e73a1a96dcf8786c01205ae0a97b10e38ab9afeb task-3666894 Forward-Port-Of: odoo/odoo#170037 Forward-Port-Of: odoo/odoo#148068
This commit fixes an issue introduced by https://github.com/odoo/odoo/pull/170159. forEach is not available for mapIterator on non-chromium based browser. opw-4008053 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#170702
Original PR description
This commit fixes an issue introduced by https://github.com/odoo/odoo/pull/170159. forEach is not available for mapIterator on non-chromium based browser. opw-4008053 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#170702
## Steps to reproduce: - Install POS app - Change the warehouse to a 2-step delivery method - Create a sales order for a product and confirm - Ensure the product is reserved for the picking transfer **as** the issue doesn't exist (all transfers are successfully cancelled) if there are no products reserved - Go to POS and settle the sales order - The delivery transfer is cancelled but the picking transfer (with product reserved) is not cancelled. although all transfers should be cancelled i
Original PR description
## Steps to reproduce: - Install POS app - Change the warehouse to a 2-step delivery method - Create a sales order for a product and confirm - Ensure the product is reserved for the picking transfer **as** the issue doesn't exist (all transfers are successfully cancelled) if there are no products reserved - Go to POS and settle the sales order - The delivery transfer is cancelled but the picking transfer (with product reserved) is not cancelled. although all transfers should be cancelled if the order is fully delivered! ## Investigation: - When the product is already reserved, the picking transfer is in the **Ready/assigned** state - When updating the steps, the **Ready/assigned** state is not taken into consideration and so the picking transfer is not updated to be **cancelled** opw-3474929 Forward-Port-Of: odoo/odoo#169197 Forward-Port-Of: odoo/odoo#164753
The aim of this commit is to allow to declare a 281.50 for curaçao. context: issue spotted by odoo.com prod db Before the commit: `f2018_landwoonplaats` xml tag is empty After the commit: `f2018_landwoonplaats` xml tag is filled with the onss country code of netherlands. task-id: None Forward-Port-Of: odoo/enterprise#65503 Forward-Port-Of: odoo/enterprise#65466
Original PR description
The aim of this commit is to allow to declare a 281.50 for curaçao. context: issue spotted by odoo.com prod db Before the commit: `f2018_landwoonplaats` xml tag is empty After the commit: `f2018_landwoonplaats` xml tag is filled with the onss country code of netherlands. task-id: None Forward-Port-Of: odoo/enterprise#65503 Forward-Port-Of: odoo/enterprise#65466
Before this commit, the "Consumidor Final Anónimo" partner could be missing due to the limited partner loading mechanism. This commit ensures that the "Consumidor Final Anónimo" partner is always loaded, regardless of the partner loading limitations. opw-3988187 Forward-Port-Of: odoo/enterprise#65296
Original PR description
Before this commit, the "Consumidor Final Anónimo" partner could be missing due to the limited partner loading mechanism. This commit ensures that the "Consumidor Final Anónimo" partner is always loaded, regardless of the partner loading limitations. opw-3988187 Forward-Port-Of: odoo/enterprise#65296
Issue ---- When a rental field like (e.g. `rental_start_date`) is changed in a sales order, its lines' description is recomputed. This makes sense for rental order lines as the description depends on these fields, but it messes with non-rental orders and non-rental order lines in rental orders when the Rental app is installed, so all descriptions get overwritten. Steps ----- - Install the rental app. - Create a new Quotation Template with whose line has a description that is differen
Original PR description
Issue ---- When a rental field like (e.g. `rental_start_date`) is changed in a sales order, its lines' description is recomputed. This makes sense for rental order lines as the description depends on these fields, but it messes with non-rental orders and non-rental order lines in rental orders when the Rental app is installed, so all descriptions get overwritten. Steps ----- - Install the rental app. - Create a new Quotation Template with whose line has a description that is different from the product name. - Create a new Quotation from the template. - The description gets overwritten. You can also reproduce this with creating a new rental order, then adding non-rental products with custom description. If you change the start date / end date the custom descriptions get overwritten. opw-3987175 Forward-Port-Of: odoo/enterprise#64675
This commit fixes the access error that occured while trying to rematch gstr-2b report Behaviour before this commit: When user tries to rematch the GSTR-2b Summary, an access error will be thrown that says user has no read access to the Attachments. Steps to reproduce: - Login with a user having `Accountant` group set in access rights for Account. - Install l10n_in_reports_gstr module & Switch to IN Company - Go to Accounting / Reports / GSTR Return Periods - Create new return period.
Original PR description
This commit fixes the access error that occured while trying to rematch gstr-2b report Behaviour before this commit: When user tries to rematch the GSTR-2b Summary, an access error will be thrown that says user has no read access to the Attachments. Steps to reproduce: - Login with a user having `Accountant` group set in access rights for Account. - Install l10n_in_reports_gstr module & Switch to IN Company - Go to Accounting / Reports / GSTR Return Periods - Create new return period. - Fetch GSTR-2b Summary and try to re-match. (An access error will popup)  Behaviour after this commit: The access error is no longer visible. Re-match can be done successfully. Forward-Port-Of: odoo/enterprise#64311
**Issue:** When a transaction is done for a subscription, we force the creation and sending of an invoice. However, depending on the localization of the company, many additional processes can be performed when generating/sending an invoice, like the generation/sending of an EDI document. In these cases, we may want to distinguish these forced creations from the manual ones as the treament of the invoice could differ depending on the case. opw-3936227 Linked community PR: https://git
Original PR description
**Issue:** When a transaction is done for a subscription, we force the creation and sending of an invoice. However, depending on the localization of the company, many additional processes can be performed when generating/sending an invoice, like the generation/sending of an EDI document. In these cases, we may want to distinguish these forced creations from the manual ones as the treament of the invoice could differ depending on the case. opw-3936227 Linked community PR: https://github.com/odoo/odoo/pull/170144 Forward-Port-Of: odoo/enterprise#65086
Steps to reproduce: - Create a QC with measure on quantity (move_lines) - Create a reciept and set move_line quantity to 0 - Validate and create a backorder - No QC on the backorder Bug: when create the backorder the sml is created first on the original picking and then it's picking_id is updated measure on quantity QCs are created at this time the QCs that are on the move_line should first be moved to the backorder before deleting the pending QCs on the original picking opw-3996782
Original PR description
Steps to reproduce: - Create a QC with measure on quantity (move_lines) - Create a reciept and set move_line quantity to 0 - Validate and create a backorder - No QC on the backorder Bug: when create the backorder the sml is created first on the original picking and then it's picking_id is updated measure on quantity QCs are created at this time the QCs that are on the move_line should first be moved to the backorder before deleting the pending QCs on the original picking opw-3996782 Forward-Port-Of: odoo/enterprise#65358
This PR changes an enterprise test that failed with a community PR. Linked community PR: https://github.com/odoo/odoo/pull/166965 ### Steps to reproduce: - Create a company and a branch - Create a contact and assign him to the company created - Switch to the branch and go to the Contact app - You can't see the contact created ### Cause: A rule does not allow branches to see partners from the parent company. ### Solution: Change the rule to make partners accessible to branches. T
Original PR description
This PR changes an enterprise test that failed with a community PR. Linked community PR: https://github.com/odoo/odoo/pull/166965 ### Steps to reproduce: - Create a company and a branch - Create a contact and assign him to the company created - Switch to the branch and go to the Contact app - You can't see the contact created ### Cause: A rule does not allow branches to see partners from the parent company. ### Solution: Change the rule to make partners accessible to branches. This solution implies changing access rules defined in base to use the 'parent_of' operator. By changing it, I removed a performance improvement introduced so I needed to change performance tests counting queries to make them pass. opw-3927295 Forward-Port-Of: odoo/enterprise#63589
When creating an invoice for a sales containing a recurring product, if the user doesn't have access to PoS you will have an access errorr Steps to reproduce: ------------------- * Remove PoS right from Marc Demo * Create a recurring product * Connect as Marc Demo * Create a sale with the recurring product * Try to invoice the sale > Observation: You get an access error opw-4010753 Forward-Port-Of: odoo/enterprise#65406
Original PR description
When creating an invoice for a sales containing a recurring product, if the user doesn't have access to PoS you will have an access errorr Steps to reproduce: ------------------- * Remove PoS right from Marc Demo * Create a recurring product * Connect as Marc Demo * Create a sale with the recurring product * Try to invoice the sale > Observation: You get an access error opw-4010753 Forward-Port-Of: odoo/enterprise#65406
https://github.com/odoo/enterprise/commit/f510c4098cc4696dec3fbc7d6cd3164c6fb1d6bd prevented to close a subscription if there was no invoice. Unfortulately, sale_order.order_line.invoice_lines.move_id is not always a reliabable way to check for invoices. Sme flows could replaces all the sale.order.line and therefore the link to the invoices would be lost. In that case, for subscription orders, using the subscription_id field on the account.move.line is more reliable. We use both values t
Original PR description
https://github.com/odoo/enterprise/commit/f510c4098cc4696dec3fbc7d6cd3164c6fb1d6bd prevented to close a subscription if there was no invoice. Unfortulately, sale_order.order_line.invoice_lines.move_id is not always a reliabable way to check for invoices. Sme flows could replaces all the sale.order.line and therefore the link to the invoices would be lost. In that case, for subscription orders, using the subscription_id field on the account.move.line is more reliable. We use both values to be sure. Forward-Port-Of: odoo/enterprise#65331
Versions -------- - 17.0+ Steps ----- 1. Go to Timesheets; 2. open list or kanban or list view; 3. click the START button to start a timer; 4. set a project & task; 5. stop timer. Issue ----- A record is added but hours spent remains 00:00, regardless of how much time has passed. Cause ----- 1. No timer was created on the server, because the `_setProjectTask` function that's responsible for it isn't being called when selecting a project or task. 2. From `_setProjectTask`, t
Original PR description
Versions -------- - 17.0+ Steps ----- 1. Go to Timesheets; 2. open list or kanban or list view; 3. click the START button to start a timer; 4. set a project & task; 5. stop timer. Issue ----- A…
Versions -------- - 17.0+ Steps ----- 1. Go to Timesheets; 2. open list or kanban or list view; 3. click the START button to start a timer; 4. set a project & task; 5. stop timer. Issue ----- A record is added but hours spent remains 00:00, regardless of how much time has passed. Cause ----- 1. No timer was created on the server, because the `_setProjectTask` function that's responsible for it isn't being called when selecting a project or task. 2. From `_setProjectTask`, the `onWillUpdateProps` hook wasn't getting triggered, because it's calling `load()` on `propsList` instead of `propsList.model`. 3. In `onWillUpdateProps`, the value of `timesheet.resId` wasn't getting updated because `resId` has a getter returning `config.resId`, but no setter modifying `config`. Solution -------- 1. Add a `onRecordChanged` hook. 2. Replace `propsList.load()` with `propsList.model.load()`. 3. Modify state tracking to supplant the need for changing `resId`. opw-3735463 Forward-Port-Of: odoo/enterprise#62630
**Current behavior:** A picking with a move for a product with kit BOM that also has some product packaging can be un-openable in Barcode. **Expected behavior:** Any picking should be able to be processed in Barcode. **Steps to reproduce:** *Enable product packagings* 1. Create a storable product with a kit BOM and a product packaging 2. Make some picking that has a move for the new product, confirm it so the moves for the kit components are created 3. Add stock move lines for
Original PR description
**Current behavior:** A picking with a move for a product with kit BOM that also has some product packaging can be un-openable in Barcode. **Expected behavior:** Any picking should be able to be…
**Current behavior:** A picking with a move for a product with kit BOM that also has some product packaging can be un-openable in Barcode. **Expected behavior:** Any picking should be able to be processed in Barcode. **Steps to reproduce:** *Enable product packagings* 1. Create a storable product with a kit BOM and a product packaging 2. Make some picking that has a move for the new product, confirm it so the moves for the kit components are created 3. Add stock move lines for each of the moves, fill out their `qty_done` field with the required amount 4. Save the picking record, go into Barcode 5. Try to open the picking -> trace back **Cause of the issue:** The Barcode client tries to read the package record of the BOM product/product template but it was never fetched into the barcode cache. **Fix:** Ensure any packaging record that could have an attempted access is fetched by the barcode client `onWillStart()`. opw-3895426 Forward-Port-Of: odoo/enterprise#65179 Forward-Port-Of: odoo/enterprise#64024
Steps: - Install the project - Enable Budget management from settings - Create project - Click on set status button inside your project - Create budget Issue: - If budget is not used for expenditure then instead of showing 0% , it displays -0% which is incorrect. Cause: - float value of 'cost' i.e. 0.0 leads to generation of negative value Fix: - Issue is been fixed by applying condition if cost equals 0.0 task-3744319 Forward-Port-Of: odoo/enterprise#65376 Forward-Port-Of
Original PR description
Steps: - Install the project - Enable Budget management from settings - Create project - Click on set status button inside your project - Create budget Issue: - If budget is not used for expenditure then instead of showing 0% , it displays -0% which is incorrect. Cause: - float value of 'cost' i.e. 0.0 leads to generation of negative value Fix: - Issue is been fixed by applying condition if cost equals 0.0 task-3744319 Forward-Port-Of: odoo/enterprise#65376 Forward-Port-Of: odoo/enterprise#56998
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to
Original PR description
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a…
### Steps to reproduce: - Enable multi-step routes in the settings - Inventory > Configuration > Warehouse Management > Operations types - Click on Manufacturing and put "Always" on create a backorder - Create a product P (no need for a bom) - Create and confirm a manufacturing order for 2 units of the product - Go to the barcode module > operations > manufacturing > the MO - Register only one unit of P and produce #### > A backorder is automatically created but you are redirected to the backend. Note: If you were in "ask" on create backorder or if your product had a bom and you did not register the quantities of consumed components, a pop up would appear and resolving the pop up would redirect you to the kanban view of mrp.production in the barcode module. ### Cause of the issue: The `validate` method called by clicking will execute the action if the orm call returns one and adds an 'onClose' call to its options: https://github.com/odoo/enterprise/blob/661fd61c0f50d4bf80484227c92a3fd0b9a05c68/stock_barcode/static/src/models/barcode_model.js#L475-L482 https://github.com/odoo/enterprise/blob/661fd61c0f50d4bf80484227c92a3fd0b9a05c68/stock_barcode/static/src/models/barcode_model.js#L487-L492 If the action is a popup, the onClose method will be called once the pop up is resolved. However, if the action redirects you directly to the form view of the mrp.propduction the onClose method will not be triggered and you will not be redirected to the kanban view. ### Fix: As pop ups are the only actions that we really want to trigger during the validate call we exclude actions from the base models (stock.picking and mrp.production) to avoid any redirection to the backend. #### Follow up of commit 6915741 ## opw-3890886 Forward-Port-Of: odoo/enterprise#64850
## Changes in the pos_preparation_display/models/preparation_display_order.py: The previous code used to have low selectivity in the initial recordset returned by the search function. Then the records were filtered on their state inside the for loop which increased the number of get requests to view the order stages. This approach caused a bottleneck in the following situation: - All the records are in the done stage and will be processed to filter them out, but not viewed which takes a l
Original PR description
## Changes in the pos_preparation_display/models/preparation_display_order.py: The previous code used to have low selectivity in the initial recordset returned by the search function. Then the…
## Changes in the pos_preparation_display/models/preparation_display_order.py: The previous code used to have low selectivity in the initial recordset returned by the search function. Then the records were filtered on their state inside the for loop which increased the number of get requests to view the order stages. This approach caused a bottleneck in the following situation: - All the records are in the done stage and will be processed to filter them out, but not viewed which takes a lot of resources and no result in the end. - Some of the records are in the done stage, This would add an overhead to the processing of the function with irrelevant records to filter out the done orders. Solution: - Reduce the recordset being returned in the first place from the search function by adding filters to return only the ones in progress by running an `_read_group` function that returns the orders that do not have a completed stage in the current preparation display. This recordset is then added to the new orders that still do not have stages and are in the current preparation display as well. ## Changes in the pos_preparation_display/models/preparation_display.py: The previous code would process all the records to be in the done state even though they could be already done. This approach causes an issue in the following situation: - All the records are archived, but pressing on archive all again, processes all the records again with no benefit added. Solution: - Same as above, reduce the recordset to return the orders still in progress only. Also note that the reset was limited for 1000 records only and with the previous setup, pressing archive multiple times would result in the same processing over the same 1000 records, Which is why the limit was removed ## Benckmark | | Before| After| Orders done | Number of records |Speed up |---|----|-----|------|---------|--------- Time | 15 s | 12 s | No | 170k |1.25x Time | 6 s | 302 ms | yes| 170k |19x This speed up is because all of the records are archived and put in the done state thus not selected by the _read_group function in the first place. Under different circumstances the speed up would differ on the ratio between done and not done orders. But under the assumption that the number of orders on the display order at a single time, the speed up is considerable. ## Reference opw-3865664 Forward-Port-Of: odoo/enterprise#64669 Forward-Port-Of: odoo/enterprise#62996