You can use the validateLine
event in your client script to prevent users from adding lines when certain conditions are met. The function you use simply needs to return a Boolean value: true
if the line addition can continue, false
if it should not.
Similarly, there is a validateDelete
event you can use to prevent line removal when certain conditions are met.
Lastly, and also following a similar pattern, there is a validateField
event you can use to prevent the user from modifying a field value when certain conditions are met. It is not quite disabling the field, but it will prevent them from changing the value.
Adding these event handler functions to your client script should allow you to prevent the changes you desire, though it does not actually disable any of the fields.
You could use jQuery to disable the Add/Copy/Remove buttons and certain fields, but I doubt that NetSuite would consider that a "supported" approach.