To enable/disable buttons on PurchTable/SalesTable form, you can customize their respective interaction classes:
Let’s say, for example, I want to enable the Configure line button under Product and Supply menu:
All you need to do is to find and customize the right method which controls the enabling/disabling of the button. In this case it is SalesTableInteractionHelper.parmButtonConfigureLineEnabled():
After compiling, you can see the button enabled!
In the example above, I am returning true without any condition to enable the button. This has been done just for demonstration purpose. You should be controlling the enabling of the button based on any condition that suits your business requirement.