Deprecate reduce_ids for SQL_OPERATORS['in']

Closes #12989 #13897
This commit is contained in:
Cédric Krier
2025-12-26 10:57:44 +01:00
parent 7b231e74e9
commit 0da67bce21
46 changed files with 191 additions and 234 deletions
+1 -2
View File
@@ -8,7 +8,6 @@ from trytond.modules.account_budget import (
BudgetLineMixin, BudgetMixin, CopyBudgetMixin, CopyBudgetStartMixin)
from trytond.pool import Pool
from trytond.pyson import Eval
from trytond.tools import reduce_ids
from trytond.transaction import Transaction
from trytond.wizard import Button, StateAction, StateView, Wizard
@@ -179,7 +178,7 @@ class BudgetLine(BudgetLineMixin, ModelSQL, ModelView):
children = cls.__table__()
balance = Sum(Coalesce(line.credit, 0) - Coalesce(line.debit, 0))
red_sql = reduce_ids(table.id, [r.id for r in records])
red_sql = fields.SQL_OPERATORS['in'](table.id, [r.id for r in records])
with Transaction().set_context(context):
query_where = Line.query_get(line)
return (table