Button access for specific user dynamically

Hi, may I know how can I allow button access for only 1 specific user that is chosen by another user?

For example, user A selects user B in Witness field, then only user B would be able to access the button. (Button depending on Witness field)

It seems like buttons doesn’t have button access nor domains to control them dynamically. I also tried ir.model.button.rule but I think I’ve gotten the Condition wrong (I tried using it like domain)

The button rules are just to count the number of user having clicked on the button per record.
There is no standard way to do what you want (personally I do not think it is a good idea because you are blocking the workflow to a unique user) so you will have to implement it completely yourself.

Ohh… did not know about this.

Okay thanks. I’ll try to find other approaches to the requirement then.