Daily updates from Odoo
Tuesday, March 10, 2026
60 changes · master
New functionality added to Odoo
This update introduces a new 'Airfare Allowance' field for UAE employees within their salary information. The system now calculates and includes this allowance on payslips based on the number of 'Air Tickets' entered, streamlining payroll processing for UAE-based staff. This enhancement ensures accurate compensation for travel expenses.
Original PR description
*= l10n_ae_hr_payroll_account - Add the 'Airfare Allowance' field in employee under the 'Allowance' section - Update the 'Airfare Allowance' salary input by changing label name to 'Air tickets' and input type to quantity - Now 'Airfare Allowance' will be included in the payslip on based of the number of 'Air Tickets' in the payslip - Update the related test cases. task-4718019
This update adds a currency field to the online account view, allowing users to accurately identify the corresponding bank account based on its currency. This improves clarity and reduces the potential for errors when managing online transactions.
Original PR description
The aim of this commit is to add the currency_id field on the online account view to allow users to identify the right bank account by using the currency. no task id
Enhancements to existing features
This update introduces a new field to track whether an employee is retired. This change is necessary to accurately calculate tax exemptions for employees who remain active while meeting specific criteria. It also prepares the system for future flexi-job functionality.
Original PR description
Retired employees that are still working can qualify for tax exemptions. This commit adds a boolean field to check if the employee is retired. Will be used for tax reporting and when flexi jobs are introduced. Task: 5976320
This update addresses an issue where excessive Many-to-Many tags could create a cluttered user interface. The commit limits the displayed tags, enhancing the visual appeal and usability of forms. A default limit of 8 tags is now enforced, with the option to display all tags (0) for greater flexibility.
Original PR description
Currently we don't have a way to limit the number of m2m tags displayed, which can lead to ugly UI. This commit introduces such a limit, making it editable via studio. As for default values, we use 8 as a default number of m2m tags displayed (which is also the number of records we display in m2m dropdowns). Setting a value of 0 can be used to display all tags regardless of how many they are. Community PR: https://github.com/odoo/odoo/pull/251159 Documentation PR: odoo/documentation#16667 task#5799365
This update adjusts the timing of changes to marital status for withholding tax calculations. Switching from an isolated status (single, divorced, widow) now takes effect at the start of the next calendar year, while becoming isolated (e.g., adding a spouse) is immediate. This aligns with Belgian tax regulations.
Original PR description
For withholding taxes: ----------------------- Switching from an isolated status (single, divorced, widow) to a non isolated will take effect the start of the next calendar year. But the other way around (becoming isolated) takes effect immediately. Task-5449907
This update optimizes Odoo's reporting functionality, specifically addressing memory usage issues with large datasets and improving report stability. The team removed unused code and refactored report generation to enhance performance and reduce resource consumption.
Original PR description
Forward-Port-Of: odoo/enterprise#102808
This update simplifies our payroll structure for Belgium, aligning with new regulations regarding joint committees. It consolidates previous CP200 structures into a single 'Belgium' structure, ensuring compliance and streamlining payroll processing. Additionally, the update introduces key features for worker compensation, including unpaid time off, sick leave calculations, and adjusted ONSS base rates.
This update streamlines invoice reports for Ecuador by removing redundant information previously displayed in the standard header. The changes also adjust the report formatting to ensure proper spacing and avoid overlapping with required legal headers. This improves the clarity and compliance of the reports.
Original PR description
The standard report header contains info that the legally required headers already contain. We hide the standard headers by using the custom_header mechanism in l10n_latam_invoice_document. This also changes an `<h4>` to an `<h5>` to avoid it overflowing the standard header_spacing of the A4 report.paperformat. task-5949275
This update simplifies the approval process by replacing a complex 'approval_type' field with a straightforward boolean. The change clarifies required approvals and streamlines the flow for managers, making it easier to manage purchase requests. This enhancement improves efficiency and reduces potential confusion.
Original PR description
This commit aims to make some enhancement to the approval Category and Request Forms. Given that approval_type will either be 'purchase' or empty, it's better to replace it with a boolean field. The field "manager_approval" is now a Boolean with False being the old None and True being "Is required Approver", and the third option "Is Approver" is now dropped. odoo/upgrade#9373 Task - 5410747
This update adds quick access to key payroll reports directly within the pay run interface. HR and payroll teams can now easily verify work entries and payroll codes, detect anomalies, and improve data accuracy – ultimately reducing the time spent on pay run audits.
Original PR description
Purpose As an HR officer or payroll consultant, add quick access to pay run verification reports to efficiently identify and validate potential errors. Changes - Add Work Times report button to pay run kanban view - Add Payroll Journal report button to pay run kanban view Benefits - Verify work entry types and payroll codes used in the pay run - Detect anomalies by comparing values with previous periods - Provide quick access to detailed reports without additional navigation - Reduce time spent verifying pay run data for accuracy This enables users to perform comprehensive pay run audits directly from the pay run interface, improving data quality and compliance. Task: 5974389
Resolved issues and error corrections
This update resolves an issue causing the floor plan screen to repeatedly refresh, impacting the user experience. The problem stemmed from a bug where the system was incorrectly modifying appointment times, triggering endless re-renders. This fix ensures appointments are displayed accurately and reliably.
Original PR description
Infinite re-rendering in floor_screen.
Root cause: `getFirstAppointment` mutates reactive model state
(appointment.start) during rendering:
```
appointments.map((appointment) => {
if (appointment.start < startOfToday) {
appointment.start = startOfToday; // <= mutates reactive state!
}
});
```
And `startOfToday` is set by
`DateTime.now().set({ hours: 0, minutes: 0, seconds: 0 })`
Which doesn't zero milliseconds, so each render creates a new
`startOfToday` with a later millisecond value.
The comparison `appointment.start < startOfToday` keeps being true
triggers another write => another re-render => infinite loop.
Forward-Port-Of: odoo/enterprise#109915This update fixes an issue related to managing private cities within the payroll system. A new module, `hr_address_extended`, has been added to handle this functionality, particularly when the ‘enforce_cities’ setting is enabled. This ensures accurate city data is captured and utilized for payroll calculations.
Original PR description
. Add new module hr_address_extended to handle M2O private_city field if enforce_cities is enabled . Add hr_address_extended to l10n_us_hr_payroll dependencies . Add Corresponding tests task-5877610
A bug causing the kitchen display to go blank when sending orders from the POS has been fixed. The update ensures the correct configuration ID is loaded, allowing orders to be properly displayed and processed on the kitchen display. This improves the efficiency of order fulfillment.
Original PR description
*=pos_urban_piper Steps to produce: ==== - Install pos_restaurant without demo data - Configure kitchen display - Place order from pos. Issue: ==== - Kitchen display gets blank as config_id was not loaded. Fix: ==== - `config_id` field was loaded in the frontend task-5999170
This update resolves an issue with the XML reports generated for Mexican tax filings, specifically addressing accounts with single-digit codes. A new field was added to the accounting structure to allow for more flexible reporting while ensuring accurate XML generation for Mexican tax compliance. The changes also update associated test cases.
Original PR description
This commit fixes the unit tests in l10n_mx_xml_polizas after code_digits has been retrieved. task-5981095
This update prevents the payslip validation process from failing if the wkhtmltopdf dependency is not present. The system now automatically generates PDFs via a scheduled task (cron) instead, ensuring payslips can still be processed without requiring the user to install wkhtmltopdf. This improves usability and avoids unnecessary disruptions.
Original PR description
You don't want to block the payslip flow if wkhtmltopdf is not installed. This commit avoids that by redirecting the pdf generation to the cron if not installed. That way, it won't affect the state of the payslip. task-6013936
This update allows users to directly edit the name of a Pay Run within its Kanban view, providing greater flexibility in managing payroll records. Previously, changes were only possible when viewing the Pay Run details. This enhancement simplifies the process of updating Pay Run names and improves user workflow.
Original PR description
This change restores inline editing of the Pay Run name in their (default) kanban view. task-5981049
This update adds a toast notification to the payslip view when a PDF is generated. Previously, users weren't informed about the progress of PDF creation, leading to uncertainty. This change provides clear feedback, ensuring users know the PDF generation process has started and completed successfully.
Original PR description
[IMP] hr_payroll: toast notification during PDF generation In payslip views, there were no toast notifications when we press to generate PDF. It was not clear whether they are generated or not and that's why we implemented this feature. task - 5975715
This update corrects a display issue within the tax return checklist. Previously, the system incorrectly flagged 'bill attachments' as an anomaly even when documents were attached to bills. Now, if all bills have attachments, the system correctly displays 'reviewed' instead of 'anomaly', streamlining the tax return process.
Original PR description
When going through checklist of tax return, anomaly is created for "bill attachments" even when a document is attached to bill. If all bills have attachment, state should not display "anomaly", but "reviewed" instead The reason of the bug is that the domain is looking for attachment to account.move which ignore the documents in the chatter, while the bill is actually attached in the chatter. task: 5408611
This update corrects a technical issue related to how the system accessed barcode target records, preventing performance problems. The change simplifies the process and avoids potential problems with future updates, ensuring consistent and reliable barcode scanning functionality. This resolves a bug that could impact user experience.
This update resolves a bug that caused the AI chat composer to crash when using the HTML editor. The fix ensures focus handling works correctly for both the text and HTML composer modes, preventing errors and improving the user experience.
Original PR description
*=ai_app In AI chat, focusing the composer used to call ev.target.select(). That works for the text composer (textarea), but not for the HTML composer (contenteditable), where select() doesn’t exist and causes a TypeError. This update makes focus handling respect the active composer mode: - text mode keeps the existing select behavior - html mode uses the editor focus path instead task-5981018 Forward-Port-Of: odoo/enterprise#109865 Forward-Port-Of: odoo/enterprise#109163
This update removes unnecessary customizations related to Swiss payroll calculations within the payrun process. The core logic has been corrected, making these overrides no longer required. This simplifies the system and ensures accurate payroll processing.
Original PR description
Not necessary anymore, standard logic has been fixed Forward-Port-Of: odoo/enterprise#108121
This update fixes a bug preventing warnings on the EC Sales List when customers don't meet specific criteria (e.g., location within Europe). Previously, the report didn't display these warnings for customers with 'Intra-Community' fiscal positions or those located outside of Europe. This ensures accurate reporting and compliance.
Original PR description
The warnings partner_same_country and partner_no_ec_country on the EC Sales List are never showed. To Reproduce (for partner_same_country warning): - Create a company in Belgium - Create a customer in Belgium with "Intra-Community" as a Fiscal Position - Create an invoice with this customer - Go to the EC Sales List - The customer doesn't appear in it, so the warning is not present. For the partner_no_ec_country, do the same but with the country of the customer being one outside of Europe. Forward-Port-Of: odoo/enterprise#109583 Forward-Port-Of: odoo/enterprise#107139
This update resolves an issue where users without project access rights would encounter errors when modifying work orders linked to private projects. The fix ensures that workers can successfully update these work orders by granting necessary read permissions to project data, preventing access errors and improving workflow efficiency.
Original PR description
When working on a MO that is linked to a project in private, it will trigger a access error if the worker is does not have project access right Steps to reproduce: ------------------- * Install Project, MRP, Accouting * Create a private project * Create a MO and link it to this project * confirm this MO with a user that has no project access right Observation: ------------- When modifying the MO, we will pass through the write that has been overwritten: https://github.com/odoo/enterprise/blob/b332af45a46b2295797a5096f68b7953554a495b/project_mrp_workorder_account/models/mrp_production.py#L6-L10 we will call _get_analytic_distribution on project.project and since _get_analytic_distribution will [read fields from self](https://github.com/odoo/odoo/blob/436921c24a531eba6bf57ffe3f7c3b4978139d83/addons/analytic/models/analytic_line.py#L59-L64) we need project.project read rights. opw-4919576 Forward-Port-Of: odoo/enterprise#108148
This update fixes an issue where sick leave days weren't accurately counted across months and where the basic salary was incorrectly calculated when there were no work entries. The changes ensure accurate payroll processing for sick leave and basic salary, particularly for leaves spanning multiple months.
Original PR description
### Issue: - Sick leaves were calculated using the leave record dates, so leaves that started in one month and continued into another month were not counted correctly. - The Basic salary rule was…
### Issue: - Sick leaves were calculated using the leave record dates, so leaves that started in one month and continued into another month were not counted correctly. - The Basic salary rule was applied even when there were no `WORK100` work entries on the payslip. ### Fix: - Updated the leave filtering logic to consider leaves whose `request_date_from` or `request_date_to` overlaps with the payslip period year, instead of relying solely on the leave start date. - Adjusted the Basic salary computation to execute only when `WORK100` exists in `worked_days_line_ids`, preventing calculation when no effective worked entries are present. ### Impact: - Ensures sick leave days are correctly accounted for in the relevant payslip period, even when the leave spans across months. - Prevents incorrect Basic salary computation on payslips with no `WORK100` work entries, resulting in accurate payroll calculations. --- task-5462380 Forward-Port-Of: odoo/enterprise#109892 Forward-Port-Of: odoo/enterprise#104401
This update corrects a display issue where 'Confirm' buttons were visible even when payslips had been generated. The system now correctly hides these buttons when there are existing payslips, ensuring a cleaner user interface. This improves clarity and prevents confusion for users.
Original PR description
The 'empty_payslips' field is an Integer, but the view was treating it as a pure Boolean. This commit: - Updates 'Confirm' buttons to be invisible when payslips exist (> 0). Task: 5916154 Forward-Port-Of: odoo/enterprise#109926 Forward-Port-Of: odoo/enterprise#106957
This update resolves a crash that occurred when sending Electronic Data Interchange (EDI) documents. The fix converts data back to a standard format for the IAP server, addressing an incompatibility issue identified in the Odoo system. This ensures EDI sending functionality is now reliable.
Original PR description
Following [^1] most base64 file access has been passed through `BinaryValue` and `BinaryBytes` classes. This assists with database access, however, this was change in `l10n_pe_edi` in a place that sends a request to the IAP server. Since `requests.requests` doesn't know how to handle the new datatype `BinaryBytes` we need to convert it back to b64. opw-none [^1]: #104714
A bug in the Gantt view of service projects, triggered by grouping tasks, was resolved. The issue stemmed from incorrect date parsing within the project domain logic. This update now correctly handles dynamic dates, ensuring the Gantt view functions reliably.
Original PR description
### Issue: When in the Gantt view of service projects, grouping by project results in a traceback. ### Steps to reproduce: - Create another field service project - Create a task in the new project…
### Issue: When in the Gantt view of service projects, grouping by project results in a traceback. ### Steps to reproduce: - Create another field service project - Create a task in the new project and add start and end dates - Go to Field service > my tasks > gantt view > group by project - Error with traceback `time data 'today' does not match format '%Y-%m-%d %H:%M:%S'` ### Cause: This [commit](https://github.com/odoo/odoo/commit/d1ea43f6721116914762ea323d8a5987f043e87f) added the possibility to use dynamic dates in domains. Then all domains were changed in 42b1fca8e127926a06f503d79c8baeddf7d5ae82 But `_expand_domain_dates()` is trying to parse the dates as if they were written in ISO format: https://github.com/odoo/enterprise/blob/be853cc1ee544dda580960d94417cfdff2c8a7db/project_enterprise/models/project_task.py#L626 ### Solution: We use the method `parse_date()`, which was added with dynamic dates, to parse them. opw-5955317 Forward-Port-Of: odoo/enterprise#109236
This update resolves several issues impacting the planning module, primarily focusing on accurate shift calculations, mobile map views, and button visibility. It ensures shifts are correctly assigned, improves the user experience on mobile devices, and provides appropriate button functionality based on intervention status.
Original PR description
## [FIX] planning: make sure allocated_percentage is defined in the view Before this commit, since we remove the allocated percentage field from the form view, the framework js does not know that…
## [FIX] planning: make sure allocated_percentage is defined in the view
Before this commit, since we remove the allocated percentage field from
the form view, the framework js does not know that field has a default
value and so it will set 0 by default for the float field and give it as
parameter when it will request an onchange when the user wants to create
a new shift.
This commit makes sure the field is inside the form view to be sure the
default value is taken into account to correctly compute the
allocated_hours.
## [FIX] planning: make sure we compare apples with apples
Before this commit, the copy previous week action in planning.slot could
crash because values for new shifts could contain Commands in
`resource_ids` field.
This commit makes sure we convert those commands into resource ids to be
able to compare those ids with the ones on the shift processed.
## [FIX] planning_field_service: display map view in mobile in My Map
Before this commit, the `My Map` action displays the calendar view in
mobile instead of the map view.
This commit makes sure we first display the map view in any device when
`My Map` action is loaded.
## [FIX] planning_field_service: hide field service buttons when slot not published
Before this commit, some buttons in planning.slot were visible even if
the intervention is not published or in progress.
This commit makes sure the buttons are visible when the state of the
intervention is published or in progress depending on what is the
purpose of the button.
## [FIX] planning_field_service: open full form view in calendar
This commit makes sure the form view is fully opened in the calendar
view of planning.slot instead of opening it inside a modal.
## [FIX] web_gantt: undo the rechescule of shifts and keep resources set
Before this commit, when the user reschedules a shift by drag and
dropping a pill in the gantt view and the group by is by Resources, if
the shift was assigned to more than one resource and the user undo his
action, the shift will be assigned to only the resource where the pill
was before the drag and drop instead of keeping its initial resources
set.
This commit makes sure the resources which were assigned to shift are
correctly set once the user undo the reschedule made.
## [FIX] planning_holidays: correctly compute the search domain for is_absent
Before this commit, the `employees on time off` filter does not return
the shifts with at least one human resource off due to wrong calculation
made in the search method of `is_absent` field defined in
`planning.slot` model.
This commit fixes the issue to correctly show the shifts with at least
one human resource off in the period of the shift.
## [FIX] planning_field_service_{sale_timesheet,worksheet}: display photos before materials
This commit makes sure the Photos button is before the one to add
materials in the intervention.
## [FIX] planning: display icon instead of label in calendar view
This commit reviews the popover in the calendar view of planning.slot to
replace the label by the icon to let more space for the value of each
fields displayed in that popover.
It also display in week by default the calendar view of planning slot in
My planning menu
## [FIX] planning: don't send re-assign email when one more resource is assigned
Before this commit, when the user edits a shift to add an additional
resource to the shift, the resource initially assigned to the shift will
receive a re-assign email even if he is still assigned to the shift.
This commit makes sure the email is sent only when the resource is no
longer assigned to the shift.
## [FIX] planning_field_service: add navigation map button to popovers and some fixes
This commit mainly adds a button to easily redirect the user to google
map with the customer address.
## [FIX] planning: don't show seconds in allocated_hours field
Before this commit, due to a rework of duration format, the allocated
hours now displays the seconds which is not really needed and take more
space than expected.
This commit makes sure we don't display the seconds in the allocated
hours field of planning.slot since that information is not really
useful.
## [FIX] planning{_field_service}: simplify display_name and conflicts warning
This commit simplifies the conflict warning in the form to have a
minimal warning message. The display name has been reviewed to only
display partner_id and role_id if partner_id otherwise project_id and
role_id will be displayed.
## [FIX] planning: don't include material resources when a human resource is set
This commit removes the material resources in the compute allocated
hours when there is at least one human resource set with it since we
could assume the material resources will just be used by the human
resource(s) assigned to the shift.
## [FIX] planning_field_service: fix geolocation when sign_in/complete intervention
Before this commit, the geolocation feature does not work because it was
only done in sign in button in calendar popover of planning.slot but the
feature is also needed when the user clicks on sign in and complete
buttons in the other views of planning.slot.
This commit makes sure the geolocation feature works in any view where
the sign in and complete buttons are currently displayed.
## [FIX] planning_field_service: add subtypes
## [FIX] planning: don't generate shifts in multi create when no resource available
Before this commit, when the user wants to create multiple shifts for a
certain resource in the gantt to cover a whole week (weekend included),
the shifts in the weekend will be generated as open shift since the
resource does not work during the weekend. Actually, the shifts should
not be generated in non working day for the resource.
This commit makes sure the shifts are not generated in non working day
of a resource selected.
## [FIX] planning_field_service: facilitate the work of planning manager
Before this commit, the planning manager cannot sign in for one of his
workers in the case, one worker forgot to do it and the intervention is
in the past. Hide price feature does not work correctly because the
check to know if the feature is enabled or not does not take the right
setting (wrong module because the feature has been moved before the
merging the main task).
This commit make sure the sign in button is available even if the
intervention is in the past. Some wordings have been reviewed and fix
typo to correctly check if hide price is enabled or not in the setting
of planning.
This commit also hides some fields for planning user when field service
is enabled in planning to only show the most important information for
the workers.
## [FIX] planning_field_service: add Today filter by default in My Map
## [FIX] planning_field_service: sign-in should recompute end date when needed
Before this commit, since the user can sign in when the shift is in the
past, we need to recompute the end_datetime to make sure the
end_datetime set is not before the start_datetime.
This commit recomputes the end_datetime when the shift is in the past
and the user clicks on sign in since the button will update the start
datetime to current time.
## [FIX] planning{_field_service_worksheet}: fix mobile form view in gantt
Before this commit, the Photos button displayed in the form view in
gantt does not have the same width than the other buttons in the form in
mobile. Moreover, a margin left is added on the first button in the form
view in gantt but in mobile that button is no longer aligned with the
other ones displayed.
This commit fixes those issues to make sure the buttons in the form view
displayed in the gantt view have the same width and the same alignment.
## [FIX] planning_field_service: fix break_time compute
Before this commit, the allocated hours field contained the sum of the
working hours of the human resources when there is at least one human
resource and so the working hours of the material resource assigned on
the intervention is not taken into account. Also, the compute of break
time field does not correctly compute it when there is more than one
resource.
This commit adapts the compute of break time according to the changes
made in the compute of allocated hours.
## [FIX] planning_field_service: hide Sign in button when no customer set
## [FIX] planning_field_service: fix SOL flow when confirming shift and portal
Before this commit, the portal views were not correctly supported the
portal user (missing sudo to find interventions completed and related to
the user which is the customer). A route is not adapted to the new route
in field service feature of helpdesk.
This commit fixes the access error in the portal to make sure the portal
user can access to intervention made for him.
## [FIX] planning_field_service_sale_timesheet: avoid copying SO and SOL
Before this commit, when field service and Billing features are
installed in planning and the user duplicates an existing intervention,
the SO and SOL fields are also copied and so the new materials added to
the new intervention will be added inside the same Sale Orders then the
one copied which is not really expected.
This commit avoid copying SO and SOL when duplicating an intervention
when field service is enabled in planning.
## [FIX] planning_field_service_sale_timesheet: rename label of back button in product
## [FIX] project_timesheet_forecast: fix compute effective hours
Before this commit, when field service and Billing features are enabled
in planning and the user completes an intervention, the allocated hours
and the break time are recomputed when the timesheets are generated for
the intervention, because of the hours recorded could be wrong in the
case the intervention finished after the working schedule of the workers
assigned. The issue is because when a timesheet is created, the
timesheet_ids field is recomputed and recompute effective hours and
allocated hours with other fields. Moreover, timesheet_ids is not stored
and is inside the compute of effective hours and that field is stored
which is not a good practise since the compute of effective hours will
do many write on db since timesheet_ids field will be recomputed each
time we need to read that field.
This commit reviews the compute of effective_hours to no longer depends
on timesheet_ids and makes sure the effective_hours field in
planning.slot are recomputed for the right slots when the employee_id,
date, task_id, project_id and unit_amount field are updated (or when the
timesheet is created). By doing that, that compute will only be computed
when needed.
## [FIX] planning_field_service: add some fields in calendar portal, and some more fixes
This commit adds the new fields added by field service in the planning
portal made for employees without any users to access in the backend.
task-5921961
task-5994180
Forward-Port-Of: odoo/enterprise#109332This update corrects a visual imbalance in the layout of Knowledge articles within the Odoo system. The change ensures consistent horizontal spacing, resulting in a more professional and balanced appearance for all articles. This improves the overall user experience and presentation of our knowledge base.
Original PR description
The Knowledge article layout shows a visual imbalance due to asymmetric horizontal spacing in the editor content. This change makes the horizontal spacing consistent on both sides, improving the overall visual balance while maintaining proper spacing and layout consistency. Task-5222643 Forward-Port-Of: odoo/enterprise#108437
This update fixes a potential issue where changes to knowledge articles (sharing, favorites, editing) weren't reliably applied. The update ensures the correct article is loaded before any modifications are made, enhancing the user experience and data consistency. This improves the reliability of the knowledge base.
Original PR description
With this commit, We ensure we're in the correct article before making any changes (share, add to favorites, edit) using `waitUntil`. We've added a `checkArticle` function to ensure the article is in the correct place in the menu. runbot-error-id~234645
This update optimizes how Odoo calculates planning fields for sales orders. Previously, all sales order lines were processed, even those not directly involved in planning. Now, calculations are focused only on sales order lines linked to products with planning enabled or those included in a planning slot, improving efficiency and accuracy.
Original PR description
Before this commit, the compute of planning_hours_to_plan and planning_hours_planned fields computes for all SOLs even the ones which are not related to planning. This commit makes sure the both computes calcules the planning field for the SOLs which are related to planning, that is: - SOL is linked to a product with planning_enabled set to True - or at least one planning slot has the SOL set. Issue detected during a fix of migration script of task-5258989 Forward-Port-Of: odoo/enterprise#109715
This update resolves several issues impacting the AI chatbot functionality, specifically related to prompt definitions and voice transcription. The fixes ensure correct prompt usage, prevent errors during rendering, and resolve issues impacting public users attempting to interact with the AI.
Original PR description
This PR fixes the following bugs: - After 2acc117, users have the ability to define prompts for ai.prompt.button records instead of using the name field as the prompt. However, the VoiceTranscription component wasn't updated to use the new prompt field. - The _render_prompt method should return the `name` of the `ai.prompt.button` if no `prompt` is defined or no `rendering_record` is passed to the method. However, this check didn't take into account that `prompt` may contain empty HTML, for example `Markup(<p></p>)`. - Accessing render_model field on `ai.prompt.button` records raises AccessError. - An error would occur if a public user (or portal) tried to chat with the AI using the live chat. - The composer retrieved by the `TranscriptionComponent` doesn't take the model of the current record into consideration. Forward-Port-Of: odoo/enterprise#108115
This update fixes a potential issue where changes to knowledge articles (sharing, favorites, editing) weren't reliably applied. The update ensures the correct article is loaded before any modifications are made, enhancing the user experience and data consistency. This improves the reliability of the knowledge base.
Original PR description
With this commit, We ensure we're in the correct article before making any changes (share, add to favorites, edit) using `waitUntil`. We've added a `checkArticle` function to ensure the article is in the correct place in the menu. runbot-error-id~234645
This update resolves a technical problem where Odoo was crashing when displaying images due to incorrect handling of binary data in templates. The fix ensures images are properly encoded as base64 strings before being used, preventing errors and improving image display reliability.
Original PR description
Templates embedding binary images using data URIs expected base64 strings and crash when receiving raw binary values (UnicodeDecodeError) during QWeb rendering. Encode the binary values explicitly using to_base64() before embedding them in the image source. See also: - https://github.com/odoo/odoo/pull/252710
This update fixes an issue where payrun status bubbles appeared as solid black in dark mode due to a hardcoded color setting. The change now uses a dynamic background color, ensuring the bubbles always match the current theme and display correctly regardless of the user's chosen mode.
Original PR description
The status bubbles in the payrun view were using the literal 'bg-white' class. In dark mode, it automatically inverts 'bg-white' to solid black. This commit changes the hardcoded 'bg-white' to the semantic 'bg-view' class. This ensures the bubble background always matches the current theme's view background variable. Task: 5959361
This update fixes a bug in the softphone's contact search, ensuring it now uses the full partner name instead of just the name. This provides more accurate search results and a better user experience when finding contacts within the softphone application. The change includes updates to both the backend Python code and the frontend JavaScript.
Original PR description
Search by partner's name in softphone should be based on complete_name, while it's currently based on name. To fix it, we do two fixes in this commit: 1. On the python side, make sure voip.call search is based on complete_name like in res.partner. No change for mail.activity search, since it always get all record. When do the search, we also make sure the search_term is escaped so that it won't trigger psql's wildcard. 2. On the js side, make sure we filter the results by complete_name. Task-[5475413](https://www.odoo.com/odoo/5778/tasks/5475413)
This update fixes a problem where users were encountering error pop-ups when accessing the payroll dashboard after making schedule changes. The issue stemmed from an outdated warning update process, now resolved by ensuring updates are performed with elevated permissions. This improves the stability and usability of the payroll module for all users.
Original PR description
Bug production: select your company -> payroll dashboard -> set schedule -> return back to apps -> change to belgium comp. -> payroll dashboard -> try to set schedule -> access error pop ups Bug cause: There is a warning update part when the dashboard is opening, in that part updating other company's warning leads to problems. Bug solution: Make the warning update as sudo task - 5958991
This update fixes an issue where icons were incorrectly displayed on small screens within the VoIP form. The change ensures that icons are only shown on desktop views, aligning with the overall form layout and improving the user experience. This ensures consistent visual presentation across different device sizes.
Original PR description
We only want these icons on desktop, as the content is not aligned with the rest of the form view. On small screens, each field is displayed one below the other, regardless of whether it is inside a header_group or not. So icons have been replaced by the label (which doesn't appear on desktop). task-6010516
This update fixes an issue where YTD payroll calculations were inaccurate after enabling YTD tracking on existing payslips. The change ensures that YTD amounts are consistently computed and displayed correctly, resolving confusion around worked days and salary totals. The YTD checkbox in structures now only controls UI visibility.
Original PR description
Steps: - Take any structure and ensure the YTD option is turned off in that structure. - Go to Payroll > Payslips and create a few payslips with that structure. Confirm them. - Now, enable the YTD…
Steps: - Take any structure and ensure the YTD option is turned off in that structure. - Go to Payroll > Payslips and create a few payslips with that structure. Confirm them. - Now, enable the YTD setting in that structure. - Open those confirmed payslips and check the YTD amount. It's not accurate. Issue: - When YTD tracking was enabled after confirming some payslips, the worked days section showed zero in the YTD column. - This caused confusion because: - The salary line YTD showed the current payslip’s amount, - The worked days YTD showed 0. Both should accurate. - YTD values were only computed if ytd_computation was enabled during compute_sheet method. - As confirmed payslips aren’t recomputed, worked days showed 00 YTD amount, when the setting was turned on later. Fix: - Removed conditional checks on 'ytd_computation' from the YTD calculation logic. - YTD values are now always computed and available on payslips and worked days. - The 'ytd_computation' checkbox in structure is retained only for visibility toggling. - e.g. showing/hiding YTD columns in payslips, reports or UI. Task - 4790749
This update resolves an issue where the Documents app would crash after deleting a payslip run. The fix ensures that associated documents are also deleted when the payslip run is removed, preventing data inconsistencies and improving application stability. This improves the user experience when managing payroll documents.
Original PR description
### Issue: When deleting a payslip run, the documents from the payslips of the run are not deleted. This results in a traceboack when opening the document app. ### Steps to reproduce: - Have a…
### Issue: When deleting a payslip run, the documents from the payslips of the run are not deleted. This results in a traceboack when opening the document app. ### Steps to reproduce: - Have a payslip run with payslips - Go to a payslip, validate and generate the document - Then cancel and reset to draft - Reset the Payslip Run to draft - Delete it - Open the Documents app ### Cause: The payslips are linked to the run with a `ondelete='cascade'` relation. https://github.com/odoo/enterprise/blob/03b2a7dae0e5c5ad3142ec2da8f3de5c9b1957f4/hr_payroll/models/hr_payslip.py#L110-L113 This means that deleting the run also deletes its payslips on a database level, bypassing the ORM. As the document is not directly linked by a relational field but instead by `res_model` and `res_id`, these fields are not updated and therefore are still pointing to a record that is no longer in DB. ### Solution: Extend the `unlink()` method in `hr.payslip.run` and unlink the documents there. opw-5501061 Forward-Port-Of: odoo/enterprise#109741 Forward-Port-Of: odoo/enterprise#105969
This update fixes an issue where employees with flexible calendars were incorrectly displaying unavailable days in planning and related modules. The change ensures that flexible employees only show unavailable times for public holidays, improving the accuracy of scheduling and resource allocation. This resolves a visual discrepancy impacting how employees see their availability.
Original PR description
### Issue: When an employee has a flexible calendar, its gantt view in planning and other modules, like project or time off, shows incorrect grayed-out days. In general, employees with a flexible…
### Issue:
When an employee has a flexible calendar, its gantt view in planning and other modules, like project or time off, shows incorrect grayed-out days. In general, employees with a flexible calendar should not have any grayed out days other than public holidays.
### Steps to reproduce:
- Create a new work schedule:
- Flexible Hours
- 24 hours per week
- 8 average hours per day
- Create an employee with this work schedule
- Open Planning app
- Only the three first days of the week are not grayed out
### Cause:
With 24 hours per week, the worked time can be done in three days. Odoo considers that the first three days of the given time frame are worked, but the others aren't. This result is returned by `_work_intervals_batch()`. In `_unavailable_intervals_batch()` we then build the unavailabilities by taking the inverse of the work intervals. The only exception was for fully flexible resources (i.e. without a calendar).
### Solution:
The case we need to consider is for flexible resources: they are available anytime, all week long except on public holidays and leaves.
To do this we fix the method `_unavailable_intervals_batch()` which is then called by each module. If the resource is flexible, then we only return the interval of the public holidays overlapping with the time frame.
Works in `appointment`, `hr_holiday_gantt`and `project_enterprise`.
In `planning`, we need to skip the case where nothing is returned in `leaves_mapping` otherwise it will consider the `company_leaves` during weeks with no public holiday or leaves.
In `hr_attendances_gantt`, `_unavailable_intervals_batch()` is not called. So we change the way the unavailabilities were computed to call `_unavailable_intervals_batch()` instead.
Forward-Port-Of: odoo/enterprise#109812
Forward-Port-Of: odoo/enterprise#105521This update enhances the Time Off Gantt view by displaying total worked hours directly on the progress bar and providing more direct actions – Approve and Refuse – instead of a general Save button. These changes streamline the approval process and improve the overall user experience for managing employee time off requests.
Original PR description
Changes Show total worked hours in the progress bar before the employee name. Remove the Save button from the popover and add Approve and Refuse buttons for direct action. Remove the Reset button from the Gantt view. UX improvements: Show the deferred icon on the pill. Fix popover margins and remove unnecessary message. task-5941368 Forward-Port-Of: odoo/enterprise#107938
This update resolves an issue where duplicate move records were being displayed in the shop floor view, leading to a technical error. The fix clarifies how work orders and moves are linked, ensuring accurate display of components and preventing the 'duplicate key' error. This improves the user experience when creating and managing work orders.
Original PR description
*: {quality_,}mrp_workorder, quality_mrp_workorder_worksheet ### Steps to reproduce: - Enable debug mode (to trigger a traceback rather than a silent error) - In the settings, enable `Work Orders` -…
*: {quality_,}mrp_workorder, quality_mrp_workorder_worksheet
### Steps to reproduce:
- Enable debug mode (to trigger a traceback rather than a silent error)
- In the settings, enable `Work Orders`
- Create an MO for a product without a BoM
- Add an operation to be performed in a workcenter
- Confirm the MO and open the Shop Floor
- Enable the workcenter of your operation, switch to it, and click on the three dots at the bottom right of the operation display
- Click on `Add component` and add any valid component via the catalog
#### > Traceback: `OwlError: Got duplicate key in t-foreach`
### Cause of the issue:
The rendering error is raised by the `MrpDisplayRecord` template: https://github.com/odoo/enterprise/blob/51ce336f8dac9ba0a8ca719201640b2829044164/mrp_workorder/static/src/mrp_display/mrp_display_record.xml#L69-L72
Two moves with the same `id` are provided to the template. Which is unexpected since the `moves` getter should not return the same move twice:
https://github.com/odoo/enterprise/blob/51ce336f8dac9ba0a8ca719201640b2829044164/mrp_workorder/static/src/mrp_display/mrp_display_record.js#L174-L188
However, neither of the two move pools is well defined. The issue stems from the confusing `operation_id` field, which should rather be `workorder_id`. Currently, the moves associated with the MO are those not linked to an `operation_id` (i.e., not linked to an `mrp.routing.workcenter` from the BoM), whereas they should instead be those linked to a `workorder_id`, representing an operation of the MO: https://github.com/odoo/odoo/blob/0d7e3d4c0ea976e37871ca44a10a442cce7caa85/addons/mrp/models/stock_move.py#L43-L47
Similarly, moves linked to workorders are only those matching the same `operation_id` as the workorder. This can only happen when the workorder is generated from the BoM and therefore has a set `operation_id`, or when both are `False`. In the latter case, all moves unlinked to any `operation_id` are displayed on all operations not generated by the BoM, which is again completely unexpected.
In the present case, our operation has not been generated from the bom and hence will fall in both move pulls for the unexpected reason leading to the duplicate key-error.
Community: https://github.com/odoo/odoo/pull/250966
opw-5417887
Forward-Port-Of: odoo/enterprise#106200Code cleanup and technical improvements
This change removes unnecessary redirects from onboarding tours within the HR Contract Salary Payroll module. The previous setup caused wasted time and potential confusion for new users. This refactoring streamlines the onboarding process and improves user efficiency.
Original PR description
The URL key in a tour's JavaScript file implies a redirect to that URL once the browser opens. If this URL is the same as the one used in start_tour() (Python), then it serves no purpose. It's even detrimental because it implies a redirect (and therefore a waste of time). The URL key in the JS file is (for now) only used for onboarding tours. This key will be defined later in the .xml file for onboarding tours. That's why we're removing the URL keys from the registries here.
This update modifies Odoo's templates to align with upcoming OWL3 requirements. Specifically, it adds `.this` to template variables that reference components, ensuring compatibility with the new OWL3 rendering context. This proactive step ensures a smooth transition to the new OWL3 standard.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: https://github.com/odoo/odoo/pull/247965 THIS_TARGETS = ["social"] task: OWL3 prep - add this. to template variables
This update modifies Odoo's template variables to align with the upcoming OWL3 system. Specifically, it adds `.this` to target component variables, a necessary change for OWL3's functionality. This ensures seamless integration and avoids potential issues when transitioning to the new system.
Original PR description
In preparation for OWL3, where template variables will need to use .this to target component variables, we add .this to template variables that are targetting the component. Community PR: https://github.com/odoo/odoo/pull/249848 Script PR: https://github.com/odoo/odoo/pull/247965 task: OWL3 prep - add this. to template variables THIS_TARGETS = ["account", "accountant"] I confirm I have signed the CLA and read the PR guidelines at [www.odoo.com/submit-pr](http://www.odoo.com/submit-pr)
This update simplifies how payslip properties are defined, moving from using IDs to using salary rule codes. This ensures payslips update correctly and prevents future issues with mismatched property definitions. An upgrade script automatically updates existing payslips and rules to align with this new standard.
Original PR description
Refactor payslip properties to user salary rule name instead of ID as a key in the json This includes: - Updating the logic to use salary rule code as a key in the input properties json - Adjust payroll structure to use the code as it will fail to update if the property definition does not match the json - Added a validation for newly added salary rules to follow the code naming convention - Upgrade script to update existing codes in salary rules and previous payslips that are labeled as property_input - Upgrade tests accordingly We change the salary rules that are property inputs and their codes don't follow the alphanumeric regex, currently those would be: ``` - EU.LEAVE.DEDUC - P.P.ADJ - DOUBLE.DECEMBER.BASIC - MOBILITY.PAYMENT - SPECIFIC RULES - SIMPLE.DECEMBER - SSCEMP.1 - N.P.BASIC - ATN.SOCIAL.CONTRIB ``` A condition was also added to validate that the codes of newly added rules follow the convention task-5366999
This update simplifies how Odoo handles chat conversations by removing an outdated method of accessing chat channels. This change streamlines the chat experience and aligns with the latest Odoo features. It ensures more efficient and reliable chat functionality.
Original PR description
This commit removes the last remaining access to the `discuss.channel` model through `getOrFetch` from `mail.thread`. PR community: https://github.com/odoo/odoo/pull/243488
This update modernizes the Enterprise website's search functionality, aligning it with a new, more efficient search architecture introduced in the Community version. It improves the way search results are displayed and ensures seamless integration across various modules like appointment scheduling and knowledge base, ultimately providing a better user experience for finding information.
This update modifies Odoo's template code to align with upcoming OWL3 requirements. Specifically, it adds `.this` to template variables that reference components, ensuring compatibility with the new OWL3 rendering context. This prepares the system for a smoother transition and avoids potential issues with future template development.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: https://github.com/odoo/odoo/pull/247965 THIS_TARGETS = [sign, sms, snailmail] task: OWL3 prep - add this. to template variables
This update prepares our Odoo Enterprise system for OWL3, a new rendering engine. It adds the necessary `.this` syntax to template variables that reference components, ensuring compatibility with the upcoming changes. This ensures a smooth transition and avoids potential issues with future functionality.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targeting the component. Script PR: odoo/odoo#247965 targets: ["product"] impacts: ["planning_field_service_sale_stock", "sale_subscription"] task: OWL3 prep - add this. to template variables
This update prepares our Odoo Enterprise system for OWL3, a new version of our template engine. We've updated template variables to include `.this`, which is now required to correctly reference component variables. This ensures continued compatibility and functionality with the upcoming OWL3 release.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: odoo/odoo#247965 task: OWL3 prep - add this. to template variables
This update prepares Odoo for OWL3, a new rendering system. It adds the `.this` syntax to template variables, which is now required to correctly reference component elements. This ensures compatibility with the upcoming OWL3 changes and avoids potential issues with future template development.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: odoo/odoo#247965 task: OWL3 prep - add this. to template variables
This update prepares the Web Studio module for the upcoming OWL3 release. It adds the `.this` syntax to template variables, which is now required to correctly target component variables within the rendering context. This ensures the Web Studio functionality continues to work seamlessly with the new OWL3 framework.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: #247965 task: OWL3 prep - add this. to template variables
This update prepares Odoo Enterprise for OWL3 by automatically adding '.this' to template variables that reference components. This change is necessary because OWL3 requires this syntax for correctly targeting component variables within templates, ensuring compatibility with the new rendering engine.
Original PR description
*project_enterprise In preparation for OWL3, where template variables will need to use .this to target component variables, we add .this to template variables that are targetting the component. Script PR: #247965 task: OWL3 prep - add this. to template variables
This update prepares Odoo for the upcoming OWL3 rendering system by automatically adding '.this' to template variables. This is necessary because OWL3 requires this syntax to correctly reference component variables within templates. The changes ensure compatibility with the new system and prevent rendering errors.
Original PR description
*web_studio In preparation for OWL3, where template variables will need to use .this to target component variables, we add .this to template variables that are targetting the component. Script PR: #247965 task: OWL3 prep - add this. to template variables
This update modifies Odoo templates to align with upcoming OWL3 requirements. Specifically, it adds `.this` to template variables that reference component data, ensuring compatibility with the new rendering context. This is a preparatory step for a larger OWL3 migration.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: odoo/odoo#247965 task: OWL3 prep - add this. to template variables
This update prepares our Odoo templates for OWL3, a new rendering engine. It adds the `.this` syntax to template variables that reference components, ensuring compatibility with the updated engine's variable targeting method. This is a necessary step to avoid future rendering issues.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: odoo/odoo#247965 task: OWL3 prep - add this. to template variables
This update prepares Odoo for a future upgrade (OWL3) that requires a specific syntax for referencing components within templates. The team has automatically updated template variables in the 'voip' module to include `.this`, ensuring compatibility with the new OWL3 rendering context. This change is a proactive step to avoid issues during the upcoming upgrade.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Script PR: https://github.com/odoo/odoo/pull/247965 THIS_TARGETS = ["voip"] task: OWL3 prep - add this. to template variables
This update modifies Odoo templates to align with upcoming OWL3 requirements. Specifically, it adds `.this` to template variables that reference components, ensuring compatibility with the new variable targeting method. This is a preparatory step for a larger OWL3 migration.
Original PR description
In preparation for OWL3, where template variables will need to use `.this` to target component variables, we add `.this` to template variables that are targetting the component. Community PR: https://github.com/odoo/odoo/pull/252725 Script PR: odoo/odoo#247965 task: OWL3 prep - add this. to template variables