Initializing help system before first use

Project

Information about a project, its members and the model's schema.
Example
// to fetch the current Project
var entity = insight
     .getView()
     .getProject();

Method summary

name description
createAttachment Create a new project attachment.
createFolder Create a new folder as a child of parent.
createScenario Create a new scenario inside the current project.
getAttachmentTagNames Get the list of attachment tag names defined by the project.
getAttachmentTags Get the list of attachment tags defined by the project.
getExecutionModes Returns the project's execution modes, indexed by name
getId The project's id.
getModelSchema The schema of the model used by this project.
getName The name of this project.
getUsers Get a list of users associated with the project.

Methods

method
createAttachment ( options ) → {Promise}

Create a new project attachment.

Parameters:
params
Name Type Argument Description
options
type
NewAttachmentOptions
optional 
details
Returns:
returns table
Type Description
type
Promise
Resolves when user closes the editor or if attachment create fails
Example
examples
project.createAttachment({filename: 'my_file.xml', tag: 'atag'})
       .then(function(data) {
           console.log(data.attachment);
       });
Back to Top
method
createFolder ( parent, name ) → {Promise.<Object>}
Parameters:
params
Name Type Argument Description
parent
type
Folder
optional  the parent node to create the folder on
name
type
string
the name of the folder to create
details
Returns:
returns table
Type Description
type
Promise.<Object>
Example
examples
// creates a new folder on a specified parent
project.createFolder(parentObj, 'my new folder');

// creates a new folder on the current project
project.createFolder('my new folder');
Back to Top
method
createScenario ( parent, name, type ) → {Promise.<Object>}
Parameters:
params
Name Type Argument Description
parent
type
Folder | Project
optional  the parent node to create the scenario on
name
type
string
the name of the scenario to create
type
type
string
optional  the type of scenario to create
details
Returns:
returns table
Type Description
type
Promise.<Object>
Example
examples
project.createScenario(parentObj, 'my new scenario', null);
Back to Top
method
getAttachmentTagNames ( ) → {Promise.<Array.<string>>}

Get the list of attachment tag names defined by the project.

details
Returns:
returns table
Type Description
type
Promise.<Array.<string>>
Promise containing an array of strings or an empty array if no attachment tag names found.
Example
examples
var attachmentTagNames = project.getAttachmentTagNames();
Back to Top
method
getAttachmentTags ( ) → {Promise.<Array.<AttachmentTag>>}

Get the list of attachment tags defined by the project.

details
Returns:
returns table
Type Description
type
Promise.<Array.<AttachmentTag>>
Promise containing an array of AttachmentTag objects or an empty array if no attachment tags found.
Example
examples
var attachmentTags = project.getAttachmentTags();
Back to Top
method
getExecutionModes ( ) → {Object.<string, ExecutionMode>}

Returns the project's execution modes, indexed by name

details
Returns:
returns table
Type Description
type
Object.<string, ExecutionMode>
Back to Top
method
getId ( ) → {string}

The project's id.

details
Returns:
returns table
Type Description
type
string
The project's Id
Example
examples
var id = project.getId();
Back to Top
method
getModelSchema ( ) → {ModelSchema}

The schema of the model used by this project.

details
Returns:
returns table
Type Description
type
ModelSchema
The schema of the model used by this project
Example
examples
var modelSchema = project.getModelSchema();
Back to Top
method
getName ( ) → {string}

The name of this project.

details
Returns:
returns table
Type Description
type
string
The name of this project
Example
examples
var name = project.getName();
Back to Top
method
getUsers ( options ) → {Promise.<Array.<User>>}

Get a list of users associated with the project. Optionally filter the result by a custom authority.

Parameters:
params
Name Type Argument Description
options
type
object
optional  fetch parameters and asynchronous callbacks
Properties
params
Name Type Argument Description
authorityFilter
type
string
optional  custom authority to filter user list by
details
Returns:
returns table
Type Description
type
Promise.<Array.<User>>
Promise containing an array of User objects or an empty array if no items found. The array elements will be ordered alphanumerically by username. The User objects will only contain custom authorities. Also the User object will not contain any authority groups.
Example
examples
var usersList = project.getUsers();
Back to Top

© 2001-2019 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.