Tuesday, October 10, 2023
96 changes · master
New functionality added to Odoo
This proposed change lets Odoo download updated language translations from an online source instead of relying only on files bundled with the software. It could make translations available sooner, reduce installation size, and allow updates without waiting for a full code release, though the PR is still experimental and raises deployment and security questions.
Original PR description
_This is a PoC to test the feasibility of such approach, nothing decided yet, creating a PR to make it easier to discuss_ Fetch the latest translations from an external provider (e.g. nightly/CDN…
_This is a PoC to test the feasibility of such approach, nothing decided yet, creating a PR to make it easier to discuss_ Fetch the latest translations from an external provider (e.g. nightly/CDN server) instead of relying on local files. This would allow to: - fetch translations more regularly than once per week - be able to update translations without having to wait for the source code to be updated - reduce the size of the repository/install files by removing .po files from this repository Questions: - how to manage SaaS installations (you do no want the action on one db to impact the files used by another) \--> solution used, two extraction methods : save to fs or save to ir.attachment - how to manage no longer supported versions and nightly server (we won't serve v14 translation files in 2042)? - triple check security related stuff as executing files downloaded This PR uses odoo/odoo#38859 as base (still to merge). Misc: - adds a `i18n_server` module to create packs, serve translations (cf retirement problem above) and test the download - copied all translations to https://github.com/odoo-dev/i18n for a demo github translation server - published test packs at https://odoo-dev.github.io/i18n to have a functional runbot Todo/Problems to solve: - we use the .pot files as reference, this is no longer working (as the files are no longer loaded from fs), this is why a test is still failing (fr_BE.po is outdated while the .pot is right) - use a `last_fetch_date` to avoid multiple refresh when not needed
Odoo now includes New Zealand English as a selectable language. This helps New Zealand users get locale settings that better match their region instead of relying on United States English defaults.
Original PR description
To avoid using the default en_US (which has different locale settings)
Adds a new Uruguay localization module with local accounting setup, tax mapping, fiscal positions, legal document types, and contact identification rules. This helps businesses operating in Uruguay configure Odoo more quickly and comply with local invoicing and accounting requirements.
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Enhancements to existing features
Resolved issues and error corrections
Fixes a problem that made a button-group switch on the online shop unusable after a supporting component was removed. Customers and site visitors can now use this shop interface control as expected, reducing friction during browsing or purchasing.
Original PR description
In commit f24e61334ec1de577c6031743199e3b713290d2f the legacy rpc files have been removed. It was not initialized in this public widget making the btn-group switch unusable. task-3547424 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Features or functions removed from Odoo
This change removes a little-used duplicate text escaping function and makes the standard escaping behavior more complete. It helps keep web and mail-related code simpler while maintaining safer handling of quotes in displayed values.
Original PR description
In https://github.com/odoo/odoo/commit/a6fea376bb2e75f2ca617811f41d83768c078f85, escapeHTML was introduced to replace the corresponding
underscore.js function. It is very similar to the widely used escape
function, except it additionally escapes single (') and double (")
quotes.
The additional escaping is not generally harmful, and is necessary to
safely inject values into attributes. As escapeHTML is almost unused,
remove it and update escape to include quotes.
taskId : 3522892Code cleanup and technical improvements
This update modernizes how drag-and-drop sorting works so it can be reused in more parts of Odoo, including website and editor screens. It reduces reliance on older components and should make sortable interactions easier to maintain and more consistent for users.
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
## Issue Reading on the field `tasks_ids` of the `sale.order` model in some context can be slow, leading to really slow creation and duplication of tasks on a medium sized database. ## Analysis After creation of a task, when the ORM flushes the model, it recomputes all the inverse dependencies that needs to be recomputed. Currently `task_ids` doesn't implement a `search` routine on the field, so `task_ids` needs to be recomputed for *all* sales orders, since we don't know which sales order
Original PR description
## Issue Reading on the field `tasks_ids` of the `sale.order` model in some context can be slow, leading to really slow creation and duplication of tasks on a medium sized database. ## Analysis After…
## Issue
Reading on the field `tasks_ids` of the `sale.order` model in some context can be slow, leading to really slow creation and duplication of tasks on a medium sized database.
## Analysis
After creation of a task, when the ORM flushes the model, it recomputes all the inverse dependencies that needs to be recomputed.
Currently `task_ids` doesn't implement a `search` routine on the field, so `task_ids` needs to be recomputed for *all* sales orders, since we don't know which sales order needs computation. So for *all* sales orders, we trigger the compute `_compute_tasks_ids`, which is badly implemented using the general performance anti-pattern
```py
for record in records:
field = self.env['model'].search(domain)
```
which makes 1 query per record that we are computing.
## Solution
Correct the implementation of `_compute_tasks_ids`, which now uses a `_read_group` instead so we do 1 query for the whole recordset. And implement the `search` on the non-stored `tasks_ids` field, which speeds up the context of re-computations. This allows the ORM to know for which sales order the field `task_ids` needs re-computation.
## Results
In the context a mid-size database (less than 10k records for the concerned models)
Task creation/duplication:
| | Before | After |
|-------------|--------|-------|
| Time | 1 min | 1 sec |
| Query count | 40k | 300 |
## Reference
opw-3445565
Forward-Port-Of: odoo/odoo#137542
Forward-Port-Of: odoo/odoo#136255This update simplifies how Odoo views refer to the current record, replacing misleading internal references with clearer ones across many modules. Existing screens should continue to work, but customizations using the older references will now receive warnings ahead of their planned removal in a future version.
Original PR description
This commit aims to simplify the evaluation context used to evaluate expressions used in views (invisible, required, readonly, domain and context attributes). For now, the evaluation context is…
This commit aims to simplify the evaluation context used to
evaluate expressions used in views (invisible, required, readonly,
domain and context attributes). For now, the evaluation context is
typically the current record (there's a key for each field in the
view). In addition to that, there're static keys (that may conflict
with field names): uid, allowed_company_ids, current_company_id,
active_id, active_ids and active_model.
The motivation of this commit is at some point to get rid of the
3 active_* keys, because they are misleading and basically useless.
The notion of active_* exists, but it is something else: when you
are in a form view (let's say the form of a partner) and you open
its opportunities (by clicking on the stat button), the list view
of opportunities shows up and in the context, there're 3 keys
active_* , referring to the record from which we came. One can
easily access those information with context.get("active_*"), in
python or in view archs.
However, almost all `active_id` found in archs were actually used
to refer to the id of the current record. Indeed, for now, in the
evaluation context of a record, the value of the `active_id` key is
always the id of the record. So this commit adapts them to
directly use `id` instead. There was no use of active_ids, and
a single use of active_model which was removed (active_model is
the res_model of the view, so it isn't really necessary).
This commit doesn't drop the support of those keys, it deprecates
them. They will be removed for v18. A warning will be displayed if
they are used.The Mail app now includes additional information needed to better support VoIP calling features. This prepares the communication experience for smoother phone integration across related Odoo apps.
Original PR description
Adds useful fields to models needed for VoIP to work. Enterprise: https://github.com/odoo/enterprise/pull/38339 Upgrade: https://github.com/odoo/upgrade/pull/5021
Mobile self-order can now be enabled without restaurant mode, with sensible pickup and per-order payment defaults. Customers also get clearer, less disruptive messages when self-order is closed or no products are available, reducing crashes and confusion.
Original PR description
Previously, mobile self-order was not available when restaurant mode was deactivated. Now it's possible to activate self-order mode without the restaurant option activated. Self-order will then be forced to "pickup zone" mode and pay after "each order". --- Previously, when the self-order was closed, a popup indicating this appeared in full screen. Now, this popup has been replaced by a banner at the top of the screen, so that the self-order can still be used in read-only mode. --- Previously, when the kiosk was loaded and there was no product available in the pos_config, a traceback was raised. Now, when we are in this case, we display a message indicating to first add products in full screen. --- Fixed a traceback when trying to start the POS by clicking on the image of the landing page. The function start() had been removed. It is now restored.
Forum moderators can now more easily view and filter non-deleted posts by status, including flagged, closed, and pending items. This helps moderators find posts needing attention and reopen posts through filters when appropriate, while reserving permanent archiving controls for internal users.
Original PR description
This commit improves filters in forum so that moderator can see all non-deleted posts on main page, use filters to move to flagged, closed or pending post lists, and reopen them through filters if need arises. task-3349373 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Customer lists now make it easier to view and organize electronic invoicing details, including EDI format and PEPPOL information. Users can also check PEPPOL endpoint details for selected customers directly from the list, helping teams manage customer e-invoicing setup more efficiently.
Original PR description
Problem --------- Currently, the tree view for customers does not include information about the EDI format. Only a custom `group_by format` is present which is not user friendly. Objective --------- As we have more and more EDI format following each type of customer, we should add an easy way to manage that directly in the customer list. Solution --------- 1. Extend the `res_partner` search view to add a group_by option on the format. 2. Extend the `res_partner` tree view to add an optional hidden column on the format, and one for the PEPPOL eas, endpoint and endpoint validity. 3. Create a server action that executes `button_account_peppol_check_partner_endpoint` on the selected records in the list view. task-3531419 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Removes outdated support code from the mail module's test helpers because the newer interface environment now covers that need. This is an internal cleanup that reduces maintenance overhead without changing day-to-day user behavior.
Original PR description
As the comment says: > This function must be removed when the WOWL env will be available in > the form_renderer. This code seems not needed anymore. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Shared portal links can now display a short preview with useful context, so recipients can understand what the link is about before opening it. This improves the sharing experience for project and task portal pages and makes links more informative in conversations.
Original PR description
Before this PR, when the user shares a portal link, the receiver has to click on the link to understand what it is about. This PR uses new key called `preview_object` inside `portal.frontend_layout` template. When it is defined, it will add some useful information for the preview link. This commit also defines `preview_object` in portal view of project and task to be able to have the preview link to prevent the user from having to click on the link to understand what it is about. task-3186692 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
Polish localization now includes JPK reporting and delivery date fields by default, making key compliance information available to all Polish users. This prepares the localization for upcoming e-invoicing needs and removes the need for separate add-on modules for these capabilities.
Original PR description
Merge l10n_pl_jpk as it is a functionality that every user that uses l10n_pl should have. Especially, since the fields will be necessary for the e-invoicing. Also merge l10n_pl_delivery_date and delivery_date on account_move. This means the module l10n_pl_sale_stock is not necessary anymore. Linked with Enterprise: https://github.com/odoo/enterprise/pull/47445 Upgrade: https://github.com/odoo/upgrade/pull/5152 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
Portal pages now use the same conversation panel as the main Odoo backend, giving external users a more consistent experience. This also brings features such as link previews and message reactions to portal interactions, while replacing older portal-specific components.
Original PR description
By this commit: - Portal chatter widget is deleted - The chatter in portal is the backend Chatter component (from mail module) now - Some features in chatter like link preview and reactions are new in portal environment (number of queries in some tests are increased because of reactions feature on messages) - Except two use cases of portal composer (as a popup composer) all the other use cases of composer in portal, are replaced by composer component in mail module - The project sharing doesn't use the previous chatter component in the sharing webclient view. It's replaced by backend chatter component as well Task-2828744 [Related enterprise PR](https://github.com/odoo/enterprise/pull/47447)
Odoo now loads messaging data only when a user action or feature actually needs it, instead of during service startup. This reduces unnecessary initialization and avoids conflicts in live chat scenarios where messaging data is not required before sending a message.
Original PR description
By this commit 'mail.messaging' service is not initialized at the start of the service. So whenever we need the data from `init_messaging`, we initialize it there. Before this commit, we had to override the initialize function if we didn't need the data from init_messaging, like in livechat module before sending a new message. As a result, any other possible usage of initializing data in messaging service, would be broken in a same assets bundle. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Odoo now uses clearer, shorter, and more approachable error and warning messages across several business apps. This helps users better understand what went wrong and reduces frustration during everyday workflows, while some unnecessary warnings were removed.
Original PR description
Before this PR error messages in odoo are boring and not much attractive to user. Those were like odoo is preventing them from doing something user want to do. In this PR, we have modified the message to be a more friendly and humorous tone, making it less tedious and more enjoyable. It aims to enhance the user experience and ensure that interactions with any application are both pleasant and informative. As a result, the messages have been clear, short, easy to understand and informative. task-3356114
Warehouse users can now search stock transfers using the lot or serial number recorded on stock move lines. This makes it easier to locate related pickings when tracing products, investigating issues, or handling barcode-driven workflows.
Original PR description
Give the ability to filter pickings base on lot/serial number set on stock move lines. 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
The self-ordering point of sale interface has been redesigned to work better on both mobile devices and large kiosk or TV screens. Demo product and loyalty visuals were also refreshed, making demonstrations and testing more polished and realistic.
Original PR description
Following the merge of mobile and kiosk functionalities [1], this commit adapt and improve the UI in order to fit both mobile devices and TV screens. [1] https://github.com/odoo/odoo/pull/136051 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Email sending now identifies cases where the sender address is missing or invalid, making delivery failures easier to understand and resolve. This improves reporting for regular mail and mass mailing, helping teams diagnose email issues faster.
The ecommerce checkout has been redesigned to make buying online clearer and easier for customers. The update improves cart navigation, page layout, checkout steps, and fixes a shop page button issue so the purchasing flow works more reliably.
Original PR description
See also: - https://github.com/odoo/enterprise/pull/46252
Spreadsheet users can now edit the criteria used by Odoo charts, aligning charts with the existing behavior for lists and pivots. Charts reload correctly when those criteria change, so reports reflect updated business filters without needing manual workarounds.
Original PR description
## Task Description: This PR aims to add the possibility to edit the evaluation domain of an Odoo chart, the same way it can currently be done for other datasources like `List` or `Pivot`. This revision ensures that the chart datasources are properly reloaded their domain update. Task: 3384872 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Spreadsheet users can now change the order of global filters with drag and drop, making filter organization more flexible and easier to manage. The underlying filter handling was also cleaned up to avoid duplicate filter identifiers and reduce inconsistent behavior.
Original PR description
## [IMP] spreadsheet: allow to reorder global filters This commit allows to reorder global filters via drag and drop. The fact that global filters have a concept of order means taht the structure of…
## [IMP] spreadsheet: allow to reorder global filters This commit allows to reorder global filters via drag and drop. The fact that global filters have a concept of order means taht the structure of the global filters in the core plugin need to change from an Object<string, GlobalFilter> to an Array<GlobalFilter>. ## [REF] spreadsheet_edition: de-duplicate filter id in cmds The commands `ADD_GLOBAL_FILTER` and `EDIT_GLOBAL_FILTER` had the filter id once in cmd.id, and once in cmd.filter.id. This made it possible to send a command with 2 different ids, which can have arbitrary behaviour depending on the implementation details of the command. Changed it so we only use cmd.filter.id, and removed the cmd.id field. Also simplified the commands helpers for the tests. Task: [3502684](https://www.odoo.com/web#id=3502684&menu_id=4720&cids=1&action=333&active_id=2328&model=project.task&view_type=form) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Spreadsheet users can now drag and drop global filters to arrange them in the order that best fits their workflow. This makes filter management clearer and more flexible, while also simplifying the underlying filter handling to avoid inconsistent filter identifiers.
Original PR description
## [IMP] spreadsheet: allow to reorder global filters This commit allows to reorder global filters via drag and drop. The fact that global filters have a concept of order means taht the structure of the global filters in the core plugin need to change from an Object<string, GlobalFilter> to an Array<GlobalFilter>. ## [REF] spreadsheet_edition: de-duplicate filter id in cmds The commands `ADD_GLOBAL_FILTER` and `EDIT_GLOBAL_FILTER` had the filter id once in cmd.id, and once in cmd.filter.id. This made it possible to send a command with 2 different ids, which can have arbitrary behaviour depending on the implementation details of the command. Changed it so we only use cmd.filter.id, and removed the cmd.id field. Also simplified the commands helpers for the tests. Task: [3502684](https://www.odoo.com/web#id=3502684&menu_id=4720&cids=1&action=333&active_id=2328&model=project.task&view_type=form)
Users can now adjust the data source behind Odoo charts directly from the spreadsheet chart side panel, including the business model and filtering criteria. This makes chart setup and maintenance easier, aligning chart editing with the existing experience for pivot tables and lists.
Original PR description
Task Description: This PR aims to add a side panel to edit the Odoo Chart data source, as the model and the domain, in the same way as it was done for the pivot and the list, making these informations available/editable from the Odoo chart side panel. - Task: 3384872 - https://github.com/odoo/odoo/pull/135242
The ecommerce checkout flow has been redesigned to make cart review, navigation, and checkout steps clearer for shoppers. The update improves spacing, table readability, and step-by-step guidance, including related rental, subscription, stock, and localization checkout screens.
Original PR description
See also: - https://github.com/odoo/odoo/pull/133064
Automatic transfer entries are now created only when there are actual lines for the selected period. This prevents empty accounting entries from being generated, reducing cleanup work and keeping records clearer.
Original PR description
before this commit, if there is no lines in the period the move is created with empty lines after this commit, move is created only when the lines exists in the period.
The POS order tracking display now has clearer layouts, adjusted colors, and better text sizing for readability on different screens. Ready orders are highlighted with a success color, helping customers quickly see when their order is available.
Original PR description
In this commit, I've made UI improvements to the user interface of the recently introduced POS order tracking display module, which serves as a display for customers to monitor the state of their orders on a screen. Key enhancements includes: - Layout small changes - Color adjustments - Font-size management to ensure readability across different displays - Success color indicator for "ready" orders to provide a better visual feedback to the customer <table> <tr> <td>Before</td> <td> After</td> <tr> <td> <img width="1726" alt="Capture d’écran 2023-08-29 à 09 05 01" src="https://github.com/odoo/enterprise/assets/80678921/051a5cac-a3bf-4cb7-b131-2a926873990b"> </td> <td><img width="1726" alt="Capture d’écran 2023-08-29 à 09 05 07" src="https://github.com/odoo/enterprise/assets/80678921/593ab0f9-0788-47ef-b818-b9eb9839cb94"> </td> </table> task-3522343
This update removes unused styling rules from the Accounting reports interface to reduce the size of the generated CSS. The change should help pages load a bit more efficiently without changing visible functionality for users.
Original PR description
`@extend` should be used with care : they are a powerful tool, but can lead to nasty overgeneration of SCSS selectors. Also these rules doesn't look to be used anyway 🤷 Example (uncompressed): - fresh database with only account_accountant (and its dependencies) installed: CSS bundle goes from 1923KB to 1702KB (gain 221KB) - runbot all: CSS bundle goes from 2664KB to 2388KB (gain 276KB) task-3546717
Warehouse users can now scan a lot or serial number directly from Barcode app menus to find related inventory and filter relevant transfers. This makes it faster to locate products tied to a specific lot and improves day-to-day stock handling accuracy.
Portal pages now use the same conversation panel experience as the backend, making messages and activity tracking more consistent for users. This reduces differences between internal and portal workflows across several business apps, helping teams collaborate with external users more smoothly.
Original PR description
Task-2828744 [Related odoo PR](https://github.com/odoo/odoo/pull/135599)
Subscription invoices can now be consolidated when generated by the automated subscription process. This reduces invoice clutter and makes recurring billing easier to manage for customers and accounting teams.
Original PR description
Allow invoices to be consolidated in the subscription cron. task-id: 3210623
Error messages have been rewritten to feel clearer, shorter, and more approachable for users. This improves the experience when users encounter restrictions or issues by making guidance easier to understand and less frustrating.
Original PR description
Before this PR error messages in odoo are boring and not much attractive to user. Those were like odoo is preventing them from doing something user want to do. In this PR, we have modified the message to be a more friendly and humorous tone, making it less tedious and more enjoyable. It aims to enhance the user experience and ensure that interactions with any application are both pleasant and informative. As a result, the messages have been clear, short, easy to understand and informative. task-3356114
The Polish reports module now includes the JPK tax reporting capabilities that were previously kept in a separate module. This simplifies setup and maintenance for Polish reporting while also updating delivery date handling in related reports.
Original PR description
Merge both modules. Also, change l10n_pl_delivery_date changes for delivery_date Linked with Odoo https://github.com/odoo/odoo/pull/135595
Shared Helpdesk portal links now include preview information so recipients can understand what the link is about before opening it. This makes shared support links clearer and reduces unnecessary clicks for customers and team members.
Original PR description
Before this PR, when the user shares a helpdesk link, the receiver has to click on the link to understand what it is about. This PR uses new key called `preview_object` inside `portal.frontend_layout` template. When it is defined, it will add some useful information for the preview link. This PR also defines `preview_object` in portal view of project and task to be able to have the preview link to prevent the user from having to click on the link to understand what it is about. task- 3186692
An unused field was removed from the Planning analysis report model after it was no longer shown or used in the interface. This keeps the reporting code cleaner without changing what users see or how they work.
Original PR description
Field overlap_slot_count of model planning.analysis.report was previously removed from the view where it was used by https://github.com/odoo/enterprise/pull/42117. The field has now no more use and should be removed from the model.
Report file exports no longer stop at the first missing or incorrectly calculated field. Users now see a wizard listing all detected issues and can still choose to generate the report, helping them complete exports while remaining informed about potential inaccuracies.
Original PR description
The file export generation blocks with user errors when some fields are not filled or wrongly computed. We want to avoid such blocking behavior, and allow the user to still generate the report, even if it's wrong. The errors that occurred are still notified to the user in a new wizard that allows him/her to generate the report anyway. This wizard also provides a list of all the errors that occurred during the generation process, instead of blocking at the first one. task-3375333
Documents now preserves selected folders, categories, and filters in the page URL. Users can reload the page or share a link and return directly to the same document workspace view, making collaboration and navigation easier.
Original PR description
Documents views will now keep the state of the searchpanel inside the url, each category and filters will thus stay after a reload. As such it is now possible to share a link that directly links to a specific folder, filter combination in documents. TaskId-3128953
Duplicated appraisal plans now automatically include "(copy)" at the end of their name. This makes it easier for users to tell original plans apart from copies and manage appraisal planning without confusion.
Original PR description
This commit introduces a feature that automatically appends "(copy)" to the end of the plan name whenever it is duplicated. This change enhances clarity and separates the original plan from its duplicates, simplifying management and tracking. task:3544642
This update adjusts several Odoo Enterprise screens so they no longer rely on outdated context fields. It helps keep these modules compatible with platform changes and reduces the risk of future view-related issues.
Original PR description
This commit is the counterpart of https://github.com/odoo/odoo/pull/136665 where keys active_id, active_ids and active_model have been deprecated from the evaluation context. This commit thus adapts archs to stop using them.
The self-ordering app now shows the correct price when customers choose take away instead of eat in. This prevents pricing confusion at checkout and helps restaurants apply the right fiscal pricing automatically.
Original PR description
Steps to reproduce: - Activate "Eat in / Take away" (`pos_self_ordering_takeaway`) setting. - Set the alternative fiscal position. - ISSUE: When selecting take away in the app, the take away price is not shown. FIX: The issue is because during the loading of the products, only the default price is computed. In this PR, we are now computing the take away price as well. And in the ui, depending on the choice, we are showing the correct price.
This fixes an issue where pages with a search panel would automatically jump back to the top. Users now get consistent scrolling behavior whether or not a search panel is shown, making navigation less disruptive.
Original PR description
Before this commit, if a view contained a searchPanel the scrollbar went at the top automatically; now the behavior of the scrollbar in a view with or without a searchPanel is the same. task : 3503894 with help of @Arcasias --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update adjusts how mentions are styled in Mail so they no longer unintentionally alter button styling elsewhere on the website. It also slightly improves mention readability by refining text and background contrast in light and dark themes.
Original PR description
Follow-up of https://github.com/odoo/odoo/pull/132701 `@extend` was used to reuse classnames intended for styling, such as `.btn`. However, this has the side-effect to increase specificity on these…
Follow-up of https://github.com/odoo/odoo/pull/132701 `@extend` was used to reuse classnames intended for styling, such as `.btn`. However, this has the side-effect to increase specificity on these classnames, which results in breaking style on the website where the specificity on `.btn` must not change. This commit fixes the issue by using a mixin rather than `@extend`. Since using these mixins are not equivalent, we took the opportunity to slightly improve the constrast of text color and background. Before/After (white)   Before/After (dark)  
This fixes an issue where the command menu could fail to open correctly while editing a mailing. The editor now keeps using the correct embedded document after updates, making mailing content editing more reliable.
Original PR description
Steps to reproduce: - Create new mailing (mass_mailing) - Type to '/' to open the Powerbox The `getPowerboxElement` function fails to return the correct node because `this.options.document` is no longer the iframe document after the Wysiwyg component is re-rendered. This happens because when the Wysiwyg component has its props updated, its `options.document` is overwritten by its default option (the top document). This commit makes sure that, when the editor is mounted inside an iframe, `options.document` evaluates to the iframe's document throughout the entirety of the Wysiwyg component lifecycle. task-3548120
This fixes a duplicated barcode test that was causing some nightly validation builds to fail. The change helps keep automated checks stable so releases and module updates are not delayed by a false test issue.
Original PR description
Task: 3290154 The nightly was failing during some single module build (website_sale, account, ...) https://runbot.odoo.com/web#id=25090&view_type=form&model=runbot.build.error&menu_id=405&cids=1 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fixes several issues in Odoo Studio so editing views no longer affects the user context used elsewhere, reducing unexpected behavior when loading views. It also prevents unnecessary browser-close warnings in the form editor and fixes crashes when viewing field tooltips in the list editor.
The restaurant appointment floor screen now shows appointment names consistently, regardless of whether the appointment was created online or in the back office. This avoids confusing or incorrect labels for staff managing restaurant bookings.
Original PR description
Previously, an operation was done to retrieve the appointment name. This operation was needed because when the appointment was created in the front end, a prefix was added to it. The issue is that this prefix was not added when the appointment was created in the back end. The solution to remove the prefix from the appointment name will be done by the team that is responsible of the Event module.
This change reorganizes the drag-and-drop building blocks so they no longer depend on one specific front-end framework. It makes the same behavior easier to use in more areas of Odoo, including places where that framework is not available, with little expected visible change for users.
Original PR description
This commit removes Owl hooks from the draggable hook builder file and introduces a new parameter attribute (`setupHooks`) to specify which functions must be used to set up, update and tear down the draggable hook. This has been done to allow the draggable hook builder function to be used in environments where Owl is not available. Enterprise: https://github.com/odoo/enterprise/pull/47693 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update removes an outdated internal bridge that was only still routing a small set of legacy service calls. It simplifies the web foundation and related modules without introducing expected changes for end users.
Original PR description
This service was used to redirect legacy service requests to the wowl service infrastructure. It has been incrementally simplified with the codebase getting converted. It now only allows to redirect calls to the effect service, which doesn't seem useful anymore. This commit thus removes it. Part of task~3439226 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 change simplifies how Odoo loads assets used in website and mass mailing preview features. It supports ongoing cleanup of the asset system while preserving the mobile preview experience for users.
Original PR description
In this commit, we remove three usages of the getBundle function from @web/core/assets.js. The final goal is to remove it totally to simplify the understanding of assets's API. To replace the use of getBundle in mobile preview dialog, an xml template has been created on the server side and then called by http requests. During the request, we retrieve the list of assets (server side getbundle) to inject these into the xml template. taskId : 3266441
This change removes leftover styling for a date picker library that is no longer used. It keeps the codebase cleaner and reduces the chance of obsolete frontend customizations affecting future maintenance.
Original PR description
The tempusdominus library has been removed by [1]. This commit removes scss customizations of the library that have been forgotten. [1] 910897fc97d87b08f01627094ec8c159f5267628 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 change removes dark mode styling that was only needed for an old date picker library. Since that library is no longer used, removing the extra styling keeps the web interface code cleaner without changing business workflows.
Original PR description
The tempusdominus library has been removed by [1]. This commit removes the dark mode override for the tempusdominus picker. [1] odoo/odoo@910897fc97d87b08f01627094ec8c159f5267628
The Gantt view’s drag-and-drop helper has been reorganized so it no longer depends directly on a specific interface framework. This keeps the scheduling experience unchanged for users while making the feature easier to maintain and align with related platform updates.
Original PR description
This commit is the follow-up of its community counterpart with the same name. It adds the Owl setup hooks as default hooks of the Gantt draggable helper hooks. Community: https://github.com/odoo/odoo/pull/136116
An unused background service related to opening the home menu has been removed because the older code path that depended on it no longer exists. This simplifies the enterprise web client internals with no expected change for end users.
Original PR description
This service is no longer useful as there's no legacy code triggering events to open the home menu anymore. Part of task~3439226
This update reworks internal drag-and-drop behavior so it can be reused in more parts of the system, including areas that do not rely on the same interface framework. It helps keep web tools such as the home menu, Gantt views, and Studio editing more flexible and easier to maintain without changing core business workflows.
The VoIP module has been rebuilt on newer Odoo technology to reduce accumulated technical debt and make future enhancements easier. This mainly updates the internal structure and user interface foundations without introducing a specific new business feature.
Original PR description
The code of the VoIP module is getting quite old and has accumulated a lot of technical debt over the years, making it very difficult if not impossible to add new features and fix some bugs. An upgrade of the code to our current coding standards is required prior to any further improvements. This commit rewrites the code to use the newest APIs. In particular, it rewrites all the javascript code in a more declarative fashion, using Owl components and services instead of the old widgets. Task-2376357. Community: https://github.com/odoo/odoo/pull/115689 Upgrade: https://github.com/odoo/upgrade/pull/5021
This SIRET is valid according to `stdnum` but does not correspond to any existing company. Forward-Port-Of: odoo/odoo#137971
Original PR description
This SIRET is valid according to `stdnum` but does not correspond to any existing company. Forward-Port-Of: odoo/odoo#137971
CLA signature update for trungtuan88 Forward-Port-Of: odoo/odoo#137951
Original PR description
CLA signature update for trungtuan88 Forward-Port-Of: odoo/odoo#137951
CLA signature update for PallaviSrivastavaa Forward-Port-Of: odoo/odoo#137959
Original PR description
CLA signature update for PallaviSrivastavaa Forward-Port-Of: odoo/odoo#137959
This traceback arises when the user changes the `end_date` without the `employee` value, while creating a new `Work Entry`. To reproduce this issue: 1) Install `hr_work_entry_contract` 2) Open `payroll` and create a new `Work Entry` 3) Select `Work Entry Type` as `Unpaid` and change the `To` date Error:- ``` KeyError: False File "odoo/http.py", line 2134, in __call__ response = request._serve_db() File "odoo/http.py", line 1710, in _serve_db return service_model
Original PR description
This traceback arises when the user changes the `end_date` without the `employee` value, while creating a new `Work Entry`. To reproduce this issue: 1) Install `hr_work_entry_contract` 2) Open…
This traceback arises when the user changes the `end_date` without the `employee` value,
while creating a new `Work Entry`.
To reproduce this issue:
1) Install `hr_work_entry_contract`
2) Open `payroll` and create a new `Work Entry`
3) Select `Work Entry Type` as `Unpaid` and change the `To` date
Error:-
```
KeyError: False
File "odoo/http.py", line 2134, in __call__
response = request._serve_db()
File "odoo/http.py", line 1710, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "odoo/service/model.py", line 133, in retrying
result = func()
File "odoo/http.py", line 1737, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 1938, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 191, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 717, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 30, in call_kw
return self._call_kw(model, method, args, kwargs)
File "addons/web/controllers/dataset.py", line 26, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 461, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "odoo/api.py", line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "odoo/models.py", line 6781, in onchange
todo = [
File "odoo/models.py", line 6784, in <listcomp>
if name not in done and snapshot0.has_changed(name)
File "odoo/models.py", line 6584, in has_changed
return self[name] != record[name]
File "odoo/models.py", line 6211, in __getitem__
return self._fields[key].__get__(self, type(self))
File "odoo/fields.py", line 1157, in __get__
self.recompute(record)
File "odoo/fields.py", line 1367, in recompute
apply_except_missing(self.compute_value, recs)
File "odoo/fields.py", line 1340, in apply_except_missing
func(records)
File "odoo/fields.py", line 1389, in compute_value
records._compute_field_value(self)
File "odoo/models.py", line 4553, in _compute_field_value
fields.determine(field.compute, self)
File "odoo/fields.py", line 101, in determine
return needle(*args)
File "addons/hr_work_entry/models/hr_work_entry.py", line 84, in _compute_duration
durations = self._get_duration_batch()
File "home/odoo/src/enterprise/saas-16.4/hr_work_entry_contract_planning/models/hr_work_entry.py", line 46, in _get_duration_batch
res.update(super(HrWorkEntry, super_we)._get_duration_batch())
File "addons/hr_work_entry_contract/models/hr_work_entry.py", line 119, in _get_duration_batch
result[work_entry.id] = mapped_contract_data[(date_start, date_stop)][calendar][employee.id]['hours']
```
On the `_get_duration_batch` method when the user is not given employee value,
there will be no `contract_id` as it is getting value from `employee_id`.
It leads to the above traceback as `result[work_entry.id]` is getting value through `employee.id`.
See:- https://github.com/odoo/odoo/blob/a277faa2ffab7559fcbad95fcc1e8fd6a26d756b/addons/hr_work_entry_contract/models/hr_work_entry.py#L110-L112
Will resolve this issue by calculating duration without employee
sentry-4514970596
Forward-Port-Of: odoo/odoo#137699This commit removes the organizer's name in the mail template when booking an appointment scheduled based on resources. Task-3458881 Forward-Port-Of: odoo/odoo#133288
Original PR description
This commit removes the organizer's name in the mail template when booking an appointment scheduled based on resources. Task-3458881 Forward-Port-Of: odoo/odoo#133288
Install auth_oauth and via the /web/login, click the "Log in using Odoo.com" button. You are redirected on odoo.com which ask you for your odoo.com login and password. When the login form on odoo.com is submited, you are redirected back on your local database. The problem is that, in case a new account was created on-the-fly, then the login fails with a cryptic error. The actual error is that `request.env.user._is_internal` fails because `user` is an empty recordset where it should had been t
Original PR description
Install auth_oauth and via the /web/login, click the "Log in using Odoo.com" button. You are redirected on odoo.com which ask you for your odoo.com login and password. When the login form on odoo.com…
Install auth_oauth and via the /web/login, click the "Log in using Odoo.com" button. You are redirected on odoo.com which ask you for your odoo.com login and password. When the login form on odoo.com is submited, you are redirected back on your local database. The problem is that, in case a new account was created on-the-fly, then the login fails with a cryptic error. The actual error is that `request.env.user._is_internal` fails because `user` is an empty recordset where it should had been the just-authenticated user. The problem is an inconsistent transaction state between the cursor of the request, the cursor used with `auth_oauth` (which created a new user) and the cursor used with `authenticate` (which authenticated the new user). Yes, there are 3 cursors. The newly created user just isn't present in the transaction of the request's cursor. Here is the lifetime of the 3 cursors: * request.env.cr, it begins when the http request enters Odoo, it is commited when a http response exits Odoo. * /auth_oauth/signin, it begins roughly at the beginning of the controller, it is commited once after the user is created (so before the authenticate transaction begins but AFTER the request transaction begun), it is commited again when the controller exits. * authenticate, begins when authenticate is called, is commited when it returns. Because the request transaction started before, it cannot access user created by /auth_oauth/signin. Because the route is `auth='none'`, if system administrators append the `auth_oauth` module via `--load` (cli) or `server_wide_modules` (odoorc) then the controller can be accessed without database. This is the reason for the explicit registry/cursor/environment inside this controller, we needed to make sure we are connected to a database, we cannot rely on request. The new approach used in this work is to benefit from `ensure_db()`, the function that is used by various web `auth='none'` controllers such as /web and /web/login. It makes sure that the database we want to connect to is already present on the request, otherwise it repeats the request but this time connecting it to the database. Using this approach we can have a `auth='none'` controller whose request.env is guaranteed to be connected on the right database. We can avoid to create explicit new registry/cursor/environment within the controller and just use request's ones. Because the /auth_oauth/signin controller now simply use the request transaction, the above point: > Because the request transaction started before, it cannot access user > created by /auth_oauth/signin. just doesn't stand anymore as the user is created within the same transaction. The extra `cr.commit()` must still be present for `authenticate` to see the newly created user. opw-3421701 Forward-Port-Of: odoo/odoo#137579
**Steps:** - Open Helpdesk - Enable the 'forum' feature on a helpdesk team - Open the help webpage - Search for something - Traceback appears **Issue:** - When we search for something, we get a traceback instead of search results. **Cause:** - In the template, we do not get the value of create_uid.id as we are trying to compute it from post_id. **Fix:** - Instead of computing the value from post_id, we need to compute it from post hence we will obtain the values by writing post.
Original PR description
**Steps:** - Open Helpdesk - Enable the 'forum' feature on a helpdesk team - Open the help webpage - Search for something - Traceback appears **Issue:** - When we search for something, we get a traceback instead of search results. **Cause:** - In the template, we do not get the value of create_uid.id as we are trying to compute it from post_id. **Fix:** - Instead of computing the value from post_id, we need to compute it from post hence we will obtain the values by writing post.create_uid.id **Task:** 3461563 Forward-Port-Of: odoo/odoo#132821
When we have all `crm.stage` records set to "fold in pipeline", the compute method for stage_id returns None. This means that when we create a lead in the form view and the stage is unset, we get a TypeError traceback as we are trying to access a property of null. This commit aims to fix this behavior so that it reflects the behavior of the kanban view. If the stage is not set, the lead will be created in the "None" stage. opw-3512966 Forward-Port-Of: odoo/odoo#137389 Forward-Port-Of: odo
Original PR description
When we have all `crm.stage` records set to "fold in pipeline", the compute method for stage_id returns None. This means that when we create a lead in the form view and the stage is unset, we get a TypeError traceback as we are trying to access a property of null. This commit aims to fix this behavior so that it reflects the behavior of the kanban view. If the stage is not set, the lead will be created in the "None" stage. opw-3512966 Forward-Port-Of: odoo/odoo#137389 Forward-Port-Of: odoo/odoo#136800
The commit https://github.com/odoo/odoo/commit/160e8bfbf72a3e5d7cc8d8cbe7bc4f310f298baa introduced a way to update the useragent used to request openstreetmap nominatim service. It was introduced as a bad fix to prevent an erroneous blacklist from the service. Once the blacklist has been removed, this fix was not necessary anymore. It also allows to abuse the free service which is against the osmfoundation policy. The best solution would be to decrease the amount of request. The Google Place
Original PR description
The commit https://github.com/odoo/odoo/commit/160e8bfbf72a3e5d7cc8d8cbe7bc4f310f298baa introduced a way to update the useragent used to request openstreetmap nominatim service. It was introduced as a bad fix to prevent an erroneous blacklist from the service. Once the blacklist has been removed, this fix was not necessary anymore. It also allows to abuse the free service which is against the osmfoundation policy. The best solution would be to decrease the amount of request. The Google Place Map service is also available to avoid using the openstreetmap service with large database. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#137886
Step to reproduce: - Install `Elearning` module - Go to any course and a content as document - Upload a PDF with more than 1 page - Go to the website and click on the course then on the content with the document - Go to last page and click on next button (should display suggested slides page) - Click on previous button Issue: Page displayed is not the last one, but the one before. Cause: When clicking on the previous button, the current page is still the la
Original PR description
Step to reproduce: - Install `Elearning` module - Go to any course and a content as document - Upload a PDF with more than 1 page - Go to the website and click on the course then on the content with the document - Go to last page and click on next button (should display suggested slides page) - Click on previous button Issue: Page displayed is not the last one, but the one before. Cause: When clicking on the previous button, the current page is still the last page (just with the suggested slides page on top of it as overlay), and therefore will decrease it to the page number before last page (nb last page - 1). Solution: When clicking on previous button, if we are on the suggested slides page (by checking if overlay is not hidden since no attribute is set on `EmbeddedViewer` to know if we are on that page), hide it. opw-3482712 Forward-Port-Of: odoo/odoo#135326
- Step: - Install project app - Activated Task Dependencies - Create project and task - Add sub-task - Click sub-task action - Issue: In the commit below we have passed the default_project reference so we get the current project stage. Fix: we pass 'subtask_action' context to subtask action and we checked that context in _read_group_stage_ids method if subtask_action context is found then we will not fetch project's stages. Side effect of this commit-https:/
Original PR description
- Step: - Install project app - Activated Task Dependencies - Create project and task - Add sub-task - Click sub-task action - Issue: In the commit below we have passed the default_project reference so we get the current project stage. Fix: we pass 'subtask_action' context to subtask action and we checked that context in _read_group_stage_ids method if subtask_action context is found then we will not fetch project's stages. Side effect of this commit-https://github.com/odoo/odoo/commit/23cf9318084c8a00f37ffcefefa3e056583d2d77 task-3390279 Forward-Port-Of: odoo/odoo#137977 Forward-Port-Of: odoo/odoo#129046
Description of the issue/feature this commit addresses: When opening a view with the quick filters available with a domain which returns no data, a message shows up saying that no filter is available for the data that has been retrieved and tells the user that updating the filters will allow him to display more records and maybe make the quick filter available. This message is displayed in a way which is not so great for user experience as it is written in a very thin column making the text b
Original PR description
Description of the issue/feature this commit addresses: When opening a view with the quick filters available with a domain which returns no data, a message shows up saying that no filter is available…
Description of the issue/feature this commit addresses: When opening a view with the quick filters available with a domain which returns no data, a message shows up saying that no filter is available for the data that has been retrieved and tells the user that updating the filters will allow him to display more records and maybe make the quick filter available. This message is displayed in a way which is not so great for user experience as it is written in a very thin column making the text being written one word per line. The example used to point out that problem is using the mexican localization, going in the accounting app, in the tax report and clicking on any value equals to zero. Desired behavior after the commit is merged : This commit replaces that message with a "All" button like it would be if the domain had returned data and some filters were available. Only this time, no filter is available under the button as there is still no data to filter. Adding this fix, there is no messy message showing up in the quick filters column when the query was not able to retrieve any data with the given domain. task-3462024 Enterprise PR : https://github.com/odoo/enterprise/pull/46422 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#133358
Before this commit, diagnosing websocket handshake error was cumbersome since the only information available was the return code of the initial HTTP request (400). The HTTP stack does not log `werkzeug.exceptions.HTTPException` and derivated classes. This commit adds a log in order to provide more insight about what went wrong. Forward-Port-Of: odoo/odoo#137972
Original PR description
Before this commit, diagnosing websocket handshake error was cumbersome since the only information available was the return code of the initial HTTP request (400). The HTTP stack does not log `werkzeug.exceptions.HTTPException` and derivated classes. This commit adds a log in order to provide more insight about what went wrong. Forward-Port-Of: odoo/odoo#137972
Avoid line breaks in monetary amounts. Steps to reproduce: * Either set the language to Swedish or enter dev mode and set the thousands separator to a space * Refresh the client * Create a purchase order * Create an order line, with taxes (important) for a total amount over a thousand * The total amount will now be broken up into two lines opw-3482329 Forward-Port-Of: odoo/odoo#136643
Original PR description
Avoid line breaks in monetary amounts. Steps to reproduce: * Either set the language to Swedish or enter dev mode and set the thousands separator to a space * Refresh the client * Create a purchase order * Create an order line, with taxes (important) for a total amount over a thousand * The total amount will now be broken up into two lines opw-3482329 Forward-Port-Of: odoo/odoo#136643
Before this commit: On applying background or on remove background color, strange padding is added on the text. After this commit: Now, padding is not added when background is colored is applied or background color is removed. task-3237693 Forward-Port-Of: odoo/odoo#138080 Forward-Port-Of: odoo/odoo#124394
Original PR description
Before this commit: On applying background or on remove background color, strange padding is added on the text. After this commit: Now, padding is not added when background is colored is applied or background color is removed. task-3237693 Forward-Port-Of: odoo/odoo#138080 Forward-Port-Of: odoo/odoo#124394
Current behavior: If you delete the default tip product, then activate tips in the PoS config you will be blocked by a warning message saying that the tip product is not set even if you set it. To fix this we only check if the tip product exist if the tips are activated. Steps to reproduce: -Delete Tip Product -Open PoS config -Activate tips -Try to save, you will be blocked by a warning message -If you try to turn off the tips, you will be blocked by the same warning
Original PR description
Current behavior: If you delete the default tip product, then activate tips in the PoS config you will be blocked by a warning message saying that the tip product is not set even if you set it. To fix this we only check if the tip product exist if the tips are activated. Steps to reproduce: -Delete Tip Product -Open PoS config -Activate tips -Try to save, you will be blocked by a warning message -If you try to turn off the tips, you will be blocked by the same warning message opw-3519123 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#137554
With this [commit](https://github.com/odoo/odoo/commit/adb8ec875c9b4e299147c46dc60a87fd26fff91f), we created a new 'Analytic Reporting' menuitem. But no `search_view_id` was specified, so it was falling back on the one from `hr_timesheet` (when installed), which we don't want. This commit fixes that by forcing the use of the one defined in `analytic`. task-3463639 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#135338
Original PR description
With this [commit](https://github.com/odoo/odoo/commit/adb8ec875c9b4e299147c46dc60a87fd26fff91f), we created a new 'Analytic Reporting' menuitem. But no `search_view_id` was specified, so it was falling back on the one from `hr_timesheet` (when installed), which we don't want. This commit fixes that by forcing the use of the one defined in `analytic`. task-3463639 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#135338
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#138068
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#138068
#### [REV] core: remove ORM `display_name` fallback This reverts commit 4573ca0c83eb63785016f4389a5157efb21fa9a4. Because now, `display_name` is implicitly on every form (last breadcrumb item). Then it will be queried by `onchange` calls. When we create a new record, `_rec_name` can be `False` and the display_name will be a technical one: '<model_name>,<NewId0x...>' which is uglier than the previous situation showing 'New'. #### [FIX] web: take in account `false` as a valid `display_n
Original PR description
#### [REV] core: remove ORM `display_name` fallback This reverts commit 4573ca0c83eb63785016f4389a5157efb21fa9a4. Because now, `display_name` is implicitly on every form (last breadcrumb item). Then…
#### [REV] core: remove ORM `display_name` fallback
This reverts commit 4573ca0c83eb63785016f4389a5157efb21fa9a4.
Because now, `display_name` is implicitly on every form (last breadcrumb item). Then it will be queried by `onchange` calls. When we create a new record, `_rec_name` can be `False` and the display_name will be a technical one:
'<model_name>,<NewId0x...>' which is uglier than the previous situation showing 'New'.
#### [FIX] web: take in account `false` as a valid `display_name`
The previous commit reverts the ORM fallback of `display_name`. Then the `display_name` can legitimately be `False` again. But the `Many2one` and `Many2XAutocomplete` components don't handle this case (and generate a traceback see task-3424154).
This commit adds the same fallback ('Unnamed record') for these two problematic components; one when the name_search returns `False` as `display_name` (autocomplete for Many2Xfields) and another when we read the many2one `display_name`. This name is not user friendly, but for the business model it shouldn't happen anyway. It is also better than the empty string which is confusing with no value. Note that there is already a fallback for `display_name` that is used in the broadcrumb
(https://github.com/odoo/odoo/blob/50b2a24f22cb470bcc1a9befe677cf794211d7b2/addons/web/static/src/views/form/form_controller.js#L282).
#### [FIX] web: display_name "New" fallback should only target new record.
There is a fallback in the control panel
(https://github.com/odoo/odoo/blob/c22cb6bbadd38ecb050f6d4dc14672868beda20b/addons/web/static/src/search/control_panel/control_panel.xml#L137)
if the display_name of the record is empty.
But it is never actually used because there is another
fallback in the form_controller ("New"). This latter fallback
should only be used for new records, not for existing ones.
## Alternative fix
The other way is to have a nice fallback in the `_compute_display_name`
(ORM side, see https://github.com/odoo/odoo/pull/133923). Unfortunately,
the performance cost is not small (each `display_name` should be
context-dependent and may generate extra queries to be computed) and the
model name (`_description`) is not meant to be user friendly. Instead,
a simpler solution is to have fallbacks on the JS side for each case.
Forward-Port-Of: odoo/odoo#137098similar to https://github.com/odoo/odoo/pull/87440 Forward-Port-Of: odoo/odoo#137960
Original PR description
similar to https://github.com/odoo/odoo/pull/87440 Forward-Port-Of: odoo/odoo#137960
Issue: ====== We have a delivery order created by a sale order by another user. A user with administrator access to inventory and sale : own documents only ,can't deliver products of that sale order without backorder , it shows access error. Steps to reproduce the error: ============================= - Create another user with admin access for inventory and own documents for sale. - Create a sale order with the current user. - Change now for the inventory admin and deliver some of the
Original PR description
Issue: ====== We have a delivery order created by a sale order by another user. A user with administrator access to inventory and sale : own documents only ,can't deliver products of that sale order without backorder , it shows access error. Steps to reproduce the error: ============================= - Create another user with admin access for inventory and own documents for sale. - Create a sale order with the current user. - Change now for the inventory admin and deliver some of the products and click on no-backorder. - Access error will show. Origin of the issue: ==================== The admin user should be able to deliver the products but when creating no backorder he needs to write on the sale_order. Solution: ========= Added `sudo` to the function that logs in the sale_order. opw-3380566 Forward-Port-Of: odoo/odoo#135872
Before this commit: In the `mailings` when we enable the A/B testing and click on the "Create an Alternative" button, the "Send final on" field doesn't copy to the new mailing. Reason: The related field are copy `false` by default. After this Commit: Now it will copy the "Send final on" into a new mailing Task: 3465887 Forward-Port-Of: odoo/odoo#137999 Forward-Port-Of: odoo/odoo#136406
Original PR description
Before this commit: In the `mailings` when we enable the A/B testing and click on the "Create an Alternative" button, the "Send final on" field doesn't copy to the new mailing. Reason: The related field are copy `false` by default. After this Commit: Now it will copy the "Send final on" into a new mailing Task: 3465887 Forward-Port-Of: odoo/odoo#137999 Forward-Port-Of: odoo/odoo#136406
__Current behavior before commit:__ When changing the `display_type` of an attribute in the website editor, the page is reloaded. However the template `website_sale.product` is contained in a `t-cache` on "pricelist,product". This means that the template will not be rendered again when the page is reloaded. Thus, the change will not appear for the user. __Description of the fix:__ Flush the cache from the `ir.qweb` model when the attribute display type is edited. This way the template `webs
Original PR description
__Current behavior before commit:__ When changing the `display_type` of an attribute in the website editor, the page is reloaded. However the template `website_sale.product` is contained in a `t-cache` on "pricelist,product". This means that the template will not be rendered again when the page is reloaded. Thus, the change will not appear for the user. __Description of the fix:__ Flush the cache from the `ir.qweb` model when the attribute display type is edited. This way the template `website_sale.product` will be refreshed. __Steps to reproduce the issue on runbot:__ - Go on the website product page of *Customizable Desk* - Open the website editor - Click on the Legs attribute values - Under the **Block** section, change the **Display Type** The page is reloaded but the display type stays the same ([Video][1]) opw-3495159 opw-3493820 [1]: https://drive.google.com/file/d/142VP4prnHskfa7uFoEkadsoQfQVO-uyW/view Forward-Port-Of: odoo/odoo#135349
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#138075
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#138075
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#137874 Forward-Port-Of: odoo/odoo#137603
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#137874 Forward-Port-Of: odoo/odoo#137603
**Description of the issue/feature this PR addresses:** It may happen that there is no company in env. Then the SQL query in `_get_multi` fails. It can happen for e.g. when running tests at install. **Current behavior before PR:** SQL query fails when `self.env.company.id == False` ``` 2023-10-06 12:59:24,382 767 ERROR odoo odoo.sql_db: bad query: SELECT substr(p.res_id, 13)::integer, r.id FROM ir_property p LEFT JOIN stock_locatio
Original PR description
**Description of the issue/feature this PR addresses:** It may happen that there is no company in env. Then the SQL query in `_get_multi` fails. It can happen for e.g. when running tests at install.…
**Description of the issue/feature this PR addresses:**
It may happen that there is no company in env. Then the SQL query in `_get_multi` fails. It can happen for e.g. when running tests at install.
**Current behavior before PR:**
SQL query fails when `self.env.company.id == False`
```
2023-10-06 12:59:24,382 767 ERROR odoo odoo.sql_db: bad query:
SELECT substr(p.res_id, 13)::integer, r.id
FROM ir_property p
LEFT JOIN stock_location r ON substr(p.value_reference, 16)::integer=r.id
WHERE p.fields_id=5862
AND (p.company_id=false OR p.company_id IS NULL)
AND (p.res_id IN ('res.partner,48') OR p.res_id IS NULL)
ORDER BY p.company_id NULLS FIRST
ERROR: operator does not exist: integer = boolean
LINE 6: AND (p.company_id=false OR p.company_id ...
```
**Desired behavior after PR is merged:**
Success of this SQL query.
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#137997Current behavior: When you link a printer to the sales detail report. The report will contains no order. This happens because we are trying to assign docids to the session_id. Steps to reproduce: - Install pos_iot - Link a printer from the demo iot to the sales_detail report (go in settings > reporting > reports) - Do some orders on the PoS, and close it - Go in the backend, and print the sales detail report - You will see that the report is empty (You can put a breakpoint in `get_sale_
Original PR description
Current behavior: When you link a printer to the sales detail report. The report will contains no order. This happens because we are trying to assign docids to the session_id. Steps to reproduce: - Install pos_iot - Link a printer from the demo iot to the sales_detail report (go in settings > reporting > reports) - Do some orders on the PoS, and close it - Go in the backend, and print the sales detail report - You will see that the report is empty (You can put a breakpoint in `get_sale_details` method to see that it will be empty) opw-3247196 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#138100 Forward-Port-Of: odoo/odoo#137446
### Steps - Create a new event. - Choose any template (training, conference,...). - Create new registration ticket for this event. - Create a new quotation. - Add 2 lines for "Event registration" product, and select each time the event and ticket created above. - Click on "Confirm". ### Issue 4 registrations lines are created and 3 attendees. ### Reason In ``RegistrationEditor.default_get()``, we match each sale order line with existing registrations in the sale order having the sa
Original PR description
### Steps - Create a new event. - Choose any template (training, conference,...). - Create new registration ticket for this event. - Create a new quotation. - Add 2 lines for "Event registration" product, and select each time the event and ticket created above. - Click on "Confirm". ### Issue 4 registrations lines are created and 3 attendees. ### Reason In ``RegistrationEditor.default_get()``, we match each sale order line with existing registrations in the sale order having the same ``event_ticket_id`` without assuming we can have multiple sale order lines with the same ``event_ticket_id``. That leads to [number_of_sol] * [number_of_ticket] registrations. To solve it, we just add an additional check for the ``sale_order_line_id`` to have a perfect match. opw-3495415 Forward-Port-Of: odoo/odoo#138111 Forward-Port-Of: odoo/odoo#138028
Before this commit, when using a loyalty reward with points, it is possible to give partial rewards. This commit prevents partial rewards. Example: - Rule: Grant 1 point per product bought; - Reward: 1.5$ per point in exchange of 2 points (3$) Before this commit, if you buy 3 products, you get 4.5$ by using 3 points. After, you only use 2 points and get 3$ (no partial reward). task-3300880 Forward-Port-Of: odoo/odoo#136982
Original PR description
Before this commit, when using a loyalty reward with points, it is possible to give partial rewards. This commit prevents partial rewards. Example: - Rule: Grant 1 point per product bought; - Reward: 1.5$ per point in exchange of 2 points (3$) Before this commit, if you buy 3 products, you get 4.5$ by using 3 points. After, you only use 2 points and get 3$ (no partial reward). task-3300880 Forward-Port-Of: odoo/odoo#136982
Ticket Adhoc: 65383 Task Latam: 1099 Description of the issue/feature this PR addresses: It is necessary in the account report invoice to show invoices grouped by partner_shipping_id. But if the invoice doesn´t have partner_shipping_id it is necessary to group by partner_id. Current behavior before PR: Account report invoice show invoices grouped by partner_shipping_id. Desired behavior after PR is merged: Account report invoice to show invoices grouped by partner_shipping_id but if
Original PR description
Ticket Adhoc: 65383 Task Latam: 1099 Description of the issue/feature this PR addresses: It is necessary in the account report invoice to show invoices grouped by partner_shipping_id. But if the invoice doesn´t have partner_shipping_id it is necessary to group by partner_id. Current behavior before PR: Account report invoice show invoices grouped by partner_shipping_id. Desired behavior after PR is merged: Account report invoice to show invoices grouped by partner_shipping_id but if the invoice doesn´t have partner_shipping_id it is necessary to group by partner_id. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#135931
This commit https://github.com/odoo/enterprise/pull/47021 removed the `updateOption` and `saveSessionOptions` part when it shouldn't. Forward-Port-Of: odoo/enterprise#48696
Original PR description
This commit https://github.com/odoo/enterprise/pull/47021 removed the `updateOption` and `saveSessionOptions` part when it shouldn't. Forward-Port-Of: odoo/enterprise#48696
The `XSD_INFO` was incorrect and not referrenced correctly, causing the validation to be skipped. Forward-Port-Of: odoo/enterprise#48604
Original PR description
The `XSD_INFO` was incorrect and not referrenced correctly, causing the validation to be skipped. Forward-Port-Of: odoo/enterprise#48604
This PR contains two commits each of which fixes a different unwanted behavior. --- 1. The account_reports module's commit fixes a bug happening in the reports. When unfolding a report which contains lines which have children but are not foldable, the unfolding process would not unfold those lines as they are not unfoldable and it would result in the report missing all the subsections and lines under that one. This is fixed by modifying the unfolding process of such lines. M
Original PR description
This PR contains two commits each of which fixes a different unwanted behavior. --- 1. The account_reports module's commit fixes a bug happening in the reports. When unfolding a report which contains…
This PR contains two commits each of which fixes a different unwanted behavior.
---
1. The account_reports module's commit fixes a bug happening in the reports. When unfolding a report which contains lines which have children but are not foldable, the unfolding process would not unfold those lines as they are not unfoldable and it would result in the report missing all the subsections and lines under that one.
This is fixed by modifying the unfolding process of such lines.
More information about that change can be found in the first commit's message.
---
2. The l10n_lt module's commit fixes a behavior happening in the Lithuanian BS and P&L. In those reports, the first lines of each section are not properly styled. This is due to them having the wrong hierarchy level assigned.
This is fixed by forcing the assignment of the right hierarchy level to the lines that are concerned.
More information about that change can be found in the second commit's message.
---
task-3462024
Community PR : https://github.com/odoo/odoo/pull/133358
---
I confirm I have signed the CLA and read the PR guidelines at [www.odoo.com/submit-pr](http://www.odoo.com/submit-pr)
Forward-Port-Of: odoo/enterprise#46422Depending on the filters applied on the intrastat report, different reports should be added to the XML export. Different companies have different reporting obligations when it comes to intrastat reports in Belgium. This largely depends on the total value of goods exchanged, but is specified by the government, and is largely unknown to us. Only the reports relevant to a particular company should be included in the XML export. Including a report for which the company has no obligation results i
Original PR description
Depending on the filters applied on the intrastat report, different reports should be added to the XML export. Different companies have different reporting obligations when it comes to intrastat reports in Belgium. This largely depends on the total value of goods exchanged, but is specified by the government, and is largely unknown to us. Only the reports relevant to a particular company should be included in the XML export. Including a report for which the company has no obligation results in an error while uploading. Our way of solving this is by having the XML contain only the reports which the current filters allow. The relevant filters in this case are "arrivals" and "dispatches", and "extended" (vs "standard"). Tests have been added to ensure the export format of the l10n_be_intrastat report is correct. task-id: 3501515 Forward-Port-Of: odoo/enterprise#48097 Forward-Port-Of: odoo/enterprise#47322
https://github.com/odoo/enterprise/pull/43103 refactored the sign template edition page to use the common PDF manipulation logic that all other iframe components used. However, during this refactoring, the deleteSignItem overwrite from SignTemplateIframe was calling super before adding the id of the deleted sign item to the array of deleted sign items. This caused the code to save the template before saving the id of the deleted item. This commit changes the order of the super call and the array
Original PR description
https://github.com/odoo/enterprise/pull/43103 refactored the sign template edition page to use the common PDF manipulation logic that all other iframe components used. However, during this refactoring, the deleteSignItem overwrite from SignTemplateIframe was calling super before adding the id of the deleted sign item to the array of deleted sign items. This caused the code to save the template before saving the id of the deleted item. This commit changes the order of the super call and the array assignment to fix the behavior. task-3489667 Forward-Port-Of: odoo/enterprise#47729
Before this commit: -When cancelling appointment based on resource it includes organizer name in mail template, which has nothing to do with that. -In portal view of user, default filter is 'upcoming'. After this commit: -Organizer's name is excluded from the mail template when cancelling a resource-based appointment. -Default filter is set to 'all' in portal view for appointment. Task-3458881 Forward-Port-Of: odoo/enterprise#46380
Original PR description
Before this commit: -When cancelling appointment based on resource it includes organizer name in mail template, which has nothing to do with that. -In portal view of user, default filter is 'upcoming'. After this commit: -Organizer's name is excluded from the mail template when cancelling a resource-based appointment. -Default filter is set to 'all' in portal view for appointment. Task-3458881 Forward-Port-Of: odoo/enterprise#46380
The aim of this commit is to correct the formula from the reports allowing users (and Odoo) to create accounts that is not part of the CoA aside of the existing accounts and make sure those are correctly included in the reports. Context: During the reworking of the CoA we were a bit too fast and we wrote the accounts numbers writen from the official spreadsheet. Before this commit: Accounts created by the OSS feature wouldn't appear in the CoA. After this commit: Those accounts appea
Original PR description
The aim of this commit is to correct the formula from the reports allowing users (and Odoo) to create accounts that is not part of the CoA aside of the existing accounts and make sure those are correctly included in the reports. Context: During the reworking of the CoA we were a bit too fast and we wrote the accounts numbers writen from the official spreadsheet. Before this commit: Accounts created by the OSS feature wouldn't appear in the CoA. After this commit: Those accounts appears in the CoA task-id: 3060790 Forward-Port-Of: odoo/enterprise#48569
Projects that have timesheets sold should be billable. This fixes staging failure of PR: [@odoo#137166](https://github.com/odoo/odoo/pull/137166) Forward-Port-Of: odoo/enterprise#48383 Forward-Port-Of: odoo/enterprise#48240
Original PR description
Projects that have timesheets sold should be billable. This fixes staging failure of PR: [@odoo#137166](https://github.com/odoo/odoo/pull/137166) Forward-Port-Of: odoo/enterprise#48383 Forward-Port-Of: odoo/enterprise#48240
When a normal user requests an appraisal, it will translate the QWeb template to an email form within `request_appraisal.py`, however, since the href is created as `t-att-t-att-href` instead of `t-att-href`, it still believes there is code within the template and throws a permission error in `_compile_directives`: `This rendering mode prohibits the use of directives.` For admin users this doesn't matter, but if a user doesn't have the `Mail Template Editor` group, they will get an access err
Original PR description
When a normal user requests an appraisal, it will translate the QWeb template to an email form within `request_appraisal.py`, however, since the href is created as `t-att-t-att-href` instead of `t-att-href`, it still believes there is code within the template and throws a permission error in `_compile_directives`: `This rendering mode prohibits the use of directives.` For admin users this doesn't matter, but if a user doesn't have the `Mail Template Editor` group, they will get an access error when sending the email: `Only users belonging to the "Mail Template Editor" group can modify dynamic templates.` By making these normal t-att-hrefs the issue is fixed. Forward-Port-Of: odoo/enterprise#48508