Skip to content
Snippets Groups Projects
Commit 956a0a1c authored by Raphael Collet's avatar Raphael Collet
Browse files

[FIX] base: record count on ir.model defined by query


Models can be defined by an SQL table, an SQL view or an SQL query (with
attribute _table_query).  Counting records makes little sense when the
model does not correspond to a table, and actually fails when it is
defined by an SQL query.

We fix the compute method by counting records only for models where
_auto=True.

closes odoo/odoo#86780

Signed-off-by: default avatarRaphael Collet <rco@odoo.com>
parent 936bad32
Branches
Tags
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment