0

Set field readonly might fix your issue.
If it's field not button then you can do something like as follow.
I think your requirement seems like that one field is depending upon another field's value.
So either you can manage @api.onchange method or you can manage @api.depends
@api.onchange('f...