Show contents 

Web Service > Web Service Operations > Working with Processes > SetBpmStage

SetBpmStage

Syntax

bool SetBpmStage(BpmProcessId tBpmProcess, BpmStageArg tBpmStepArg)

Parameters

tBpmProcess. Moniker of opened process.

tBpmStepArg. Operation execution parameters.

Description

The SetBpmStage operation changes process stage settings.

Comments

To execute the operation, in the tBpmProcess field specify moniker of opened process, and in the bpmStepArg field specify stage settings. The moniker can be obtained after executing the OpenBpmProcess operation.

The operation results in the logical True if stage settings were changed successfully.

Example

Below is the example of changing process stage settings. The request contains moniker of opened process, GUID, and new name that will be set for the stage. The response contains whether style stage settings were changed successfully.

SOAP request:

<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<SetBpmStage xmlns="http://www.fsight.ru/PP.SOM.Som">
<tBpmProcess xmlns="">
  <id>COAOPGKGCJKEGOAEIHPPEJNABOOGNDGENKOKNINMLFLJFBMK!M!S!BPHLNJFALGCJKEGOAEJPJLLKGPHKELIFIECLCHAGEBCDNFMELP</id>
  </tBpmProcess>
<tBpmStepArg xmlns="">
  <guid>{94C3E46B-1BBC-4FFF-9600-49C6B5D344D7}</guid>
  <name>Additional stage</name>
  </tBpmStepArg>
  </SetBpmStage>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
  <SetBpmStageResult xmlns="http://www.fsight.ru/PP.SOM.Som" xmlns:q1="http://www.fsight.ru/PP.SOM.Som" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1</SetBpmStageResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"SetBpmStage" :
{
"tBpmProcess" :
{
"id" : "COAOPGKGCJKEGOAEIHPPEJNABOOGNDGENKOKNINMLFLJFBMK!M!S!BPHLNJFALGCJKEGOAEJPJLLKGPHKELIFIECLCHAGEBCDNFMELP"
},
"tBpmStepArg" :
{
"guid" : "{94C3E46B-1BBC-4FFF-9600-49C6B5D344D7}",
"name" : "Additional stage"
}
}
}

JSON response:

{
"SetBpmStageResult" : "1"
}
public static bool SetBpmStage(string moniker, string stageGuid, string newName)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tSet = new SetBpmStage()
{
// Create object moniker
tBpmProcess = new BpmProcessId() { id = moniker },
tBpmStepArg = new BpmStageArg()
{
guid = stageGuid,
name = newName
}
};
// Change stage settings
var result = somClient.SetBpmStage(tSet);
return result;
}

See also:

Working with Processes