Skip to Content
Menu
This question has been flagged
1 Reply
3675 Views

When calling a function without parametter the context is preserved and can be used

@api.multi
def button_print(self):
_logger.info('Context : %s: ', self.env.context)

Calling this function from a button we get a filled context dictionnary.

But calling the same function with a  defined parametter we get an empty context {}

@api.multi
def button_print(self, demo=False):
_logger.info('Context : %s: ', self.env.context)
Avatar
Discard
Best Answer

Hello, did you find a solution for this issue ?

Avatar
Discard
Related Posts Replies Views Activity
1
Apr 25
3147
3
Apr 17
2673
0
Apr 17
5232
2
Mar 19
3093
0
Oct 15
9511