But in the Tasklist I am getting below error:
**An error happend while submitting the task form : **
Cannot submit task form e974bf48-92bf-11e6-99c6-d43d7ec7ada1: Unable to evaluate script: sun.org.mozilla.javascript.internal.EcmaError: SyntaxError: Empty JSON string (#1) in at line number 1
Consider Below as the JSON Response:
{
“recordSetTotal”: “1”,
“resourceName”: “productview”,
“recordSetComplete”: “true”,
“recordSetStartNumber”: “0”,
}
Just do response;in your script and open cockpit and inspect the process instance. Show me a pic of the data being stored as a string. It sounds like you are not getting your rest response back from your API call
Today I am not able to move from the 1st activity(Provide Product ID), after submitting in the Tasklist it says:
**An error happend while submitting the task form : ** Internal Server Error
I am not able to hit the http URL from the Service Task after entering the ProductID (the URL is correct and its giving proper response when tried in Web Browser).
Follow through and use the example BPMN file. There are also some updates further down in the thread so make those changes to the BPMN file. Replace the sample URL in the BPMN file with your URL. If it does not work then you have a issue with your URL. The example in the post works and has worked for multiple people with similar issues as you described.
Likely you have a config issue in your BPMN.
I tried this code in appendID.js file
var productid = execution.getVariable(“productId”);
var url = “http://abc/”+productid+ “?responseFormat=json”;
execution.setVariable(“url”, url);
and in Name= url
Type = Script
Script Format = “JavaScript”
Script Type = “External Resource”
Resource =“appendID.js”
ERROR: An error happend while submitting the task form :
HTCL-02005 Request url required.