Alvaro Fuentes d25b4b020d [FIX] account: fix tuple domain
Domains must be lists on calls to `_where_calc`.
```
 Traceback (most recent call last):
   File "/tmp/tmpjmcn3gby/migrations/base/tests/test_mock_crawl.py", line 162, in crawl_menu
    self.mock_action(action_vals)
   File "/tmp/tmpjmcn3gby/migrations/base/tests/test_mock_crawl.py", line 253, in mock_action
    mock_method(model, view, fields_list, domain, group_by)
   File "/tmp/tmpjmcn3gby/migrations/base/tests/test_mock_crawl.py", line 366, in mock_view_tree
    self.mock_web_read_group(model, view, domain, group_by, fields_list, limit_group=5)
   File "/tmp/tmpjmcn3gby/migrations/base/tests/test_mock_crawl.py", line 442, in mock_web_read_group
    self.mock_web_search_read(model, view, [group["__domain"]], fields_list)
   File "/tmp/tmpjmcn3gby/migrations/base/tests/test_mock_crawl.py", line 402, in mock_web_search_read
    data = model.search_read(domain=domain, fields=fields_list, limit=80)
   File "/home/odoo/src/odoo/14.0/addons/account/models/account_move.py", line 3645, in search_read
    return super(AccountMoveLine, self.with_context(domain_cumulated_balance=to_tuple(domain or []), order_cumulated_balance=order)).search_read(domain, fields, offset, limit, order)
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 4839, in search_read
    result = records.read(fields)
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 3020, in read
    return self._read_format(fnames=fields, load=load)
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 3040, in _read_format
    vals[name] = convert(record[name], record, use_name_get)
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 5666, in __getitem__
    return self._fields[key].__get__(self, type(self))
   File "/home/odoo/src/odoo/14.0/odoo/fields.py", line 1019, in __get__
    self.compute_value(recs)
   File "/home/odoo/src/odoo/14.0/odoo/fields.py", line 1175, in compute_value
    records._compute_field_value(self)
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 4061, in _compute_field_value
    getattr(self, field.compute)()
   File "/home/odoo/src/odoo/14.0/addons/account/models/account_move.py", line 3655, in _compute_cumulated_balance
    query = self._where_calc(self.env.context.get('domain_cumulated_balance'))
   File "/home/odoo/src/odoo/14.0/odoo/models.py", line 4247, in _where_calc
    domain = [(self._active_name, '=', 1)] + domain
 TypeError: can only concatenate list (not "tuple") to list
```

Observed on upgrade request 11722
Ref 9d28c71a71 since saas-13.2

closes odoo/odoo#73522

X-original-commit: e24295da8436b4d24cd03f6ac1f22e86465f950d
Signed-off-by: Christophe Simonis <chs@odoo.com>
2021-07-09 20:50:24 +00:00
2021-07-09 20:50:24 +00:00
2021-06-29 14:41:41 +00:00
…
…
…
…
…

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials

S
Description
No description provided
Readme LGPL-3.0
3.4 GiB
Languages
Python 49.6%
JavaScript 47.8%
SCSS 2%
CSS 0.3%
HTML 0.2%