singlepageapp
This topic provides information about the available fields for singlepageapp
SDF custom objects.
For information about developing single page applications (SPAs) as part of SDF SuiteApp projects, see Single Page Applications.
For additional information about the SPA object definition file, see Single Page Applications as XML Definitions.
Feature Dependencies
-
SERVERSIDESCRIPTING
Attributes
Name |
Type |
Required / Optional |
Description |
---|---|---|---|
scriptid |
string |
Required |
The ID of the single page application (SPA). Ensure that:
This attribute value can be up to 28 characters long. The default value is ‘custspa’. |
Fields
Name |
Type |
Required / Optional |
Description |
---|---|---|---|
name |
string |
Required |
Name of the SPA. This name is the value that appears in the list of SPAs. This field value can be up to 1000 characters long. |
url |
string |
Required |
Custom part of the URL where the SPA is executed. Ensure that:
This field value can be up to 1000 characters long. |
clientscriptfile |
filereference |
Required |
Location of the SPA client script. This script runs the application in the browser. Ensure that:
This field must reference a .js file. |
serverscriptfile |
filereference |
Required |
Location of the SPA server script. This script runs on the server before the application is served to the browser. Ensure that:
This field must reference a .js file. |
folder |
folderreference |
Required |
Location of the folder that contains all SPA components. Ensure that:
|
description |
string |
Optional |
Description of the SPA. This field value can be up to 1000 characters long. |
assetsfolder |
folderreference |
Optional |
Location of the folder that contains a set of assets (such as style sheets, images, and subfolders). This assets folder is optional and, if available, must be located inside the SPA folder. The assets in this folder are accessible through the SPA asset endpoint Ensure that:
|
audienceallroles |
boolean |
Optional |
Indicates whether all internal roles can run SPA-related scripts. It can be set to T or F. If it is set to T, all internal roles are included in the audience along with any specific external roles listed in If you remove this field, but The default value is F. |
loglevel |
single-select list |
Optional |
Sets the log level. For information about possible values, see script_loglevel. The default value is 'DEBUG'. |
audienceroles |
multi-select list |
Optional |
List of roles that can run the SPA. For example, to list a custom role and the standard developer role, specify: If You can specify multiple values by separating each value with a pipe (|) symbol. This field accepts references to the role custom type. For information about other possible values, see generic_role. |
executeas |
single-select list |
Optional |
Sets the user role used when executing SPA. The default value is 'CURRENT ROLE'. The This field refers to the role used to run the SPA server script. The SPA in the browser will always run based on the role of the currently logged in user. This field accepts references to the role custom type. For information about other possible values, see generic_role. |
usesuif |
boolean |
Optional |
This field must always be set to T. It indicates that NetSuite UIF libraries are used when running SPAs. The default value is T. |
notifyadmins |
boolean |
Optional |
Indicates whether all administrators are notified about errors. Can be set to T or F. The default value is F. |
notifyowner |
boolean |
Optional |
Indicates whether the script owner is notified about errors. Can be set to T or F. The default value is T. |
notifyuser |
boolean |
Optional |
Indicates whether the current user is notified about errors. Can be set to T or F. The default value is F. |
notifyemails |
string |
Optional |
List of email addresses for users that must be notified about errors. Ensure that:
This field value can be up to 999 characters long. |
Structured Fields
Structured fields are elements that usually contain subfields or groups of fields. They are similar to regular fields but have their own embedded structure. The following structured fields are supported: