Client Script

Internal ID: clientscript

Fields

Internal ID Type nlapiSubmitField Label Required Help
description textarea false Description false Description of this script or plug-in implementation.
externalid text false ExternalId false
fieldchangedfunction text false Field Changed Function false Enter the name of the function that will run on Field Changed events. Field Changed events occur whenever a field is changed by the user or by a client side API call. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
isinactive checkbox false Inactive false Sets the current script or plug-in implementation to inactive. When a script is set to inactive, all associated deployments of the script are also inactive. If you wish to inactivate a specific deployment rather than all deployments of this scripts, go to the Script Deployments page.
lineinitfunction text false Line Init Function false Enter the name of the function that will run on Line Init events. These events occur when an existing line is selected. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
name text false Name true The name for the script or plug-in implementation. For scripts, since you may have multiple deployments of a single script, ensure that the name of the script is generic enough to be relevant for all deployments. For example, a single script may be applied to several different record types so it may not make sense to include the record type in the script name.
notifyadmins checkbox false Notify All Admins false If enabled, NetSuite sends an email to all users with the Administrator role whenever an error is thrown.
notifyemails emails false Notify Emails false A comma deliminated list of emails that error notifications should be sent to.
notifygroup select false Notify Group false If enabled, NetSuite send an email to a predefined group whenever an error is thrown. Only existing groups are available in the Groups notification drop-down list. To define new groups, go to Lists > Relationships > Groups.
notifyowner checkbox false Notify Script Owner false If enabled, NetSuite sends an email to the owner of the script whenever an error is thrown.
notifyuser checkbox false Notify Current User false If enabled, NetSuite sends an email to the logged in user of the script whenever an error is thrown.
owner select false Owner false Sets the owner of the script or plug-in implementation. Default is the currently logged in user. Once a script or plug-in implementation is created, only the owner of the script can modify it.
pageinitfunction text false Page Init Function false Enter the name of the function that will run on a Page Init event. Page Init events occur when the page completes loading or when the form is reset. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
postsourcingfunction text false Post Sourcing Function false Enter the name of the function that will run on Post Sourcing events. These events occur following a field change once all the field's child field values are sourced from the server. Enables fieldChange style functionality to occur once all dependent field values have been set. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
recalcfunction text false Recalc Function false Enter the name of the function that will run on Recalc events. These events occur after a line has been successfully added to a sublist. This allows for any global actions that change whenever the contents of the sublist change such as recalculation of item totals on a transaction. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
saverecordfunction text false Save Record Function false Enter the name of the function that will run on a Save Record event. Save Record events occur prior to submitting the form when the user tries to save any changes (clicking the Save button). Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
scriptfile select false Script File true Defines the JavaScript file that contains your desired scripts or plug-in implementation script file. You must first upload the file in the SuiteScripts folder in the File Cabinet. To upload your file, click the New icon when in Edit mode.
scriptid identifier false ID false If desired, enter a custom internal ID for the script record, script deployment, or plug-in implementation. If this field is left blank, a system-generated script ID will be created for you. Whether creating a custom ID or accepting a system-generated ID, once the script record or plug-in implementation is saved, the system automatically prepends customscript to the ID. If a custom ID is created for a script deployment, customdeploy is appended to the front of the deployment ID. (For example, a custom script deployment ID called employeeupdates will be called customdeployemployeeupdates once the script record is saved.) Custom IDs are recommended if you plan to bundle the script and deploy it into another NetSuite account. Custom IDs reduce the risk of naming conflicts when deployed into other accounts. Although not recommended, you can edit your custom ID once the record is saved. To do so, click the Change ID button on the Script Record, Script Deployment, or Plug-in Implementation pages. Note: Custom IDs must be in lower case and contain no spaces.
scripttype select false Type false Lists the type of SuiteScript (Suitelet, RESTlet, User Event, Scheduled, Map/Reduce, Client, Portlet, Mass Update, Workflow Action, Bundle Installation) or plug-in implementation. Note: Client SuiteScripts in this context are record-level client scripts. These scripts must be deployed and you must specify the record(s) they will run against.
validatedeletefunction text false Validate Delete Function false The validateDelete event occurs when you try to remove an existing line from an edit sublist. Returning false blocks the removal. (For information on the edit sublist type, see Editor Sublists in the NetSuite Help Center.)
validatefieldfunction text false Validate Field Function false Enter the name of the function that will run on a Validate Field event. Validate Field events occur whenever a field is about to be changed by the user or by a client side API call. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.
validateinsertfunction text false Validate Insert Function false The validateInsert event occurs when you insert a line into an edit sublist. For information on the edit sublist type, see Editor Sublists in the NetSuite Help Center. The UI equivalent of this event is when a user selects an existing line in a sublist and then clicks the Insert button. In SuiteScript, the equivalent action is calling nlobjRecord.insertLineItem(...). Note that returning false on a validateInsert blocks the insert.
validatelinefunction text false Validate Line Function false Enter the name of the function that will run on Validate Line events. These events occur prior to a line item being added to a sublist. Note: When entering the function name, do not include parentheses or arguments. For example, type sampleFunction for a function that appears as sampleFunction(arg1) in your JavaScript file.

