Error while invoking process inside interface in SaveInto of "SubmitLink"proce

Using the below code to trigger a process upon clicking on an iconindicator image. Used SubmitLink to show confirm message and upon confirming, the process model is triggered, but still throws the error in the image below. Please advise if anything wrongly save into target variable inside the SubmitLink which is where the error is pointing to.

Code

a!imageField(
label: "Take Action",
showWhen: ri!enableTriggerImages,
images: {
a!documentImage(
document: a!iconIndicator(
"MOVE_RIGHT"
),
showWhen: isnull(rule!NSA_GetStatusOfApprovalTeam_ExprRule(ri!NSARequest, fv!item)),
altText: "Submit",
caption: "Submit " & fv!item,
link:
a!submitLink(
label: "Submit for Review",
confirmHeader: "Please confirm!",
confirmMessage: "Please confirm to submit.",
confirmButtonLabel: "Confirm",
confirmButtonStyle: "PRIMARY",
/*value: ri!NSARequest,*/
saveInto: {
a!startProcess(
processModel: rule!NSA_GetPMConsByTeam_ExprRule(fv!item),
processParameters: {
NSARequest: ri!NSARequest,
cancel: false,
newComments: null,
taskRequest: true,
teamToAssignTask: rule!NSA_GetGroupByTeamName_ExprRule(fv!item),
updateRequest: false
},
onSuccess: a!save(
ri!NSARequest,
null
),
onError: a!save(
ri!NSARequest,
null
)
)
}
)
),

a!documentImage(
document: a!iconIndicator(
"MOVE_RIGHT_DISABLED"
),
showWhen: not(isnull(rule!NSA_GetStatusOfApprovalTeam_ExprRule(ri!NSARequest, fv!item))),
altText: "Action Completed.",
caption: "Action Completed."
)
},
size: "ICON"
)

Error:

  Discussion posts and replies are publicly visible

Parents
  • +1
    Certified Lead Developer
    Hi
    Couple of things here:

    1. You are looping over an item in forEach(), may i know what does a fv!item returns, can you try printing an item first in a textField, is that a CDT or a normal type variable such as Text, Integer etc..?

    2. What's the return type of rule!NSA_GetPMConsByTeam_ExprRule()? is that of type Process Model but not null() or Process Model?List

    3. Why are you using onSuccess, onError when you want to save only null? In such case simply you can remove it.

    As per my understanding, it will be better if you can attach the complete SAIL code of this interface along with the details about the return type of their respective expressions and variables. This will help the practitioner to understand and resolve the issue quickly.
  • After removing onSuccess, onError it is working fine. Thank You all.
Reply Children
No Data