Skip to Content
Menu
You need to be registered to interact with the community.
This question has been flagged
4072 Prikazi
#Global Variable
context_data = None # contains dictionary

@api.model
def fields_view_get(self, view_id=None, view_type='form', toolbar=False, submenu=False):
res = super(sales_dash_report, self).fields_view_get(
view_id=view_id, view_type=view_type, toolbar=toolbar, submenu=submenu)
global context_copy

if view_type == 'form' and context_copy.get('key'):

#some code to execute

return res


While execute on local machine it executing normal but while try to run on production server then it gives an error that context_data (None object) has no attribute get.

Please help to solve this issue.

Avatar
Opusti
Related Posts Odgovori Prikazi Aktivnost
0
avg. 15
3241
3
jun. 22
14250
4
sep. 16
3391
5
apr. 16
4062
0
maj 15
73