SetBpmProcessSettings

Syntax

bool SetBpmProcessSettings(BpmProcessId tBpmProcess, BpmProcessSettings tBpmProcessSettings)

Parameters

tBpmProcess. Moniker of opened process instance.

tBpmProcessSettings. Settings of parameters that should be applied for process.

Description

The SetBpmProcessSettings operation changes process settings.

Comments

To execute the operation, in the tBpmProcess field specify opened process instance moniker, and in the tBpmProcessSettings field specify changed settings. The moniker can be obtained after executing the OpenBpmProcess operation. The process should be opened for edit.

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

Example

Below is the example of changing a list of parameters in process settings. The request contains moniker of opened process instance and settings of created parameter. The response contains whether the list of parameters is 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">
<SetBpmProcessSettings xmlns="http://www.fsight.ru/PP.SOM.Som">
<tBpmProcess xmlns="">
  <id>PCMPFKDANKDAGOAEHGGCMAILKEKKFDIEKJCJBILJBEBFPLMF!M!S!BPGFFNKBEANKDAGOAEDJNBGLCJMDPBKHHEIKDLOLJJHKCKAIFG</id>
  </tBpmProcess>
<tBpmProcessSettings xmlns="">
<paramsSettings>
<bpmProcessParams>
<it>
  <dictKey>338159</dictKey>
  <dictName>Planning version</dictName>
  </it>
  </bpmProcessParams>
  </paramsSettings>
  </tBpmProcessSettings>
  </SetBpmProcessSettings>
  </s:Body>
  </s:Envelope>

SOAP response:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
  <SetBpmProcessSettingsResult 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</SetBpmProcessSettingsResult>
  </soapenv:Body>
  </soapenv:Envelope>

JSON request:

{
"SetBpmProcessSettings" :
{
"tBpmProcess" :
{
"id" : "PCMPFKDANKDAGOAEHGGCMAILKEKKFDIEKJCJBILJBEBFPLMF!M!S!BPGFFNKBEANKDAGOAEDJNBGLCJMDPBKHHEIKDLOLJJHKCKAIFG"
},
"tBpmProcessSettings" :
{
"paramsSettings" :
{
"bpmProcessParams" :
{
"it" :
{
"dictKey" : "338159",
"dictName" : "Plan scenario"
}
}
}
}
}
}

JSON response:

{
"SetBpmProcessSettingsResult" : "1"
}
public static bool SetBpmProcessSettings(string moniker, BpmProcessParams[] bpmParams)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tSet = new SetBpmProcessSettings()
{
// Create object moniker
tBpmProcess = new BpmProcessId() { id = moniker },
// Parameters
tBpmProcessSettings = new BpmProcessSettings()
{
paramsSettings = new BpmProcessParamsSettings()
{
bpmProcessParams = bpmParams
}
}
};
// Change information about parameters
var result = somClient.SetBpmProcessSettings(tSet);
return result;
}

See also:

Working with Processes