mirror of
https://github.com/NaN-tic/trytond-sale_opportunity.git
synced 2023-12-14 02:33:08 +01:00
Use _check_access instead of set_user
This commit is contained in:
parent
5dfe663ce1
commit
7dc1b1a192
1 changed files with 1 additions and 1 deletions
2
sale.py
2
sale.py
|
@ -17,7 +17,7 @@ def process_opportunity(func):
|
|||
pool = Pool()
|
||||
Opportunity = pool.get('sale.opportunity')
|
||||
func(cls, sales)
|
||||
with Transaction().set_user(0, set_context=True):
|
||||
with Transaction().set_context(_check_access=False):
|
||||
Opportunity.process([o for s in cls.browse(sales)
|
||||
for o in s.opportunities])
|
||||
return wrapper
|
||||
|
|
Loading…
Reference in a new issue