Hi,
we upgraded to JIRA 7 from v6.4.11 to v7.1.4 and ScriptRunner form v4.1.3.15 to v4.3.4. Since then some of the behaviour scripts (triggered at ticket creation) doesn´t work anymore. If I remove the following script evertything works as it should. But we need this script.
I have activated the logging but there are no errors in the log.The script validation say: unable to resolve class FormField. I have tried to switch from FormField to def - it does not work.
image2016-7-4 15:45:53.png
Any idea how to solve this issue?
Kind regards, Benjamin
FormField FieldKategorie11507 = getFieldById ("customfield_11507")
FieldKategorie11507.setHelpText("<script type=\"text/javascript\">FieldKategorie11507_Value=document.getElementById(\'customfield_11507\');\
FieldTechnPL_1=document.getElementById(\'customfield_12002\').parentNode;\
FieldTechnPL_2=document.getElementById(\'customfield_12002\');\
FieldFachlPL_1=document.getElementById(\'customfield_12003\').parentNode;\
FieldFachlPL_2=document.getElementById(\'customfield_12003\');\
FieldLinkKPLaufwerk_1=document.getElementById(\'customfield_12004\').parentNode;\
FieldLinkKPLaufwerk_2=document.getElementById(\'customfield_12004\');\
FieldLinkAlfi_1=document.getElementById(\'customfield_11401\').parentNode;\
FieldLinkAlfi_2=document.getElementById(\'customfield_11401\');\
switch(FieldKategorie11507_Value.value){case\'11222\':\
var value=\"gginf22\";\
AJS.\$(\"#assignee-field\").val(value);\
AJS.\$(\"#assignee\").find(\":selected\").data(\"descriptor\").model()[0].value=value;\
AJS.\$(\"#customfield_12002\").closest(\'div.field-group\').hide();\
FieldTechnPL_2.value=\"\";\
AJS.\$(\"#customfield_12003\").closest(\'div.field-group\').hide();\
FieldFachlPL_2.value=\"\";\
FieldLinkKPLaufwerk_1.style.display=\'none\';\
FieldLinkKPLaufwerk_2.value=\"\";\
FieldLinkAlfi_1.style.display=\'none\';\
FieldLinkAlfi_2.value = \"\";\
break;\
case\'11223\':\
var value=\"gginf22\";\
AJS.\$(\"#assignee-field\").val(value);\
AJS.\$(\"#assignee\").find(\":selected\").data(\"descriptor\").model()[0].value=value;\
AJS.\$(\"#customfield_12002\").closest(\'div.field-group\').hide();\
FieldTechnPL_2.value=\"\";\
AJS.\$(\"#customfield_12003\").closest(\'div.field-group\').hide();\
FieldFachlPL_2.value=\"\";\
FieldLinkKPLaufwerk_1.style.display=\'none\';\
FieldLinkKPLaufwerk_2.value=\"\";\
FieldLinkAlfi_1.style.display=\'none\';\
FieldLinkAlfi_2.value = \"\";\
break;\
case\'11226\':\
var value=\"rmb10004526\";\
AJS.\$(\"#assignee-field\").val(value);\
AJS.\$(\"#assignee\").find(\":selected\").data(\"descriptor\").model()[0].value=value;\
AJS.\$(\"#customfield_12002\").closest(\'div.field-group\').show();\
AJS.\$(\"#customfield_12003\").closest(\'div.field-group\').show();\
FieldLinkKPLaufwerk_1.style.display=\'\';\
FieldLinkAlfi_1.style.display=\'\';\
break;\
default:\
var value=\"-1\";\
AJS.\$(\"#assignee-field\").val(value);\
AJS.\$(\"#assignee\").find(\":selected\").data(\"descriptor\").model()[0].value=value;\
AJS.\$(\"#customfield_12002\").closest(\'div.field-group\').hide();\
FieldTechnPL_2.value=\"\";\
AJS.\$(\"#customfield_12003\").closest(\'div.field-group\').hide();\
FieldFachlPL_2.value=\"\";\
FieldLinkKPLaufwerk_1.style.display=\'none\';\
FieldLinkKPLaufwerk_2.value=\"\";\
FieldLinkAlfi_1.style.display=\'none\';\
FieldLinkAlfi_2.value=\"\";\
break;}</script>")