Deduce from credit amount only sales from the user's company
Since #4080 the record rules are no more enforced on getter of Function fields. Closes #12586
This commit is contained in:
1 parent
bace374c3e
commit
ff079187c5
1 file changed
+1
@@ -25,6 +25,7 @@ class Party(metaclass=PoolMeta):
|
||||
currency = user.company.currency
|
||||
|
||||
sales = Sale.search([
|
||||
('company', '=', user.company.id),
|
||||
('party', 'in', [p.id for p in parties]),
|
||||
('state', 'in', ['confirmed', 'processing']),
|
||||
])
|
||||
|
||||
Reference in new issue
Block a user