Convert submitLink that start a process to a process model

I am trying configure a related action to be nearly identical to how a a!submitLink works in the below code snippet. I need to reference a process model to configure a related action that can be setup like to my previous implementation of the a!submitLink logic. I am having a hard time determining if I can do what I need to do with a process model that would be the a!submitLink that allows for user confirmation of the action or cancel the action. See the code snippet below. Is it possible to convert this submitLink to a process model? If I am missing the documentation that documents the way to covert this a!submitLink into a process model instantiation/implementation, please let me know. Thanks!

a!localVariables(
  a!cardLayout(
    contents: a!richTextDisplayField(
      value: {
        a!richTextItem(
          text: { "Rescind Case" },
          size: "MEDIUM",
          style: "STRONG"
        )
      },
      align: "CENTER"
    ),
    link: a!submitLink(
      label: "Rescind Case",
      saveInto: {
        a!startProcess(
          processModel: cons!UWM_CASE_STATUS_UPDATE_PROCESS,
          processParameters: {
            caseId: ri!case.caseId,
            caseUpdate: {
              status: "RESCIND",
            }
          },
          onSuccess: a!save(
            ri!case.status,
            "RESCIND"
          )
        )
      },
      confirmHeader: "Attention",
      confirmMessage: "This transition will move the case to a rescinded status.",
      confirmButtonLabel: "Transition Case",
      cancelButtonLabel: "Cancel"
    ),
    height: "AUTO",
    style: "ACCENT",
    shape: "ROUNDED"
  )
)

  Discussion posts and replies are publicly visible

Parents Reply Children
No Data