Submit Link - functionality for cancel button

Hi,

Can we include logic so that when we click cancel, the other local variable logic changes?

a!localVariables(
  local!val:2,
  a!linkField(
    links: {
      a!submitLink(
        label: "Delete Request",
        saveInto: a!save(local!val,local!val+1),
        confirmHeader: "Warning!",
        confirmMessage: "This request will be permanently deleted. Do you want to continue?",
        confirmButtonLabel: "Delete Request",
        confirmButtonStyle: "DESTRUCTIVE",
        cancelButtonLabel: "Cancel"
      )
    }
  )
)

  Discussion posts and replies are publicly visible