Monday, February 22, 2021
23 changes · master
Enhancements to existing features
Payroll administrators can now choose colors for work entry types directly in the form and list views. This makes entries easier to visually distinguish when configuring or reviewing payroll-related work entries.
Original PR description
Task - 2452036
This update streamlines how Odoo manages automatic record tracking fields and relational field updates. It reduces unnecessary database work during saves, which can improve performance and make system behavior more predictable without changing user workflows.
Original PR description
This proposes * a refactoring that simplifies the hacks dealing with `_log_access` fields, also known as "magic" fields; * a refactoring that reduces calls to `flush()` when updating x2many fields.
This change lets Odoo calculate certain fields directly in the database, making them faster and easier to use in grouped reports. It is especially useful for values that change over time and should not be permanently stored, improving reporting flexibility without adding storage overhead.
Original PR description
Comparision with regular computed fields: 1. it work faster 2. allows read_group without making field storable --- task-1915411 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
A new email template is added specifically for sending and printing credit notes, instead of reusing the invoice template. This makes customer communications clearer and easier for accounting teams to manage.
Original PR description
There is only a single mail template for invoices at the moment. To make things easier to work with, this will add a new template for credit notes. Task id #2343331 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Resolved issues and error corrections
The Belgian EDI process now checks that the related PDF still exists before trying to include it in the XML file. This prevents invoice printing from failing in cases where the attachment was removed or is no longer available.
Original PR description
Before this commit, on some cases the attachment of the Belgian EDI might not exist any longer when printing the pdf, which caused a crash when trying to embed it into the xml. 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
Miscellaneous changes
PURPOSE Hide cover images from the sample data of tasks kanban cards, as the pictures are quite random and don't do the view justice SPEC Do not return many2one value for cover image field(do not return value if relation of field is ir.attachment) TASK 2368505 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66350
Original PR description
PURPOSE Hide cover images from the sample data of tasks kanban cards, as the pictures are quite random and don't do the view justice SPEC Do not return many2one value for cover image field(do not return value if relation of field is ir.attachment) TASK 2368505 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66350
This change fixes an internal automated test that could fail unpredictably depending on network timing. It makes the test wait for the required error dialog component to load, improving development reliability without changing user-facing behavior.
Original PR description
Since commit 2716828f25c5837fff7a90a1cbb9c957b056e853, the error dialog has an additional JS lib dependency, which means that it may needs to perform a request before it opens up. However, a test in the crashmanager was only waiting for a next tick, which is possibly too short for a network request. So, depending on the network speed (and on the test order), this test could fail. To fix it, we simply make sure that the test also wait for the library to be loaded Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This field shouldn't be visible on the view for 'base' repartition lines. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66541
Original PR description
This field shouldn't be visible on the view for 'base' repartition lines. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66541
-- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66543
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#66543
Currently we always auto-reserve products for moves when other incoming picking makes the product available. This is unwanted for some users. In this commit, we allow to disable this by add a parameter to ir.config_parameter. To disable it, name the parameter "stock.picking_no_auto_reserve" 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
Original PR description
Currently we always auto-reserve products for moves when other incoming picking makes the product available. This is unwanted for some users. In this commit, we allow to disable this by add a parameter to ir.config_parameter. To disable it, name the parameter "stock.picking_no_auto_reserve" 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#66373
Open POS, add something to the order, go to checkout, add payment, double click on validate js error will popup opw-2429523 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#66046
Original PR description
Open POS, add something to the order, go to checkout, add payment, double click on validate js error will popup opw-2429523 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#66046
PURPOSE When there is only one page in the notebook tag and there is a boolean field in the form to show/hide that notebook page based on invisibility attrs, if we toggle boolean field notebook hides, that's OK but when we toggle boolean field again then notebook page is displayed but it is not active and due to that content of notebook page is not displayed. SPEC When there is only one page in the notebook and it has attrs for invisibility, when we toggle boolean field to hide/show noteboo
Original PR description
PURPOSE When there is only one page in the notebook tag and there is a boolean field in the form to show/hide that notebook page based on invisibility attrs, if we toggle boolean field notebook hides, that's OK but when we toggle boolean field again then notebook page is displayed but it is not active and due to that content of notebook page is not displayed. SPEC When there is only one page in the notebook and it has attrs for invisibility, when we toggle boolean field to hide/show notebook page then notebook page, as well as content, is toggled. TASK 2449053 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#66241 Forward-Port-Of: odoo/odoo#65318
Let's assume the following scenario: - have an action in target new (e.g. a form view) - in the dialog, have an action/object button with confirm attribute - when clicking on that button, a confirm dialog opens - if validated, the following action returned by the server is again an action in target new Before this commit, the confirm dialog remained in the DOM. This issue occurred because it's parent wasn't correctly set (wrong use of `this`), so when the first dialog was
Original PR description
Let's assume the following scenario: - have an action in target new (e.g. a form view) - in the dialog, have an action/object button with confirm attribute - when clicking on that button, a confirm dialog opens - if validated, the following action returned by the server is again an action in target new Before this commit, the confirm dialog remained in the DOM. This issue occurred because it's parent wasn't correctly set (wrong use of `this`), so when the first dialog was destroyed, the confirm dialog wasn't automatically destroyed in turn. OPW~2440712 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#66345 Forward-Port-Of: odoo/odoo#66326
Before this commit, in some cases the attachment of the Belgian EDI might not exist any longer when printing the pdf, which caused a crash when trying to embed it into the xml. 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#66588
Original PR description
Before this commit, in some cases the attachment of the Belgian EDI might not exist any longer when printing the pdf, which caused a crash when trying to embed it into the xml. 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#66588
Go to the website Drag a "Tabs" block on the page, by default you will have 3 example tabs Click on the tab "Contact" and drag in the block "Image Gallery" Add multiple images to the image gallery Click on one of the other tabs so that the image gallery is hidden Save The image gallery do not have the thumbails anymore This occur because when the carousel-indicator is hidden, jquery is not able to fetch its real length, so no icons are added https://github.com/odoo/odoo/blob/768bcf58e
Original PR description
Go to the website Drag a "Tabs" block on the page, by default you will have 3 example tabs Click on the tab "Contact" and drag in the block "Image Gallery" Add multiple images to the image gallery…
Go to the website Drag a "Tabs" block on the page, by default you will have 3 example tabs Click on the tab "Contact" and drag in the block "Image Gallery" Add multiple images to the image gallery Click on one of the other tabs so that the image gallery is hidden Save The image gallery do not have the thumbails anymore This occur because when the carousel-indicator is hidden, jquery is not able to fetch its real length, so no icons are added https://github.com/odoo/odoo/blob/768bcf58e8dc215b96b11bafa632c07dc683e297/addons/website/static/src/snippets/s_image_gallery/000.js#L99 A solution is to give the object a fictional length (i.e. the number of elements of the list do just fine for the use case) Other solution require more involved hack on the elements https://stackoverflow.com/questions/1472303/jquery-get-width-of-element-when-not-visible-display-none opw-2438513 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#66197
Steps: - Install sales,payment - Go to Sales - Create a quotation - Click Actions > Generate a Payment Link - Browse the link in a private window - Pay Bug: The transaction is not linked to the sale order in the link table `sale_order_transaction_rel` Explanation: When not connected, the user doesn't have the rights to read the order. This leads `order_id` to be set to `None`: https://github.com/odoo/odoo/blob/d2f3c9e7975188753fa17c06db3fc5c73c773944/addons/payment/controllers/p
Original PR description
Steps: - Install sales,payment - Go to Sales - Create a quotation - Click Actions > Generate a Payment Link - Browse the link in a private window - Pay Bug: The transaction is not linked to the sale…
Steps: - Install sales,payment - Go to Sales - Create a quotation - Click Actions > Generate a Payment Link - Browse the link in a private window - Pay Bug: The transaction is not linked to the sale order in the link table `sale_order_transaction_rel` Explanation: When not connected, the user doesn't have the rights to read the order. This leads `order_id` to be set to `None`: https://github.com/odoo/odoo/blob/d2f3c9e7975188753fa17c06db3fc5c73c773944/addons/payment/controllers/portal.py#L177-L178 When paying without `order_id`, the app is not able to make a link with the transactions: https://github.com/odoo/odoo/blob/d2f3c9e7975188753fa17c06db3fc5c73c773944/addons/payment/controllers/portal.py#L276-L277 This raises problems such as not being able to capture an amount as seen here: https://github.com/odoo/odoo/blob/d2f3c9e7975188753fa17c06db3fc5c73c773944/addons/sale/views/sale_views.xml#L254-L257 If we ensure a `partner_id` is present, using `sudo` here shouldn't be a problem as the data is protected by the token. Everything we get from `order_id` should already be in the URL. opw:2451564 Forward-Port-Of: odoo/odoo#66565
Before this commit, 'hours' was on the next row instead of the same line. 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#66615
Original PR description
Before this commit, 'hours' was on the next row instead of the same line. 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#66615
…rect "followup_line_id" In follow-up reports with no negative follow-up levels, in certain circumstances you can have a partner with 0$ overdue and still appearing as "In need of action". This can lead to a partner receiving multiple mails while the actually have no overdue invoices. Before some move lines can get a "followup_line_id" beside the fact that they are not overdue because the parameter "aml.date" is taken into account. The parameter "aml.date" should only be compared if the
Original PR description
…rect "followup_line_id" In follow-up reports with no negative follow-up levels, in certain circumstances you can have a partner with 0$ overdue and still appearing as "In need of action". This can lead to a partner receiving multiple mails while the actually have no overdue invoices. Before some move lines can get a "followup_line_id" beside the fact that they are not overdue because the parameter "aml.date" is taken into account. The parameter "aml.date" should only be compared if there is no "aml.date_maturity" when we check if the invoice is overdue. opw-2370615 Forward-Port-Of: odoo/enterprise#16531
Show a meaningful error message instead of traceback. TaskID: 2465141 Forward-Port-Of: odoo/enterprise#16563
Original PR description
Show a meaningful error message instead of traceback. TaskID: 2465141 Forward-Port-Of: odoo/enterprise#16563
Forward-Port-Of: odoo/enterprise#16546 Forward-Port-Of: odoo/enterprise#16539
Original PR description
Forward-Port-Of: odoo/enterprise#16546 Forward-Port-Of: odoo/enterprise#16539
On iPad Safari, when using list view, Odoo have trouble to register clicks from external mouse/trackpad. And when using my fingers to operate, I cannot bulk edit fields on the list view (e.g. change salesperson, add tags) because taping on the column will result in check/uncheck of the record instead of editing the field. This commit fixes the condition to enable the "mobile-friendly" behavior on list views. Note: by removing entirely the "touch" part of the condition, we assume that
Original PR description
On iPad Safari, when using list view, Odoo have trouble to register clicks from external mouse/trackpad. And when using my fingers to operate, I cannot bulk edit fields on the list view (e.g. change salesperson, add tags) because taping on the column will result in check/uncheck of the record instead of editing the field. This commit fixes the condition to enable the "mobile-friendly" behavior on list views. Note: by removing entirely the "touch" part of the condition, we assume that mobile-like devices (aka smartphone-like screen size) are also touch-enabled. It matches the rest of the codebase and was probably a bit too restrictive in the first place... Task ID: 2446829 Forward-Port-Of: odoo/enterprise#16486
This is done so that accountants from fiduciaries can properly submit the reports from their customers directly on intervat. The files got refused when trying to do that, because they didn't contain the Representative node. Forward-Port-Of: odoo/enterprise#16542 Forward-Port-Of: odoo/enterprise#16501
Original PR description
This is done so that accountants from fiduciaries can properly submit the reports from their customers directly on intervat. The files got refused when trying to do that, because they didn't contain the Representative node. Forward-Port-Of: odoo/enterprise#16542 Forward-Port-Of: odoo/enterprise#16501
Go to Accounting>Reporting>Certificado de Retención en ICA Click 'Print Preview', the report is not correct, it should output the "Certificado de Retención" This reverts commit 0d198d3529b593bd9c94bba38f1a9afa6ee1ae1f adding the correct fix to not break the certificates opw-2446354 Forward-Port-Of: odoo/enterprise#16429
Original PR description
Go to Accounting>Reporting>Certificado de Retención en ICA Click 'Print Preview', the report is not correct, it should output the "Certificado de Retención" This reverts commit 0d198d3529b593bd9c94bba38f1a9afa6ee1ae1f adding the correct fix to not break the certificates opw-2446354 Forward-Port-Of: odoo/enterprise#16429