RequestPendingEditsSave
Node Action:
This node action shows a dialogue within ArcGIS Pro prompting the user to save or discard their edits.
Parameters:
se_type
RequestPendingEditsSave
se_type = RequestPendingEditsSave
se_resultVariable
Name of the result variable to store a value representing the user's response to the Save Edits dialogue.
Example:
Stop Editing: This example prompts the user to save pending edits (if any) prior to executing a custom action.
digraph workflow {
entry[
label = "Stop Editing Action Button"
se_type0 = SessionOperationTrigger
se_isPrimaryOperation0 = true,
se_displayName0 = "Stop Editing Workflow",
se_sortOrder0 = 10,
se_showButtonText0 = false,
se_visibilityCondition0 = "(ctx, log) => {
return ctx.Event.assignment.assignedTo == ctx.User.UserId &&
(ctx.Event.isSessionOpen == null || ctx.Event.isSessionOpen == false);
}"
]
requestPendingEditsSave[
label = "Prompt user to save pending edits (if any)"
se_type0 = RequestPendingEditsSave
se_resultVariable0 = "SaveEditsResult"
se_type1 = Action
se_action1 = "(ctx, log) => {
ctx.State.ShouldCancel = ctx.State.SaveEditsResult == \"Canceled\";
}"
]
performAction[
label = "Custom Action"
se_type0 = Action,
se_action0 = "(request, ctx, log) => {
// Define custom action here
}"
]
exit[
shape = invhouse,
color = "#22FF44",
style = filled
]
requestPendingEditsSave->exit[
label = "User canceled"
se_type = Condition
se_condition = "(ctx, log) => ctx.State.ShouldCancel"
]
requestPendingEditsSave->performAction[
se_type = Condition
se_condition = "(ctx, log) => !ctx.State.ShouldCancel"
]
entry->requestPendingEditsSave;
performAction->exit;
}