Daily updates from Odoo
Tuesday, February 27, 2024
11 changes · saas-17.1
New functionality added to Odoo
This update adds a crucial HSN (Harmonized System Nomenclature) summary to the invoice reports for Odoo's India localization. Previously, invoices lacked this key detail, making it difficult for businesses to accurately track and report on Goods and Services Tax (GST) obligations. This change improves reporting accuracy and simplifies compliance for Odoo users in India.
Original PR description
task_id: 3196107 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#155084
Resolved issues and error corrections
This update streamlines the process of creating Sales Order Lines (SOLs) when creating them on the fly within project mapping. Previously, a form would open unnecessarily when a SOL name matched an existing product. This change eliminates the form opening, resulting in a quicker and more efficient creation process for SOLs, particularly when mapping employees to projects.
Original PR description
When creating a SOL on the fly, if the name entered matches an existing service product, selecting 'Create' should create the SOL without opening a form view modal. We do that by fetching the `default_name` from the context. However, from the Many2one field, since the name will already be present in the create vals, in will not be in the default values in the context. To fix this, this PR adds a new context key when calling `name_create` that allows us to retrieve the name from the `default_get` Enterprise: https://github.com/odoo/enterprise/pull/53833 Task-3553151 Forward-Port-Of: odoo/odoo#155191 Forward-Port-Of: odoo/odoo#142720
This pull request addresses two issues related to the knowledge editor's delete functionality. It now correctly deletes emojis and resolves the problem of invisible whitespace characters being deleted one at a time when using the delete forward command. This ensures a more reliable and user-friendly editing experience.
Original PR description
Issue 1 : ======= Delete forward on emoji dosn't work ### Steps to reproduce the issue: - Go to knowledge - Add an emoji and put the cursor on the left of the emoji and delete forward - only half of…
Issue 1 : ======= Delete forward on emoji dosn't work ### Steps to reproduce the issue: - Go to knowledge - Add an emoji and put the cursor on the left of the emoji and delete forward - only half of the emoji gets deleted ### Solution: We need to get the correct offset and correct charsize because not all of the items of the sliced string had char size equal to `1`. So we slice the string and get the offset corrosponding to the target offset and of course we need to handle the directions differently Issue 2: ====== Invisible whitespaces at the start gets deleted by one by one with delete forward. ### Steps to reproduce the issue: - Go to knowledge - Add any text - Make sure you have an empty line before it - Change the html of the added text and add some spaces at the start (this is the easiest way to reproduce it) - Go to the line before and keep deleting forward - The invisible spaces will be deleted one by one. ### Solution: When the selection is at the start of the node and it contains whitespaces, `parentState` whill have undefined node when deleting forward since we are at the first leaf. We need to keep deleting forward with the text node instead of parentElement because calling delete forward with the parent will do a 1 delete backward call from the specified offset and it will not propagate forward anymore. task-3629743 Forward-Port-Of: odoo/odoo#155378 Forward-Port-Of: odoo/odoo#150224
This update fixes a printing issue on Android devices related to the point-of-sale system. Previously, printed receipts were incorrectly removed, causing blank pages. The change ensures receipts are retained until the next print, resolving the problem and improving the user experience.
Original PR description
Prior to this commit, the receipt element was cloned and appended to the render-container for web printing, then deleted after print callback. This approach failed on Android, leading to an empty page, as the cloned element was removed before printing. This commit resolves the issue by retaining the cloned element until the next clone addition to the container, at which point existing elements are removed. opw-3755682 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#154777
This update corrects a potential issue where a translation typo fix could incorrectly reuse translations for unrelated terms. The change prevents this by checking if a similar term already exists before applying the fix, ensuring translations are accurate and avoid unintended consequences. This improves the reliability of our translation system.
Original PR description
for model_terms translated fields, for sake of typo fixing feature if a term is removed after write its translations might be reused by another close term which has totally different meaning this fix removes the typo fixing if the matched closest term exists before write 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#155476 Forward-Port-Of: odoo/odoo#154868
This update fixes an issue where event attendees who had canceled registrations were still appearing in the downloaded ticket PDFs. The change ensures that only registered and attended attendees are included, providing accurate ticket information for customers. This improves the user experience and reduces potential confusion.
Original PR description
Steps to reproduce the issue: - Install `website_event_sale` module - Create an event with a paid ticket - Go to website and register for the event for 2 persons - Go to the cart and remove one of the attendees - Proceed to checkout and confirm the order - On the checkout confirmation page, click on `Download tickets` - Open the downloaded PDF file Issue: Two tickets are displayed in the PDF file. Cause: Not filtering out the canceled attendees. Solution: Display tickets only for `Attended` and `Registred` attendees. opw-3718542 Forward-Port-Of: odoo/odoo#155125
This update enhances the web editor's ability to copy translations from multiple related records to a single record. Previously, it could only copy from one view at a time. This change allows for more efficient translation management, particularly when dealing with complex, inherited views like those used in reports.
Original PR description
Before this commit, the function `_copy_field_terms_translations` allowed to copy translations from one record to another. After this commit, it can copy from a record set to a single record. opw-3746922 opw-3724701 opw-3719157 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#155346 Forward-Port-Of: odoo/odoo#154540
This update resolves an issue where users couldn't access product catalogs correctly when viewing them through sale orders. The fix ensures the catalog requests are made within the context of the sale order's company, preventing access errors and ensuring accurate product display. This improves the user experience for multi-company operations.
Original PR description
Versions -------- - 17.0+ Steps ----- 1. Create a new company; 2. switch to it via the selector; 3. create a new product specific to the company; 4. create a sale order; 5. open the catalog via a sale order line. Issue ----- Access error Cause ----- The catalog controller loses track of the current company, so `env.company` defaults to the primary `company_id` of the user. Solution -------- Use `with_company` to update `env.company` to the order's company. opw-3690226 Forward-Port-Of: odoo/odoo#153915
This update resolves an issue where background videos wouldn't display properly in Right-to-Left languages like Persian or Arabic. The fix adjusts how video positioning is calculated to account for language direction, ensuring videos are displayed correctly across all supported languages.
Original PR description
Background videos' dimensions are adapted according to the screen size. This could lead to the video not showing in RTL languages, because the computed position was coded for LTR languages. This commit replaces the `left` and `top` CSS properties with logical properties to account for language directions. Steps to reproduce: 1. Add a Cover snippet 2. Add a video to it (use any sample videos from the selector) 3. Save > Check mobile view, video shows fine. 4. Add a Right to Left language to the website (Persian, Arabic...) 5. Switch to the RTL language > Check mobile view => video doesn't display properly. opw-3688660 Forward-Port-Of: odoo/odoo#154247
This update fixes an issue where sitemaps generated for multilingual websites were incorrectly translated into the website's secondary language. Now, sitemaps always reflect the default language of the website, ensuring consistent and accurate indexing for search engines.
Original PR description
This commit prevents the sitemap from being translated when a website is available in multiple languages. The sitemap should always be in the default language of the website. Steps to reproduce the bug: - Set up a website in English and French - Navigate to the French version of the website (/fr) - Access the sitemap (/sitemap.xml) => The sitemap appears in French but should be in English. Note: There is a cache for the sitemap. It is not regenerated if it has been generated within the last 12 hours (see `SITEMAP_CACHE_TIME`). task-3743970 Forward-Port-Of: odoo/odoo#154993
This update fixes an issue where the web editor was incorrectly carrying attributes from list (`<li>`) elements. The change ensures that only the attributes of paragraph elements are passed, resulting in more consistent and predictable behavior for the editor. This improves the overall reliability of the web editor.
Original PR description
Commit [1](https://github.com/odoo/odoo/commit/fcb3846226007c31f60aecad3a92fe643540780e) changed the behavior of `setTagName` to only carry the attributes of paragraph related elements. Ideally, this should not carry the attributes of `<li>` element only. [1]: fcb3846 task-3764154 Forward-Port-Of: odoo/odoo#155151