Daily updates from Odoo
Thursday, June 6, 2024
12 changes
1 change
Resolved issues and error corrections
This fix keeps automated web tours from stopping unexpectedly when an optional page element is not found. It restores more forgiving behavior, helping internal testing and guided flows run more reliably.
Original PR description
This commit [1] introduces `queryOne` to find element nodes in DOM. But, if `queryOne` fails to find the element it throws error which breaks the tour which wasn't the case before this change was introduced. There might be some scenarios where it might not affect if the node is found or not, but because of `queryOne` the tour will fail. So, to fix this we use `queryFirst` which doesn't throw error if it fails to find the node. 1: c0f3bdb928db5a119817710e260edfda9a2f40ac --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
1 change
Resolved issues and error corrections
UPS package types are now renamed so users can clearly tell the standard UPS carrier option apart from the legacy UPS option when grouping by carrier. This reduces confusion during package type selection and helps teams choose the correct UPS configuration.
Original PR description
Steps to reproduce: - open package type and group by carrier - No way to distinguish rest and legacy ups Fix: rename package type to match carrier and distinguish it from rest ups opw-3911171
10 changes
Resolved issues and error corrections
This fix restores the "Generate Payslips" and "Regenerate Work Entries" buttons that were accidentally hidden in the Payroll work entry view. The buttons disappeared due to a technical issue where system updates were overwriting custom button configurations. This fix ensures users can access these important payroll functions again.
Original PR description
Versions -------- - 17.0 - saas-17.1 - saas-17.2 Issue ----- From Payroll work entry view, the "Generate Payslips" and "Regenerate Work Entries" buttons have gone missing. Cause ----- In commit 4134ed00f6f I added a registry workaround in order to not modify the manifest. When `hr_gantt` gets added, the `workEntriesGanttView` gets updated to its value, but this overwrote the additions from `hr_work_entry_contract_enterprise` itself. Solution -------- Re-include the `Controller`, `Model` and `buttonTemplate` values when updating the registry. opw-3969616
This fix corrects how the system matches bank transactions to sales orders when partial payments have been made. Previously, when a bank transaction referenced a sales order, the system would incorrectly try to match it against the remaining invoice balance instead of the actual payment amount, creating confusion about duplicate payments. Now the system properly recognizes existing payments first before attempting invoice reconciliation.
Original PR description
Before, if a bank transaction contain the sale order reference, the reconciliation model will try to reconcile with the invoices created from this sale order but ignore the payment records for those. This leads to situations where it looks like there were two payments on the invoices (one payment record and one bank transaction) while there is just one partial payment. Steps to reproduce: 0/ Have default reconciliation models 1/ Create SO for 100$ and confirm invoice 2/ Partially pay invoice for 70$ 3/ Create bank transaction with SO ref and same partner for 70$ 4/ Match transaction => will match the 30$ residual of the invoice instead of 70$ payment Now, the system will try to reconcile with the payments of those invoices first before considering invoice reconciliation. opw-3904177 Forward-Port-Of: odoo/enterprise#62972
The Paid Time Off Allocation wizard in the Belgian Payroll module was crashing when users selected a department and then a time off type. This fix corrects a problematic database query that was causing the error, and also removes unnecessary subqueries to improve performance.
Original PR description
In the Payroll app with a Belgian company, we can do Reporting > Paid Time Off Allocation. This opens a wizard and if we filled the department then the time off type, the app would crash because of a terrible sql query. Also, the query was doing unnecessary subqueries that have been removed. Task: 3878904 Forward-Port-Of: odoo/enterprise#62293
This fix resolves a system error that occurred when users tried to create invoices for refunded Point of Sale orders in Mexico. The issue was caused by missing data being concatenated with text, which has now been corrected. Users can now successfully process refunds and generate invoices without encountering errors.
Original PR description
When a user tries to validate an invoice of the refunded order a traceback will occur. Steps to produce: - Install 'l10n_mx_edi_pos' module. - Switch to a company whose country code is 'MX'(Mexico).…
When a user tries to validate an invoice of the refunded order a traceback will occur.
Steps to produce:
- Install 'l10n_mx_edi_pos' module.
- Switch to a company whose country code is 'MX'(Mexico).
- Open 'Point of Sale' and New Session.
- Select any products > payment > Select payment method > Invoice > Select customer > Validate.
- Click on 'Next Order'.
- Click on 'Refund and select your order.
- Click on refund > payment > Select payment method > Invoice > Validate.
- Error will be generated.
Traceback on sentry:
```
TypeError: can only concatenate str (not "bool") to str
File "odoo/http.py", line 2252, in __call__
response = request._serve_db()
File "odoo/http.py", line 1828, in _serve_db
return self._transactioning(_serve_ir_http, readonly=ro)
File "odoo/http.py", line 1848, in _transactioning
return service_model.retrying(func, env=self.env)
File "odoo/service/model.py", line 134, in retrying
result = func()
File "odoo/http.py", line 1826, in _serve_ir_http
return self._serve_ir_http(rule, args)
File "odoo/http.py", line 1833, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2058, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 222, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 740, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 42, in call_button
action = self._call_kw(model, method, args, kwargs)
File "addons/web/controllers/dataset.py", line 34, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 458, in call_kw
result = getattr(recs, name)(*args, **kwargs)
File "home/odoo/src/enterprise/saas-17.1/l10n_mx_edi_pos/models/pos_order.py", line 108, in action_pos_order_invoice
action_values = super().action_pos_order_invoice()
File "addons/point_of_sale/models/pos_order.py", line 856, in action_pos_order_invoice
res = self._generate_pos_order_invoice()
File "addons/point_of_sale/models/pos_order.py", line 873, in _generate_pos_order_invoice
move_vals = order._prepare_invoice_vals()
File "addons/pos_sale/models/pos_order.py", line 32, in _prepare_invoice_vals
invoice_vals = super(PosOrder, self)._prepare_invoice_vals()
File "home/odoo/src/enterprise/saas-17.1/l10n_mx_edi_pos/models/pos_order.py", line 150, in _prepare_invoice_vals
vals['l10n_mx_edi_cfdi_origin'] = '03|' + self.refunded_order_id.account_move.l10n_mx_edi_cfdi_uuid
```
This is because 'l10n_mx_edi_cfdi_uuid' is empty at [1] and a string concatenate with it.
link [1]: https://github.com/odoo/enterprise/blob/1502f8b3e519d41f4a58e2acc846f315f6f5eeda/l10n_mx_edi_pos/models/pos_order.py#L150
This commit solves the above issue while checking the existence of
'l10n_mx_edi_cfdi_uuid' while creating the invoice for refund_order
sentry-4935781389
Forward-Port-Of: odoo/enterprise#59873This update fixes a crash in the Belgian financial reports module that occurred when processing partners with missing or invalid VAT numbers. The system now gracefully handles these edge cases instead of failing, ensuring smoother report generation for all partner records regardless of VAT data completeness.
Original PR description
The aim of this commit is to make the code more robust and defensive by handling a bad value for the `vat` field. Context: Partners having a `partner.vat=False` were making the compact function crash. Before the commit: The flow crash even if the value shouldn't be processed. After the commit: The flow is smooth. task-id: None Forward-Port-Of: odoo/enterprise#63865
This fix resolves an issue where spreadsheet files were incorrectly identified when WPS Office is installed on a computer. WPS Office changes how the system recognizes Excel files, causing them to be misidentified. The update ensures that spreadsheet documents are properly recognized regardless of whether WPS Office is present on the system.
Original PR description
On computers where WPS office is installed, the mimetype of office files (eg. .docx, .xslx) the mimetype recognition is altered (at least on linux machines [^1][^2]). The detection of xlsx files in Documents did not account for the specific mimetype set by WPS Office. [^1]: https://forum.puppylinux.com/viewtopic.php?t=2379&i=1 [^2]: https://askubuntu.com/questions/1360278/wps-office-messing-up-mime-types-associated-with-office-documents Task-3915912 Forward-Port-Of: odoo/enterprise#63719 Forward-Port-Of: odoo/enterprise#62100
This fix resolves an issue where the kitchen preparation display was not showing all items when a product was ordered multiple times with internal notes added. Previously, duplicate items with notes would not appear correctly on the display, causing kitchen staff to miss orders. Now all items display properly regardless of whether notes are attached.
Original PR description
Current behavior: When you add a product with an internal note to an order the preparation display is not updated correctly. Steps to reproduce: - Open PoS restaurant session - Add product A, and press Order button - Add product A, add an internal note, and press Order button - Go on the preparation display, there is only one product A opw-3902869
This update removes unnecessary error messages that were appearing during automated tests for the room booking feature. The tests were trying to load background images for test rooms that don't actually exist, causing false error alerts. The fix cleans up these test errors without affecting how the feature works for real users.
Original PR description
Purpose: -------- The frontend room view uses the "background-image" property to add a background image if one has been set on the room. This causes several 404 errors in qunit tests because the test room does not exist, resulting in a "room not found" exception when the browser tries to get the background image. This commit patches the view in the tests to remove the url part of the background-image property, so that the background image is not fetched anymore. In order to make this patch possible, the background-image property value has been moved inside a getter. Task-3943099
This fix corrects how batch payments calculate the total amount when payments are in different currencies. Previously, the system was not properly converting individual payment amounts to the company's base currency before summing them, resulting in incorrect batch totals. Now batch payments will display the correct total amount regardless of the currencies involved.
Original PR description
Steps to reproduce: - Go to Accounting > Vendor > Payments. - Create one "Send" payment for 500 USD to Abigail Peterson and confirm. - Create one "Send" payment for 500 EUR to Abigail Peterson and confirm. - Go to Accounting > Vendor > Batch Payments. - Create a new batch payment and add the two payments. - Print the batch payment (either Print button or Action > Print Batch Payment) Issue: The sum amount in company currency is not correct Cause: We do not convert the line amount (and we apparently don't want to use the payment amount for reconciliation) opw-3911484 Forward-Port-Of: odoo/enterprise#63857 Forward-Port-Of: odoo/enterprise#62553
This update corrects the spacing around percentage symbols displayed in the planning calendar event popover. When users click on calendar events to view details, the percentage indicator now displays with consistent, proper spacing for a more polished appearance.
Original PR description
Steps to reproduce: 1. Install the planning module and open it. 2. Open events in calendar view. 3. Click on any event. 4. In the calendar popover, observe the spacing around the percentage (%). Issue: There is inconsistency in spacing around the percentage (%). Solution: Add a space before the percentage and remove the space after it in the common calendar popover. task-3908815 Forward-Port-Of: odoo/enterprise#62083