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 (grafted from 27f9dfa253e48fd885ea54d5b983186d7e829583) --HG-- branch : 6.0
This commit is contained in:
@@ -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