UpdateWorkRequestCustomProperties

Node Action:

The UpdateWorkRequestCustomProperties node action updates the work request resource custom properties.

Parameters:

se_type

UpdateWorkRequestCustomProperties

se_type = UpdateWorkRequestCustomProperties

se_workRequestId

The ID of the work request to update.

se_determineWorkRequestId

A lambda to create a work request ID.

se_determineCustomPropertyEdits

A lambda to create a dictionary of property and values to update. The dictionary structure should be <string,object>.

Example:

Update Work Request Property: The following workflow updates a custom property on a work request resource.

digraph workflow {

entry[
  se_type0 = DesignToolTrigger,
se_deferUntilOnline0 = false,
se_displayName0 = "Update Work Request Property"
se_iconService0 = ""
se_iconUrl0 = ""
se_requiresConnection0 = false,
se_visibilityCondition0 = "(dynamicStateMachineContext, msLogger) => {
  return true;
}",

]

GetCustomProperty[
se_type0 = PromptUser,
se_cardTemplate0 = "
{
    \"type\": \"AdaptiveCard\",
    \"$schema\": \"https://adaptivecards.io/schemas/adaptive-card.json\",
    \"version\": \"1.5\",
    \"body\": [
        {
            \"type\": \"Input.Text\",
            \"label\": \"Name\",
            \"placeholder\": \"Name\",
            \"id\": \"name\"
        },
        {
            \"type\": \"Input.Text\",
            \"label\": \"Value\",
            \"placeholder\": \"Value\",
            \"id\": \"value\"
        }
    ],
    \"actions\": [
        {
            \"type\": \"Action.Submit\",
            \"title\": \"Update\"
        }
    ]
}"

se_promptCaption0 = "Update Design Property"
se_resultVariable0 = Property

]

UpdateCustomProperty[

se_type0 = UpdateWorkRequestCustomProperties,
se_determineCustomPropertyEdits0 = "(ctx, msLogger) => {
  var name = ctx.State.Property.userInputs.name.ToString();
  var value = ctx.State.Property.userInputs.value;
  
  var properties = new Dictionary<string,object>();
  properties.Add(name,value);
  return properties;
}",
se_determineWorkRequestId0 = "(ctx, msLogger) => {
  return ctx.Event.design.id.ToString();
}",

]

entry->GetCustomProperty->UpdateCustomProperty->exit
}
Feedback
QR Code is a registered trademark of DENSO WAVE INCORPORATED in Japan and other countries.