跳至内容
菜单
此问题已终结
1 回复
2896 查看

Hi everyone,

Say we have a sale team with access to a view form with a custom button in it.

If one of them login with his own odoo account and click on that button, is there a method to log that it is him that click on that button, a this time, etc ?


Thank you for your help.

形象
丢弃
编写者 最佳答案

Hi everyone,

I found a way.

in the action definition triggered by the button. You can access current user like this:

def test_identifier(self):
_logger.error("TEST LOG USER ID" + self.env.user.name)

I hope this will help
形象
丢弃
相关帖文 回复 查看 活动
1
12月 23
2987
2
10月 23
6173
3
9月 23
3050
0
5月 23
3012
1
5月 23
2361