Setting the class column in item sub list as mandatory from Company preferences through script

User may set the Class Field to mandatory by ticking the Make Classes Mandatory field on Setup Accounting Accounting Preferences General tab. This can also be done via SuiteScript.

var accountingPref = config.load({‌
type: config.Type.ACCOUNTING_PREFERENCES
});

accountingPref.setValue({‌
fieldId: ‘CLASSMANDATORY’,
value: true
});

accountingPref.save();

Leave a comment

Your email address will not be published. Required fields are marked *