automa
automa copied to clipboard
Firefow wokflow event don't run with JS
Hello,
If we create a Javascript script in "Settings-Worflow Event- on action Finish (fail or success)."
The Javascript script is never triggered. No error (of course).
If we use httprequest it works.
Under Chrome everything works (Httprequest) and of course the same JS script.
Same problem with Firefox and Linux.
The code JS
`const workflow = automaRefData('workflow'); const wfl = workflow.logs; const workflowlast = wfl[wfl.length-1];
const date1 = new Date();
const datefr = date1.toLocaleString('fr-FR',{ weekday: 'short', day: 'numeric', month: 'short', year: '2-digit', hour: 'numeric', minute: 'numeric', second: 'numeric'});
fetch("http://192.168.100.18:8089/api/webhook/tokenxxxx", { method: "POST", body: JSON.stringify({ Status: workflow.status, ErrorBlock: workflowlast, ErrorMessage: workflow.errorMessage, DateError: datefr }), headers: { "Content-type": "application/json; charset=UTF-8" } });`
Firefox : 129 Windows : 10 Automa : 1.28.27
Thanks