Thursday, April 14, 2022
24 changes · master
Enhancements to existing features
The Documents spreadsheet component has been updated to the latest version. This improves formula/reference handling, aligns underlying interface dependencies with Odoo, and prevents users from moving or editing figures when a spreadsheet is in read-only mode.
Original PR description
### Contains the following commits: https://github.com/odoo/o-spreadsheet/commit/10db754a [FIX] tokenizer: strict position at the end of reference string https://github.com/odoo/o-spreadsheet/commit/c7d36a9a [FIX] package.json: update owl version to macth Odoo's https://github.com/odoo/o-spreadsheet/commit/4c711f37 [FIX] figures: prevent user to manipulate figures in Readonly mode
HR users can now start a signature request for several employees in one action instead of processing employees one by one. This streamlines contract signature workflows and saves time when preparing documents for groups of employees.
Original PR description
This change implies changing 'hr.contract.sign.document.wizard' m2o employee_id field into m2m employee_ids field. task - 2797331
Resolved issues and error corrections
Canceled Mexican invoices will now keep their electronic invoice attachment instead of deleting it. This preserves the information needed to confirm the cancellation status with the tax authority, preventing invoices from incorrectly appearing as not found.
Original PR description
#### The issue: At the moment, when we successfully request the cancellation of an invoice in Mexico, the cfdi attachment is deleted. However, several stored computed fields depend on this…
#### The issue: At the moment, when we successfully request the cancellation of an invoice in Mexico, the cfdi attachment is deleted. However, several stored computed fields depend on this attachment, notably the Fiscal Folio uuid. Without this uuid, we can't query the invoice’s status from the SAT. As a result, the invoice’s status is ‘Not Found’ when it really should be ‘Canceled’. See this video by @vbe-odoo demonstrating the problem functionally: https://us02web.zoom.us/rec/play/7kRPfbcM1YixbiezgtHV0C9KAP6AwAmEzf05WtBJO2j3cLMpvSXznOad0qT2u0NoJsisH5ICFLfcxrNN.NjyNJHvBxfK2TNf3?continueMode=true&_x_zm_rtaid=xzBnPaTGTZiTv53zobKqqg.1646836564724.d211a63c07c388cdef9dfb832d780831&_x_zm_rhtaid=552 password: ?wgK1c$N See this explanation of where the issue occurs in the source code: https://drive.google.com/file/d/1z8GhsSk6nphmhB46C0wiDHMZjV7_QSZ8/view?usp=sharing #### The solution: In stable: Retrieve the uuid from the attachment when querying the SAT status. (https://github.com/odoo/enterprise/pull/25533) In master: Don’t delete the attachment when the invoice is successfully canceled. (this PR) #### Does it work? Yes. (See this video where I do the testing): https://drive.google.com/file/d/1IIV7_kntYaUlXF5IarE5FEJaRwTW83qq/view?usp=sharing #### Does it break any other EDIs? No. - only Colombia and Peru use the cancellation workflow - in Colombia, the attachment isn’t used to populate fields - in Peru, the only time the attachment is used is in _l10n_pe_edi_get_extra_report_values (see https://github.com/odoo/enterprise/blob/28554d66478a8d884e618e35406c1ad9ac2dd646/l10n_pe_edi/models/account_move.py#L213-L214 ) which is used to create the invoice PDF. It’s not a problem if the values are correctly populated for a cancelled invoice. See this video: https://drive.google.com/file/d/1GUoQ-4HAVf1fNRWlNNkRxYWP538Jc230/view?usp=sharing #### Related support tickets: opw-2790491 opw-2716731\
Miscellaneous changes
Steps to reproduce: • Create Record: Product Category - Costing Method: Average - Inventory Valuation: Automated - Specify a price difference account (may create new account). - Ensure Stock Interim (Received) account is reconcilable. • Create Record: Product - Product Type: Storable - Cost Price: 1.01 - Product Category: New Product Category • Create bill with this product, for a quantity of 10.5 -> The is price difference of 0.1 Issue commes from this commit 286ea6b681e9b
Original PR description
Steps to reproduce: • Create Record: Product Category - Costing Method: Average - Inventory Valuation: Automated - Specify a price difference account (may create new account). - Ensure Stock Interim (Received) account is reconcilable. • Create Record: Product - Product Type: Storable - Cost Price: 1.01 - Product Category: New Product Category • Create bill with this product, for a quantity of 10.5 -> The is price difference of 0.1 Issue commes from this commit 286ea6b681e9ba77357f91b546052449f6342f20 which doesn't round if there is a discount. With this commit we isolate the latter case in order to keep the price unit rounded if there is no discount. 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#87666
Since [1] when the blog layout was refactored between 12.0 and 13.0, a negative word spacing was introduced in the blog post snippet with the big pictures layout. This commit removes this negative word spacing. Before:  After:  [1]: https://github.com/odoo/odoo/
Original PR description
Since [1] when the blog layout was refactored between 12.0 and 13.0, a negative word spacing was introduced in the blog post snippet with the big pictures layout. This commit removes this negative word spacing. Before:  After:  [1]: https://github.com/odoo/odoo/commit/bb0cdec4594fab8c22265ed8af0c2d431a263b72 task-2822436 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#88643 Forward-Port-Of: odoo/odoo#88548
When adding an editable node to a non-editable region (which in turn is situated in an editable part of the document), the editor triggers a rollback because the new node is considered an editable root, making it unremovable. However, semantically, the new node is not an editable root, being a descendant of another node having the `contenteditable` property set to true. Logically, it also makes sense to consider these elements as removable. The rollback is currently triggered when adding a
Original PR description
When adding an editable node to a non-editable region (which in turn is situated in an editable part of the document), the editor triggers a rollback because the new node is considered an editable root, making it unremovable. However, semantically, the new node is not an editable root, being a descendant of another node having the `contenteditable` property set to true. Logically, it also makes sense to consider these elements as removable. The rollback is currently triggered when adding an editable node inside a non editable part of a snippet, for example when toggling the recaptcha legal notice on a form. A commit was cherry picked from pull request #86489, simply using the special root `oid` as a check for editable roots. opw-2723017 Forward-Port-Of: odoo/odoo#87586
Missing translation opw:2782254 Forward-Port-Of: odoo/odoo#86139
Original PR description
Missing translation opw:2782254 Forward-Port-Of: odoo/odoo#86139
With l10n_nl, create a purchase journal -> traceback opw-2801012 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#87445
Original PR description
With l10n_nl, create a purchase journal -> traceback opw-2801012 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#87445
Before this commit, updating the voice activation threshold in one tab would not affect the other tabs as the localStorage was only read when discuss was initialized. This commit fixes this issue. task-2679234 Forward-Port-Of: odoo/odoo#88099 Forward-Port-Of: odoo/odoo#88077
Original PR description
Before this commit, updating the voice activation threshold in one tab would not affect the other tabs as the localStorage was only read when discuss was initialized. This commit fixes this issue. task-2679234 Forward-Port-Of: odoo/odoo#88099 Forward-Port-Of: odoo/odoo#88077
Current behavior: When adding a "Heading" in the first 200 characters of a blog with /Heading, the short description of the blog preview would have unwanted stars (*) around the heading Steps to reproduce: - Create a blog article - In the first 200 characters of the blog use a heading (e.g. /Heading1) - Go back to the blog list, the description of the new article contains unwanted stars (*) opw-2798595 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/sub
Original PR description
Current behavior: When adding a "Heading" in the first 200 characters of a blog with /Heading, the short description of the blog preview would have unwanted stars (*) around the heading Steps to reproduce: - Create a blog article - In the first 200 characters of the blog use a heading (e.g. /Heading1) - Go back to the blog list, the description of the new article contains unwanted stars (*) opw-2798595 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88082
Fix two issues linked to payment methods and their journal link. SEPA Credit Transfer was marked as only available on EUR journals, but from what we have been told, and we have seen, it should also be made available for other currencies (CHF/SEK). So we are changing the rule used to determine if SEPA Credit Transfer is available on a journal to allow to use it on journals using CHF or SEK as a currency. There is another issue, where the filtering is done differently at the journal cr
Original PR description
Fix two issues linked to payment methods and their journal link. SEPA Credit Transfer was marked as only available on EUR journals, but from what we have been told, and we have seen, it should also…
Fix two issues linked to payment methods and their journal link. SEPA Credit Transfer was marked as only available on EUR journals, but from what we have been told, and we have seen, it should also be made available for other currencies (CHF/SEK). So we are changing the rule used to determine if SEPA Credit Transfer is available on a journal to allow to use it on journals using CHF or SEK as a currency. There is another issue, where the filtering is done differently at the journal creation and when the user add the payment method manually in the lists. The filter rules were not respected at the journal creation, which would lead to incorrect default inbound and outbound payment method list. For example, a new journal would have the company currency (let's say, USD) but still have SEPA Credit Transfer (EUR,CHF,SEK) added on it by default while it should not be available there. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#84916
Steps : Create a Time Off Type T. Create 2 Allocations : > Type : T > Start date : monday D > End date : / > Number of days : resp 4 and 1 > Employee : Admin Create 2 Time Off Requests : > Type : T > Dates : resp monday D to thursday and friday to friday. Validate both. Issue : Allocation's days taken are resp 5.0/4.0 and 0.0/1.0. Cause : We set allocation to leave before validating. To do so, we take the alloc with max allocated days. Fix : Take the alloc with max
Original PR description
Steps : Create a Time Off Type T. Create 2 Allocations : > Type : T > Start date : monday D > End date : / > Number of days : resp 4 and 1 > Employee : Admin Create 2 Time Off Requests : > Type : T > Dates : resp monday D to thursday and friday to friday. Validate both. Issue : Allocation's days taken are resp 5.0/4.0 and 0.0/1.0. Cause : We set allocation to leave before validating. To do so, we take the alloc with max allocated days. Fix : Take the alloc with max days left = allocated - taken. Recompute the allocation before validating, to check that enough days are left. opw-2812534 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#88103
Description of the issue/feature this PR addresses: Wrong computation in the polish tax report Current behavior before PR: Instead of doing the difference between output tax and input tax, the tax report was doing the sum. Desired behavior after PR is merged: This commit fixes this computation without revamping the rest of the report -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88445 Forward-Port-Of: odoo/o
Original PR description
Description of the issue/feature this PR addresses: Wrong computation in the polish tax report Current behavior before PR: Instead of doing the difference between output tax and input tax, the tax report was doing the sum. Desired behavior after PR is merged: This commit fixes this computation without revamping the rest of the report -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88445 Forward-Port-Of: odoo/odoo#87763
Adding icon module with Pakistani flag -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88218
Original PR description
Adding icon module with Pakistani flag -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88218
The Credit Limit group on the res.partner record doesn't appear until you save the record. This means you have to perform extra clicks if you want to edit this value. The goal is to show the `credit` field on the accounting tab on creation if `res.partner` is a company and Credit Limit setting is activated. task-2817650 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88525
Original PR description
The Credit Limit group on the res.partner record doesn't appear until you save the record. This means you have to perform extra clicks if you want to edit this value. The goal is to show the `credit` field on the accounting tab on creation if `res.partner` is a company and Credit Limit setting is activated. task-2817650 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88525
-- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88642 Forward-Port-Of: odoo/odoo#88509
Original PR description
-- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#88642 Forward-Port-Of: odoo/odoo#88509
Steps to reproduce: - Set a new DB without demo data - Install Ecommerce - Switch language to Arabic - Try to open website module Issue: Traceback raised. Cause: When generating random sample data for website dashboard, it will use the current local to generate dates, who in this case have a non-latin numbering system, and therefore will break when trying to parse field value. Solution: Use latin (`latn`) as numbering system. opw-2743243 Forward
Original PR description
Steps to reproduce: - Set a new DB without demo data - Install Ecommerce - Switch language to Arabic - Try to open website module Issue: Traceback raised. Cause: When generating random sample data for website dashboard, it will use the current local to generate dates, who in this case have a non-latin numbering system, and therefore will break when trying to parse field value. Solution: Use latin (`latn`) as numbering system. opw-2743243 Forward-Port-Of: odoo/odoo#86267
Adding icon module with Pakistani flag Forward-Port-Of: odoo/enterprise#26003
Original PR description
Adding icon module with Pakistani flag Forward-Port-Of: odoo/enterprise#26003
Despite the fact that the IOT box is successfully connected with the DB and a camera is configured on the quality point for the product “P1” If the user creates a MO for “P1” and tries to validate the quality check by taking a picture but at the same time the iot loses the internet connection, he will not be able to use the camera, and we will have to display a user error by calling the _onIoTActionFail function: https://github.com/odoo/enterprise/blob/c7af16674057128604444a3a558b61fab254
Original PR description
Despite the fact that the IOT box is successfully connected with the DB and a camera is configured on the quality point for the product “P1” If the user creates a MO for “P1” and tries to validate the quality check by taking a picture but at the same time the iot loses the internet connection, he will not be able to use the camera, and we will have to display a user error by calling the _onIoTActionFail function: https://github.com/odoo/enterprise/blob/c7af16674057128604444a3a558b61fab2540aed/quality_iot/static/src/js/iot_picture.js#L26-L36 but this function needs “this” in order to run correctly https://github.com/odoo/enterprise/blob/9f3afb31199593e508db50a5e5a414bcaa2d9b86/iot/static/src/js/iot.js#L581-L584 opw-2817557 https://user-images.githubusercontent.com/78867936/163194382-fb4b5ea0-c47e-44d3-b3c1-5f5f1cf7c7cb.mp4 Forward-Port-Of: odoo/enterprise#26169
Fix two issues linked to payment methods and their journal link. SEPA Credit Transfer was marked as only available on EUR journals, but from what we have been told, and we have seen, it should also be made available for other currencies (CHF/SEK). So we are changing the rule used to determine if SEPA Credit Transfer is available on a journal to allow to use it on journals using CHF or SEK as a currency. There is another issue, where the filtering is done differently at the journal cr
Original PR description
Fix two issues linked to payment methods and their journal link. SEPA Credit Transfer was marked as only available on EUR journals, but from what we have been told, and we have seen, it should also be made available for other currencies (CHF/SEK). So we are changing the rule used to determine if SEPA Credit Transfer is available on a journal to allow to use it on journals using CHF or SEK as a currency. There is another issue, where the filtering is done differently at the journal creation and when the user add the payment method manually in the lists. The filter rules were not respected at the journal creation, which would lead to incorrect default inbound and outbound payment method list. For example, a new journal would have the company currency (let's say, USD) but still have SEPA Credit Transfer (EUR,CHF,SEK) added on it by default while it should not be available there. Forward-Port-Of: odoo/enterprise#24539
With this commit, we compute the batch payment amount after computing the batch_payment_id of a related payment. Steps : - Create and post two payments - Create a batch from the 2 payments -> batch payment amount is the sum of the payments - Reset one of the payment to draft state -> batch payment amount still the same, should be half After, this commit, the batch amount is recomputed when resetting a payment to draft. opw-2780106 Forward-Port-Of: odoo/enterprise#24878
Original PR description
With this commit, we compute the batch payment amount after computing the batch_payment_id of a related payment. Steps : - Create and post two payments - Create a batch from the 2 payments -> batch payment amount is the sum of the payments - Reset one of the payment to draft state -> batch payment amount still the same, should be half After, this commit, the batch amount is recomputed when resetting a payment to draft. opw-2780106 Forward-Port-Of: odoo/enterprise#24878
Steps : Install Rental and Stock. Create a Product : > Can be rented: True > Tracking : By Unique Serial Number Create a Serial Number for this Product. Create a Rental Order with this Product. With two accounts, pickup the same SN at the same time. Issue : Rental Order Line's reserved quantity is 2. Cause : When applying a pickup, SOLine.qty_reserved += WizardLine.qty_reserved. Upon 1st pickup, SOLine.qty_reserved is updated to 1. As the lot isn't reserved yet upon 2nd pickup
Original PR description
Steps : Install Rental and Stock. Create a Product : > Can be rented: True > Tracking : By Unique Serial Number Create a Serial Number for this Product. Create a Rental Order with this Product. With two accounts, pickup the same SN at the same time. Issue : Rental Order Line's reserved quantity is 2. Cause : When applying a pickup, SOLine.qty_reserved += WizardLine.qty_reserved. Upon 1st pickup, SOLine.qty_reserved is updated to 1. As the lot isn't reserved yet upon 2nd pickup, no error is raised. So 1 (SOLine) + 1 (WizardLine) = 2 Fix : Before adding WizardLine.qty_reserved to SOLine's, deduct SOLine.pickedup_lot_ids from WizardLine's and recompute WizardLine.qty_reserved as its pickedup_lot_ids' count. opw-2794441 Forward-Port-Of: odoo/enterprise#25929 Forward-Port-Of: odoo/enterprise#25909
An error is thrown when running the tests of this module Steps to reproduce: 1. Run odoo with parameters `-i helpdesk_timesheet --test-enable --test-tag helpdesk_timesheet` 2. There is an error when running the tests Solution: Remove the option `use_helpdesk_sale_timesheet` from the `helpdesk_team` created in the test as it will try to install the module `helpdesk_sale_timesheet` which is forbidden inside tests opw-2777146 Forward-Port-Of: odoo/enterprise#26000
Original PR description
An error is thrown when running the tests of this module Steps to reproduce: 1. Run odoo with parameters `-i helpdesk_timesheet --test-enable --test-tag helpdesk_timesheet` 2. There is an error when running the tests Solution: Remove the option `use_helpdesk_sale_timesheet` from the `helpdesk_team` created in the test as it will try to install the module `helpdesk_sale_timesheet` which is forbidden inside tests opw-2777146 Forward-Port-Of: odoo/enterprise#26000
With this commit, we display the right currency sign on payment report. With Mexican accounting and MXN as main currency, make an invoice in USD and register a payment for it in MXN. !! for versions after 13, send cfdi on both invoice and payment Print the payment receipt -> the field 'Amount Paid' is displaid with the main currency sign instead of invoice currency. opw-2767853 Forward-Port-Of: odoo/enterprise#25333
Original PR description
With this commit, we display the right currency sign on payment report. With Mexican accounting and MXN as main currency, make an invoice in USD and register a payment for it in MXN. !! for versions after 13, send cfdi on both invoice and payment Print the payment receipt -> the field 'Amount Paid' is displaid with the main currency sign instead of invoice currency. opw-2767853 Forward-Port-Of: odoo/enterprise#25333