Modules

filter

 

Objects/Functions

module (N/certificateControl)

SuiteScript 2.0

Certificate.restrictions

// Please search https://system.netsuite.com/app/help/helpcenter.nl?search=Certificate.restrictions for more information.

N/certificateControl Module
Certificate.restrictions
Property Description: The internal IDs of the employees selected in the Restrict to Employees field of the certificate record. If you set this property with an employee internal ID, you check the Restrict to Employees box and select that employee. Employees selected must also have either the Certificate Management or Certificate Access role permission in order to access the certificate. When the Restrict to Employees box is checked, only Administrators and the employees selected can access the certificate.
Type: number[]
Module: N/certificateControl Module
Parent Object: certificateControl.Certificate
Sibling Object Members: Certificate Object Members
Since: 2019.2
Search NetSuite - https://system.netsuite.com/app/help/helpcenter.nl?search=Certificate.restrictions

Example:

// Code Example 1
// Add additional code
//...
//load the certificate record object
var loadedCertificate = cc.loadCertificate({
scriptId : 'custcertificate_testid'
});
//check the Restrict to Employees box and select employees with internal IDs of 189 and 250
loadedCertificate.restrictions = [189,250];
loadedCertificate.save();
//...
// Add additional code

//SOURCE: https://system.netsuite.com/app/help/helpcenter.nl?fid=section_156263396061.html