Monday, October 28, 2024
20 changes · 18.0
Resolved issues and error corrections
This fix prevents an error that could occur when the customer credit field is added to an invoice form through Studio. It updates the sales invoice logic to use the current tax total value, keeping customized invoice views from crashing.
Original PR description
Currently, a traceback occurs when the user tries to add the `partner_credit` field to the form view of the `account.move` through the studio. Error:- ``` KeyError: 'amount_total' ``` This error is…
Currently, a traceback occurs when the user tries to add the `partner_credit` field to the form view of the `account.move` through the studio. Error:- ``` KeyError: 'amount_total' ``` This error is occurring because the `amount_total` was removed from the `tax_taotals` from the commit [1]. A major refactor was done to compute the tax_totals from [1] [1] https://github.com/odoo/odoo/commit/d0e7be7832672d476f1b289af52d3a425990d719 We can resolve this issue by taking the `total_amount_currency` from tax_totals Note:- However, the actual problem was the field and the compute method itself. Initially the field `partner_credit` was used for building the warning from [2] [2] https://github.com/odoo/odoo/commit/7bd93cc64b582cdd559a6b6f855c1950a992df68#diff-1e3bd6be3bfb83a37ec9fb800ce8b1c95afe0be90ff792874ae7299c320a2f6eR1383 But later it was removed from the commit [3] [3] https://github.com/odoo/odoo/pull/126575/commits/32954ca0ae54752073c7b5ae46793d1f2e34f0d1#diff-1e3bd6be3bfb83a37ec9fb800ce8b1c95afe0be90ff792874ae7299c320a2f6eL1416 So the field `partner_credit` was neither used in the Python side nor used in the XML side also. which is completely dead code and has never been executed. We should remove both the field and compute method in the master sentry-5987829118
The product demo import templates have been updated so they match the current product fields and sample data. This prevents users from running into errors when using the provided spreadsheet templates and adds a safeguard to keep them valid in future updates.
Original PR description
The demo import templates of the product module were not adapted to recent changes to fields and demo data. This commit makes sure the xls are valid, and adds a test to ensure they are adapted in the future when needed. Fixes #185430
The product import template has been corrected to use the current "Goods" product type instead of the outdated "consumable" value. This prevents import failures when users download the sample template and import it back into Odoo.
Original PR description
before this commit, in the import template of product the type is recorded as consumable, which is no longer valid and when user try to import into system the import will be valid * open import for product * export the import template * import it back, import wont work after this commit, the given sample template is update with Goods instead of consumable --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix updates several help and documentation links so they open the Odoo 18.0 documentation instead of the older 17.0 pages. Users are less likely to land on outdated guidance when looking for product, website link, or localization documentation.
Original PR description
before this commit, many of the url is pointing to 17.0 after this commit, the url will point to 18.0 documentation link Enterprise: https://github.com/odoo/enterprise/pull/72858 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
A small typo in an automated test setup was corrected so invoice-related snail mail tests run reliably again. This helps maintain confidence that sending invoices by post still works for partners who do not have an email address.
Original PR description
Since pr https://github.com/odoo/odoo/commit/9e769e1b11f2 there was a typo, causing tests to break because value of country_id was missing .id at the end. This commit fixes the issue.
Fixes an error that occurred when HR users selected multiple employees and chose “Create a Time Off” from the Presence Control menu. The action now uses the appropriate multi-employee wizard, allowing time off to be created for several employees without a system traceback.
Original PR description
Steps: - Install the hr_presence module - open employee list view - Click on the `Create a Time Off` from Presence Control Menu Description of the issue/feature this PR addresses: In the HR module, When selecting multiple employees from the list view and clicking `Create a Time Off` in the Presence Control menu, a traceback error occurs. Cause: The error is caused by opening the hr.leave form view, which contains the employee_id field that allows the selection of only one employee. Since multiple employees are selected, a singleton error is triggered. Fix: This PR resolves the issue by updating the wizard of the model `hr.leave.generate.multi.wizard`, enabling the creation of time off for multiple employees. task-4207392
Selected course tags now keep their intended colors when learners filter courses, instead of appearing plain until hovered. This makes the course filtering experience clearer and more consistent with the main course listing page.
Original PR description
After this commit https://github.com/odoo/odoo/commit/b4a5bf03cd81ece2a7fd21a3c5a058ee2d3336fe , we have to hover on tags to see solid/bg colors. Here, the selected tag's color is 'primary' but due to hovering behavior, it will display similar to `o_color_0`, unless user hover on the tag. This PR modify selected tags colors to `tag.color` used in 'All courses' page Task-4274049
Fixed an issue that prevented users from downloading payment receipts in certain vendor payment setups. The receipt now uses the correct payment reference information, avoiding an error page and allowing accounting teams to retrieve receipts as expected.
Original PR description
1. Create a new Account called "Outstanding Payment". 2. Create a new Bank Journal and adde the new account in the Outgoing Payment tab. 3. Create a Vendor Bill, add partner details, product, date and confirm. 4. Process the payment using the newly created Bank Journal. 5. Opened the payment record. 6. Attempted to download the payment receipt. Traceback will raise ``` odoo.addons.base.models.ir_qweb.QWebException: Error while render the template KeyError: 'memo' Template: account.report_payment_receipt_document Path: /t/t/div[1]/table/tbody/t/t/tr[2]/td[3]/span Node: <span t-field="payment.move_id.memo"/> ``` It occurs because the field `memo` is defined on the payment and not on the move opw-4280508
This update adjusts several automated website and messaging test flows so they first move over page elements before clicking them. This helps ensure the elements are visible and ready, reducing false test failures without changing customer-facing functionality.
Original PR description
In this commit, we use "hover" action in run to ensure element are visible before clicking on it.[REF] brol 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
Spreadsheet pivots now avoid reloading data when users add or remove computed measures, because those changes do not require fetching data again. This improves responsiveness while still refreshing data when real source measures are added, removed, or changed.
Original PR description
Before this commit, the pivot was reloaded even when the user add or remove a computed measure, which does not require a new data fetch. With this commit, the data is only re-fetched only when the user makes some changes on the measures that require a new data fetch: - Add/remove a non-computed measure - Update the fieldName or aggregator of a non-computed measure Task: 4210672 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 website SEO optimization screen no longer crashes when a blog's name has been removed. This helps website editors continue managing SEO settings reliably even when blog details are incomplete.
Original PR description
Steps to reproduce: --- - Install the ``website_blog`` module - Click on ``Blog`` > Open editor > Click on blog name(eg: Travel) - Remove that blog name and Save Traceback: --- ``TypeErrornormalize() argument 2 must be str, not bool`` This error comes after this commit https://github.com/odoo/odoo/commit/25abac896f53240b08dd38a89110ec811132ee1d Previous Behaviour: --- When trying to open optimize SEO without a blog name at [1] we are getting ``record.display_name`` as false. [1]- https://github.com/odoo/odoo/blob/e4a4806e5c58c599815204a73c78a228ee230613/addons/website/controllers/main.py#L785-L786 sentry-5967410495 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Half-day time off entries now show the correct duration in calendar and Gantt reports instead of being reduced to an incorrect "00 hours" label. This helps HR users read leave schedules accurately when employee names are hidden.
Original PR description
Versions -------- - 18.0+ Steps ----- 1. Create a half-day leave of any type allowing custom hours; 2. open All Time Off in Gantt view. Issue ----- Leave is displayed as "00 hours". Cause ----- PR #177570 changed the way leave hours are displayed, from decimal to HH:MM. With the `hide_employee_name` context value set, the name of `hr.leave.report.calendar` records was computed by splitting on `':'`, and taking the last part. Before the hour formatting change, this was everything after the employee name. After the formatting change, only the "MM" part remains. Solution -------- We can remove the `_fetch_query` override which updates names in cache only, and instead add a `_compute_display_name` override, in turn using the `removeprefix` method added in Python 3.9 to reliably strip the employee name. opw-4274365
This fix prevents an error when a website page title is cleared and the page properties are saved. Users can now save changes without seeing a traceback, improving reliability in the website editor.
Original PR description
When the user tries to save page properties without a Page Title, a traceback will appear. Steps to reproduce the error: - Go to Website > Site > Properties > Remove the Page Title > Save & Close…
When the user tries to save page properties without a Page Title,
a traceback will appear.
Steps to reproduce the error:
- Go to Website > Site > Properties > Remove the Page Title > Save & Close
Traceback:
```
TypeError: normalize() argument 2 must be str, not bool
File "odoo/http.py", line 2364, in __call__
response = request._serve_db()
File "odoo/http.py", line 1891, in _serve_db
return self._transactioning(
File "odoo/http.py", line 1954, in _transactioning
return service_model.retrying(func, env=self.env)
File "odoo/service/model.py", line 137, in retrying
result = func()
File "odoo/http.py", line 1921, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2168, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 330, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 728, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 35, in call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 517, in call_kw
result = getattr(recs, name)(*args, **kwargs)
File "addons/web/models/models.py", line 70, in web_save
self.write(vals)
File "addons/website/models/website_page_properties.py", line 179, in write
write_result = super().write(vals)
File "odoo/models.py", line 4786, in write
fields[0].determine_inverse(real_recs)
File "odoo/fields.py", line 1478, in determine_inverse
determine(self.inverse, records)
File "odoo/fields.py", line 112, in determine
return needle(records, *args)
File "odoo/fields.py", line 724, in _inverse_related
target[field.name] = record_value[record]
File "odoo/models.py", line 7009, in __setitem__
return self._fields[key].__set__(self, value)
File "odoo/fields.py", line 1402, in __set__
records.write({self.name: write_value})
File "addons/website/models/website_page.py", line 158, in write
vals['key'] = self.env['website'].with_context(website_id=website_id).get_unique_key(self.env['ir.http']._slugify(vals['name']))
File "odoo/addons/base/models/ir_http.py", line 161, in _slugify
return cls._slugify_one(value, max_length=max_length)
File "odoo/addons/base/models/ir_http.py", line 154, in _slugify_one
uni = unicodedata.normalize('NFKD', value).encode('ascii', 'ignore').decode('ascii')
```
This error generates after this commit: https://github.com/odoo/odoo/commit/58705803a9e7ef0b0f5ff9e8b82d52ad1321b64a
https://github.com/odoo/odoo/blob/4b99aa4e48158ddc7cea8910c0f610e62778bc9c/addons/website/models/website_page.py#L158
When, user tries to save page properties without a page title,
``vals['name']`` will be False,
So, It will lead to the above traceback.
sentry-5989403584
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prZero-rated supplies under LUT will now appear correctly as exports without payment of tax in the GSTR spreadsheet. This fixes a reporting classification issue caused by unnecessary IGST tags, helping Indian localization tax reports better match expected GST treatment.
Original PR description
In GSTR spreadsheet the zero-rated supplies under lut are shown as `wopay` export type, earlier it was showing as `wpay` due to igst tags being applied on zero-rated lut taxes, that are unnecessary and as we don't need this items for gstr calculations hence igst tags are removed from this taxes. task-4263013
This change prevents an error when users edit and save email-related rich text fields in Safari on iOS, such as email signatures or quotation email subjects. It improves reliability for Safari users by ignoring a browser-unsupported formatting rule that could block saving.
Original PR description
Issue On Safari iOS, editing `html_mail` fields (such as "Email signature" in user profile or "Subject" in Quotation send by mail) throws an error: `@page is not a valid selector` at save. Change Add `@page` to the list of ignored selectors as it was done in commit 7b68c9eaf8ad94ecbcc3893bf6cc220b7e9b6636 as it is currently not supported by all browsers. opw-4256252
Fixes an issue in Manufacturing where clicking a subcontracting line in the bill of materials overview could show an error pop-up. Users can now expand subcontracting details smoothly, reducing interruptions when reviewing production setup.
Original PR description
When the user clicks on a subcontracting line in the BOM overview, an error is raised. This occurs because we are passing false when subcontracting lines are not folded, but a function is expected. The solution is to pass a function, which should be a void function when toggleFolded is false. Steps to Reproduce: 1. Go to the Manufacturing app. 2. Enable the Subcontracting feature in the Settings tab. 3. Navigate to the BoM overview in the Products tab. 4. Open a BoM that includes subcontracting. 5. Click to expand the subcontracting line. Previous Behaviour: An error pop-up appears. Current Behaviour: Opens without any error. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This update prevents project scheduling tests from failing when the HR app is not installed. HR-dependent test coverage is moved to the HR-specific project module, keeping automated checks reliable without changing customer-facing behavior.
Original PR description
## [FIX] project_enterprise: avoid creating employee in test Before this commit, `:TestSmartSchedule.test_multi_users_tasks` test in `project_enterprise` module creates 2 employees but the problem is `hr` module is not in the dependencies of `project_enterprise` and so that test fails when `hr` is not installed. This commit adapts the test to make sure to not create any employees inside that test. ## [FIX] project_enterprise_hr: adds test_smart_schedule test Before this commit, the `test_multi_users_tasks` test defined in `/project_enterprise:TestSmartSchedule` failed when `hr` module is not installed since that test create 2 employees. This commit moves the test in `project_enterprise_hr` to make sure the test works as expected and we can create employee since `hr` is in the dependencies of `project_enterprise_hr` module. runbot-76567
Selecting a document no longer causes the control panel to visually flicker. The selection button now matches the height of neighboring buttons, creating a smoother and more stable experience for users.
Original PR description
Fix the flicker of the control panel when selecting a document. Remove the extra padding that was set around the current selection button so that its height matches the one of the other control panels buttons preventing the flicker. Task-4266281
This fix ensures Belgian payroll group sequence values are properly checked against the allowed maximum length. It prevents invalid sequence data from passing validation, reducing the risk of payroll export errors.
Original PR description
The check for the sequence of the group_s was always true because the length was not compared. Now it is compared to the max length of the sequence. task-4203261
Documentation links across several Odoo Enterprise modules have been corrected to point to the 18.0 documentation instead of the older 17.0 pages. This helps users access the right guidance for their current version and reduces confusion when following help links.
Original PR description
before this commit, many of the url is pointing to 17.0 after this commit, the url will point to 18.0 documentation link