Event Handlers not saving after Mango 3
-
Hello
I can no longer create or edit new event handlers running processes.
When saving event handler PROCESS I get this error. I also noticed that the "command" under Process of all the event handlers that existed previously is also gone.
I am running Version 3.3.4. I updated to latest to see if it helps.
WARN 2018-04-11T13:09:27,407 (com.serotonin.m2m2.web.dwr.MiscDwr.jsError:176) - Javascript error Description: Uncaught TypeError: Cannot read property 'dataSourcePermissions' of undefined Page: http://myURL/event_handlers.shtm Line: 1557 Browser name: Chrome Browser version: 65 osName: Windows location: http://myURL/event_handlers.shtm
-
Hi glamprecht,
Thanks for bringing that to our attention. I have fixed it. The good news is you can fix it without updating or restarting by editing Mango/web/WEB-INF/tags/scriptPermissions.tag
Changing the function,
function setScriptPermissions(permissions){ $set('scriptDataSourcePermission', permissions.dataSourcePermissions); $set('scriptDataPointSetPermission', permissions.dataPointSetPermissions); $set('scriptDataPointReadPermission', permissions.dataPointReadPermissions); }
to
function setScriptPermissions(permissions){ if(typeof permissions === 'object') { $set('scriptDataSourcePermission', permissions.dataSourcePermissions); $set('scriptDataPointSetPermission', permissions.dataPointSetPermissions); $set('scriptDataPointReadPermission', permissions.dataPointReadPermissions); } }
You may need to delete your Mango/work/jsp directory as well.
-
This worked. Thank you.