04.03.26
This commit is contained in:
@@ -2303,6 +2303,23 @@ class SaleReport(CompanyReport):
|
|||||||
with Transaction().set_context(address_with_party=True):
|
with Transaction().set_context(address_with_party=True):
|
||||||
return super(SaleReport, cls).execute(ids, data)
|
return super(SaleReport, cls).execute(ids, data)
|
||||||
|
|
||||||
|
@classmethod
|
||||||
|
def execute(cls, ids, data):
|
||||||
|
pool = Pool()
|
||||||
|
Company = pool.get('company.company')
|
||||||
|
|
||||||
|
company_id = Transaction().context.get('company')
|
||||||
|
if company_id:
|
||||||
|
company = Company(company_id)
|
||||||
|
if company.party.name == 'MELYA':
|
||||||
|
data = dict(data)
|
||||||
|
data['action_id'] = None
|
||||||
|
|
||||||
|
with Transaction().set_context(
|
||||||
|
address_with_party=True,
|
||||||
|
report_company=company_id):
|
||||||
|
return super().execute(ids, data)
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def get_context(cls, records, header, data):
|
def get_context(cls, records, header, data):
|
||||||
pool = Pool()
|
pool = Pool()
|
||||||
|
|||||||
Reference in New Issue
Block a user