Friday, September 20, 2024
9 changes · saas-17.4
Resolved issues and error corrections
This update fixes a community-only issue in Italian electronic invoicing tests caused by different payment status values between community and enterprise setups. It now relies on matching document numbers instead of payment status and avoids unnecessary processing for non-Italian companies.
Original PR description
The test "test_account_move_payment_method" was failing in community only because the payment_state is paid if only l10n_it is installed but is in_payment if the enterprise module is installed. We decided to totally remove the if statement on the payment_state. The matching numbers are enough. Also adding some early returns in the compute to make sure we don't do the search on account.move.line for nothing or compute the document type for non italian companies. fw-port of: https://github.com/odoo/odoo/pull/178235 no task-id --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The Point of Sale category menu now keeps child categories in a consistent order when staff navigate between them. This avoids confusing changes in the sales interface and helps cashiers find products more reliably.
Original PR description
Problem:
When clicking on a category with child categories in PoS, the order of the child categories changes unpredictably, leading to inconsistencies.
Steps to reproduce:
- Create PoS categories:
> Parent A category > Child1 A category > Child2 B category
> Parent B category > Child1 B category > Child2 A category
- Open PoS and navigate between categories.
- You'll notice inconsistent ordering when selecting child categories and their subcategories.
opw-4184020
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prCanned reply suggestions now keep more of the reply name visible when both the name and description are too long. This makes it easier for users to identify and choose the right saved response in the chat composer.
Original PR description
Follow-up of https://github.com/odoo/odoo/pull/180438 PR above fixes an issue where the canned reponse was overflowing in chat window when its name is longer than composer width. The fix however introduced problem where description was truncating the name of canned response heavily. The description is usually very long while the name is short, and people tend to find the canned response based on name, so this makes canned response less practical. This commit fixes the issue by forcing description to take up to 20% width when both the name and description overflow. opw-4196113 Before / After <img width="322" alt="Screenshot 2024-09-19 at 17 04 01" src="https://github.com/user-attachments/assets/f74bdd9f-b94e-4887-a033-8eec2cf22aae"> <img width="320" alt="Screenshot 2024-09-19 at 17 04 17" src="https://github.com/user-attachments/assets/0d243371-f6b7-40cd-9d89-97d18d387ab8">
This fix prevents a crash when users try the sample vendor bill flow for a newly created company without the required accounting journal setup. Instead of showing a technical error, Odoo now handles the missing setup consistently and shows a clearer business-facing message.
Original PR description
The error occurs when we click on the button ``try our sample`` by creating a new company. Steps to reproduce: - Install the ``account`` module(without demo data) - Create a new ``Company`` - Go to a newly created company - Invoicing > Vendors > Bills - Click on ``try our sample`` Traceback: ``AttributeError: 'bool' object has no attribute 'id'`` This error occurs at [1], where we are receiving ``default_expense_account`` as False. This commit will resolve the above error by raising an error if no journal exists in that particular company. [1]- https://github.com/odoo/odoo/blob/f80f1a27152c5fc38253fa59d7a24206d5774a6b/addons/account/models/account_journal_dashboard.py#L878 sentry-5722721931 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Users can now save Batch Transfers after removing the Dock Location without encountering an error. This improves reliability for inventory operations using fleet-related stock workflows.
Original PR description
This error occurs when attempting to save a ``Batch Transfer`` without specifying a ``Dock Location``. Steps to reproduce: - Install the ``stock_fleet`` module - Activate ``Storage Locations`` in Configuration of Inventory - Now go to ``Batch Transfers`` in Operations and Create new - Now add ``Dock Location`` and save - Now Remove ``Dock Location`` and save Traceback: ``AttributeError: 'stock.picking.batch' object has no attribute 'location_dest_id'`` The error in [1] occurred because the ``location_dest_id`` field is not part of the ``stock.picking.batch`` model but belongs to the ``stock.picking`` model. This commit resolves the error by adding ``picking_ids``, allowing us to retrieve the ``location_dest_id``. [1]- https://github.com/odoo/odoo/blob/45e75693e8ee4f8cf9af842cd2facd4f2f6356d8/addons/stock_fleet/models/stock_picking_batch.py#L81 sentry-5825702049 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
This fix ensures accounting tests for duplicate payments remain reliable when they run across midnight. It prevents timing-related false failures in automated checks, helping maintain confidence in payment duplicate detection without changing user-facing behavior.
Original PR description
If the payments created in the setUpClass happen Monday at 23:59, and the actual test create duplicate on the following day (at 0:00), it won't be recognized as duplicate. runbot-97948 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The Point of Sale setup flow now skips missing product categories instead of crashing when users open the Clothes onboarding scenario. This helps stores continue configuration even if a default category was previously removed.
Original PR description
Currently, an error occurs when trying to load onboarding clothes. Step to produce: - Install the 'point_of_sale' module. - Go to the point of Sale / Configuration / Products / Pos Product…
Currently, an error occurs when trying to load onboarding clothes.
Step to produce:
- Install the 'point_of_sale' module.
- Go to the point of Sale / Configuration / Products / Pos Product Categories, and Delete the record name 'Upper body'.
- Go to 'Dashboard' to archive all sessions, Click on the 'Clothes' scenario card.
Stack Trace:
```
KeyError: ('ir.model.data', <function IrModelData._xmlid_lookup at 0x7fe08b6ffd80>, 'point_of_sale.pos_category_upper')
File "odoo/tools/cache.py", line 103, in lookup
r = d[key]
File "decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
File "odoo/tools/func.py", line 84, in locked
return func(inst, *args, **kwargs)
File "odoo/tools/lru.py", line 34, in __getitem__
a = self.d[obj]
ValueError: External ID not found in the system: point_of_sale.pos_category_upper
File "odoo/http.py", line 2373, in __call__
response = request._serve_db()
File "odoo/http.py", line 1903, in _serve_db
return self._transactioning(
File "odoo/http.py", line 1966, 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 1933, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2177, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 223, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 754, 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 459, in call_kw
result = getattr(recs, name)(*args, **kwargs)
File "addons/point_of_sale/models/pos_config.py", line 924, in load_onboarding_clothes_scenario
self.env.ref('point_of_sale.pos_category_upper').id,
File "odoo/api.py", line 584, in ref
res_model, res_id = self['ir.model.data']._xmlid_to_res_model_res_id(
File "odoo/addons/base/models/ir_model.py", line 2229, in _xmlid_to_res_model_res_id
return self._xmlid_lookup(xmlid)
File "decorator.py", line 232, in fun
return caller(func, *(extras + args), **kw)
File "odoo/tools/cache.py", line 110, in lookup
value = d[key] = self.method(*args, **kwargs)
File "odoo/addons/base/models/ir_model.py", line 2222, in _xmlid_lookup
raise ValueError('External ID not found in the system: %s' % xmlid)
```
An error occurs when the system tries to retrieve an external ID 'point_of_sale.pos_category_upper' at [1] when opening a 'Clothes' scenario card in POS, but it is not available.
link [1]: https://github.com/odoo/odoo/blob/475459d06dfb81031812fd0d1813d13eb865451f/addons/point_of_sale/models/pos_config.py#L923-L927
To handle this issue, add a method in the pos.config model that filters out unavailable external IDs.
Sentry-5667341424
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prSpanish Facturae e-invoice files now include the product sales description in item descriptions, not just the product name. This restores expected behavior from earlier versions and helps customers send more complete invoice details to recipients.
Original PR description
Steps to reproduce: - Switch to ES company - Products > Sales tab > Add sales description - Invoice that product > Confirm - Send & Print > Tick 'Generate Facturae edi file' - Download the xml facturae file - ItemDescription only contains the product name We expect the ItemDescription to contain the product's sale description as well, which is the behavior of versions 17.2 and prior. The change was introduced in 4f325ef620263c27e095eb49026a677ac617a0ee. opw-4181520 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Corrects an issue in the German reports module where a recently changed database query could return incorrect or unreliable results. This helps ensure DATEV-related partner/reporting data is processed accurately for German accounting workflows.
Original PR description
Fixup of a bad query introduced in https://github.com/odoo/enterprise/commit/63d4ec0e7f57aa8e93f31436e9ac91465c8d1f69 opw-4163804