Tabs

Name Label
errorhandling Unhandled Errors
executionlog Execution Log
historytab History
scriptdeployments Deployments
scripts Scripts
tab_parameters Parameters

Search Joins

Join ID Join Description Actual Join Name
user User Employee

Search Filters

Internal ID Type Label
afterinstallfunction text After Install Function
aftersubmitfunction text After Submit Function
afterupdatefunction text After Update Function
beforeinstallfunction text Before Install Function
beforeloadfunction text Before Load Function
beforesubmitfunction text Before Submit Function
beforeuninstallfunction text Before Uninstall Function
beforeupdatefunction text Before Update Function
defaultfunction text Default Function
deletefunction text Delete Function
description textarea Details
fieldchangedfunction text Field Changed Function
formuladate date Formula (Date)
formulanumeric float Formula (Numeric)
formulatext text Formula (Text)
getfunction text Get Function
internalid select Internal ID
internalidnumber integer Internal ID (Number)
isinactive checkbox Inactive
lineinitfunction text Line Init Function
name text Name
owner select Owner
pageinitfunction text Page Init Function
portlettype select Portlet Type
postfunction text Post Function
postsourcingfunction text Post Sourcing Function
putfunction text Put Function
recalcfunction text Recalc Function
saverecordfunction text Save Record Function
scriptfile select Script File
scriptid text Script ID
scripttype select Script Type
validatedeletefunction text Validate Delete Function
validatefieldfunction text Validate Field Function
validateinsertfunction text Validate Insert Function
validatelinefunction text Validate Line Function

Search Columns

Internal ID Type Label
afterinstallfunction text After Install Function
aftersubmitfunction text After Submit Function
afterupdatefunction text After Update Function
beforeinstallfunction text Before Install Function
beforeloadfunction text Before Load Function
beforesubmitfunction text Before Submit Function
beforeuninstallfunction text Before Uninstall Function
beforeupdatefunction text Before Update Function
defaultfunction text Default Function
deletefunction text DELETE Function
description text Description
fieldchangedfunction text Field Changed Function
formulacurrency currency Formula (Currency)
formuladate date Formula (Date)
formuladatetime datetime Formula (Date/Time)
formulanumeric float Formula (Numeric)
formulapercent percent Formula (Percent)
formulatext text Formula (Text)
getfunction text GET Function
internalid select Internal ID
isinactive checkbox Inactive
lineinitfunction text Line Init Function
name text Name
owner select Owner
pageinitfunction text Page Init Function
postfunction text POST Function
postsourcingfunction text Post Sourcing Function
putfunction text PUT Function
recalcfunction text Recalc Function
saverecordfunction text Save Record Function
scriptfile select Script File
scriptid text Script ID
scripttype select Script Type
validatedeletefunction text Validate Delete Function
validatefieldfunction text Validate Field Function
validateinsertfunction text Validate Insert Function
validatelinefunction text Validate Line Function