# Class WorkflowStep

#### Hierarchy

- WorkflowStep

- Defined in saltcorn-data/models/workflow_step.ts:27

#####
Index

### Constructors

constructor

### Properties

action_name
configuration
id?
initial_step
name
next_step?
only_if?
trigger_id

### Accessors

mmname
mmnext
toJson

### Methods

delete
run
update
builtInActionConfigFields
builtInActionExplainers
create
deleteForTrigger
find
findOne
generate_diagram
getDiagramLoopLinkBacks
mmescape

## Constructors

### constructor

- new WorkflowStep(o): WorkflowStep

- WorkflowStep constructor

  #### Parameters

  - ##### o: WorkflowStep | WorkflowStepCfg

  #### Returns WorkflowStep

  - Defined in saltcorn-data/models/workflow_step.ts:41

## Properties

### action_name

action_name: string

- Defined in saltcorn-data/models/workflow_step.ts:33

### configuration

configuration: any

- Defined in saltcorn-data/models/workflow_step.ts:35

### `Optional` id

id?: number

- Defined in saltcorn-data/models/workflow_step.ts:28

### initial_step

initial_step: boolean

- Defined in saltcorn-data/models/workflow_step.ts:34

### name

name: string

- Defined in saltcorn-data/models/workflow_step.ts:29

### `Optional` next_step

next_step?: string

- Defined in saltcorn-data/models/workflow_step.ts:31

### `Optional` only_if

only_if?: string

- Defined in saltcorn-data/models/workflow_step.ts:32

### trigger_id

trigger_id: number

- Defined in saltcorn-data/models/workflow_step.ts:30

## Accessors

### mmname

- get mmname(): string

- #### Returns string

  - Defined in saltcorn-data/models/workflow_step.ts:60

### mmnext

- get mmnext(): undefined | string

- #### Returns undefined | string

  - Defined in saltcorn-data/models/workflow_step.ts:65

### toJson

- get toJson(): any

- #### Returns any

  - Defined in saltcorn-data/models/workflow_step.ts:91

## Methods

### delete

- delete(connect_prev_next?): Promise<void>

- #### Parameters

  - ##### connect_prev_next: boolean = false

  #### Returns Promise<void>

  - Defined in saltcorn-data/models/workflow_step.ts:125

### run

- run(context, user): Promise<any>

- #### Parameters

  - ##### context: any

  - ##### user: User

  #### Returns Promise<any>

  - Defined in saltcorn-data/models/workflow_step.ts:207

### update

- update(row): Promise<void>

- #### Parameters

  - ##### row: Row

  #### Returns Promise<void>

  - Defined in saltcorn-data/models/workflow_step.ts:193

### `Static` builtInActionConfigFields

- builtInActionConfigFields(opts?): Promise<(FieldRepeat | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: {
  options: string[];
  };
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: {
  options: string[];
  };
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel?: undefined;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default: string;
  fieldview: string;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview: string;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg: boolean;
  wf_action_name: string;
  };
  sublabel?: undefined;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default: string;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: undefined | {
  options: string[];
  };
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  } | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  })[]>

- #### Parameters

  - ##### opts: any = {}

  #### Returns Promise<(FieldRepeat | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: {
  options: string[];
  };
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: {
  options: string[];
  };
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel?: undefined;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default: string;
  fieldview: string;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview: string;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class?: undefined;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required?: undefined;
  showIf: {
  immediately_bg: boolean;
  wf_action_name: string;
  };
  sublabel?: undefined;
  type: string;
  validator?: undefined;
  } | {
  attributes?: undefined;
  class: string;
  default: string;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator?: undefined;
  } | {
  attributes: undefined | {
  options: string[];
  };
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  } | {
  attributes?: undefined;
  class: string;
  default?: undefined;
  fieldview?: undefined;
  label: string;
  name: string;
  required: boolean;
  showIf: {
  immediately_bg?: undefined;
  wf_action_name: string;
  };
  sublabel: string;
  type: string;
  validator: any;
  })[]>

  - Defined in saltcorn-data/models/workflow_step.ts:428

### `Static` builtInActionExplainers

- builtInActionExplainers(opts?): any

- #### Parameters

  - ##### opts: any = {}

  #### Returns any

  - Defined in saltcorn-data/models/workflow_step.ts:399

### `Static` create

- create(step_in): Promise<WorkflowStep>

- #### Parameters

  - ##### step_in: WorkflowStepCfg

  #### Returns Promise<WorkflowStep>

  - Defined in saltcorn-data/models/workflow_step.ts:74

### `Static` deleteForTrigger

- deleteForTrigger(trigger_id): Promise<void>

- #### Parameters

  - ##### trigger_id: number

  #### Returns Promise<void>

  - Defined in saltcorn-data/models/workflow_step.ts:181

### `Static` find

- find(where, selectopts?): Promise<WorkflowStep[]>

- #### Parameters

  - ##### where: Where

  - ##### `Optional` selectopts: SelectOptions

  #### Returns Promise<WorkflowStep[]>

  - Defined in saltcorn-data/models/workflow_step.ts:101

### `Static` findOne

- findOne(where): Promise<WorkflowStep>

- #### Parameters

  - ##### where: Where

  #### Returns Promise<WorkflowStep>

  - Defined in saltcorn-data/models/workflow_step.ts:113

### `Static` generate_diagram

- generate_diagram(steps, options?): string

- #### Parameters

  - ##### steps: WorkflowStep[]

  - ##### options: {} = {}

  #### Returns string

  - Defined in saltcorn-data/models/workflow_step.ts:317

### `Static` getDiagramLoopLinkBacks

- getDiagramLoopLinkBacks(steps): Record<string, string>

- #### Parameters

  - ##### steps: WorkflowStep[]

  #### Returns Record<string, string>

  - Defined in saltcorn-data/models/workflow_step.ts:296

### `Static` mmescape

- mmescape(s): string

- #### Parameters

  - ##### s: string

  #### Returns string

  - Defined in saltcorn-data/models/workflow_step.ts:55

Generated using TypeDoc