Choose where you’d like to start

Change Stage

Note: 

  • This task is only applicable to Zoho Creator.

Overview

The thisapp.blueprint.changeStage task lets you change the blueprint stage of a record to a specified stage without performing any transitions in-between.

Note: 

  • This task cannot be performed, if the blueprint is not active in that specified record.
  • The maximum number of blueprint statements that can be executed in one function is 50.
  • Blueprint will be associated only after the event completes for records created using the insert record task. To execute a change stage, you can use make use of schedule workflows.

Syntax

thisapp.blueprint.changeStage(<form_link_name>, <blueprint_link_name>, <stage_link_name>, <recordID>);
                                

where:

ParamsData typeDescription
<form_link_name> TEXT

The link name of the form associated with the blueprint.

Note:

  • Link names of applications, forms, reports, and fields in your account can be viewed on the reference page (listed in brackets).
  • You can also fetch link names from the URL while accessing the form. The URL is in the format: app.zohocreator.com/appbuilder/<application_owner>/<application_name>/#Form:<form_link_name>
<blueprint_link_name> TEXT

The link name of the blueprint in which this task will be performed.

Note: You can get the link name of blueprint under Blueprint properties.
<stage_link_name>TEXTThe link name of the stage to which the transition needs to be made. (The stage link name is the same as stage name)
<recordID> NUMBERThe ID of the record in which this task will be performed.

This task can be used in the following events

When a record is Created
On LoadNo
On ValidateNo
On SuccessYes
On User inputNo
Subform on add rowNo
Subform on delete rowNo
When a record is Created or Edited
On LoadNo
On ValidateNo
On SuccessYes
On User inputNo
Subform on add rowNo
Subform on delete rowNo
When a record is Edited
On LoadNo
On ValidateNo
On SuccessYes
On User inputNo
Subform on add rowNo
Subform on delete rowNo
When a record is Deleted
On ValidateNo
On SuccessYes
Other workflow events
On a scheduled dateYes
During approval processYes
During payment processYes
In a Custom FunctionYes
In an Action item in reportYes

Example 1: Change the stage of the blueprint

The following example changes the stage of the blueprint from the ordered stage to the cancelled stage in an order management form.

thisapp.blueprint.changeStage("orderMangement", "orders", "cancelled", input.ID);
                                

Where:

"orderManagement"
is the TEXT that represents the link name of the form associated with the blueprint.
"orders"
is the TEXT that represents the link name of the blueprint.
"cancelled"
is the TEXT that represents the link name of the stage to which the current stage is being switched.
ID
is the NUMBER that represents the ID of the record in which this task will be executed.
 

Scenario 1

In a courier delivery management system, a package undergoes several processes before delivering to the customer, including packing, shipping, and despatching. These processes will be added as blueprint stages. In some situations, if a customer collects the couriers directly from the delivery office when the package reaches the destination city, the stage Out for delivery should be skipped to delivered by configuring the workflow as a button in the report with this task.

note = "directly picked up at hub by customer"; 
                                thisapp.blueprint.changeStage("courierMangement", "deliveryStatus", "delivered", input.ID);
                                

Related Links

Get Started Now

Execute