Home Reference Source Repository
import Workflow from 'rodan-client/js/Models/Workflow.js'
public class | source

Workflow

Extends:

backbone~Backbone.ModelBaseModel → Workflow

Workflow.

Method Summary

Public Methods
public

Returns defaults.

public

initialize(options: object)

Initialize

public

parse(response: object): object

Override of Backbone.Model.parse.

Inherited Summary

From class BaseModel
public

destroy(options: object)

Override of destroy to allow for generic handling.

public

fetch(options: object)

Override of fetch to allow for generic handling.

public

Returns descriptive string for model.

public

Parses ID out of resource type URL.

public

save(attributes: object, options: object): *

Override of save to allow for generic handling.

public

url(): string

URL override to add trailing slash.

Public Methods

public defaults(): object source

Returns defaults.

Return:

object

object holding default values

public initialize(options: object) source

Initialize

Params:

NameTypeAttributeDescription
options object

Backbone.Model options object; 'options.connections' (ConnectionCollection or associated Backbone.Collection raw-object representation), 'options.workflow_input_ports' (InputPortCollection or associated Backbone.Collection raw-object representation), 'options.workflow_output_ports' (OutputPortCollection or associated Backbone.Collection raw-object representation), 'options.workflow_jobs' (WorkflowJobCollection or associated Backbone.Collection raw-object representation), and 'options.workflow_runs' (WorkflowRunCollection or associated Backbone.Collection raw-object representation) must also be provided

public parse(response: object): object source

Override of Backbone.Model.parse. This will populate 'workflow_runs', 'workflow_jobs', 'workflow_input_ports', and 'workflow_output_ports' with the appropriate models.

Params:

NameTypeAttributeDescription
response object

JSON response from server

Return:

object

response object