dynamic required attribute does not work - RTC 3.0.1.1
Whatever I do, I get errors in the ccm log (see below) and the work item just saves.
This is RTC 3.0.1.1, no patches on win 2003 server, my "play" vm.
I found several posts where users posted working dojo scripts and I also tried to just stick in the sample in the Attribute Customization - Condition. It shows the Class Name, so I am thinking that it reads the dojo just fine.
I tried it in JKE banking and a pretty vanilla scrum project.
Any ideas what I need to tweak to make it work?
2013-03-13 11:48:31,283 [ http-9443-Processor345] ERROR com.ibm.team.workitem.common - Error invoking work item filter 'com.ibm.team.workitem.valueproviders.CONDITION._CkdmQIwGEeK7UttOCWjckg'
org.mozilla.javascript.JavaScriptException: [object Error] ({"Bundle-SymbolicName":"org.dojotoolkit.dojo", "path":"resources\\_base\\_loader", "name":"loader.js"}#414)
at org.mozilla.javascript.gen.c2._c18({"Bundle-SymbolicName":"org.dojotoolkit.dojo", "path":"resources\\_base\\_loader", "name":"loader.js"}:413)
at org.mozilla.javascript.gen.c2.call({"Bundle-SymbolicName":"org.dojotoolkit.dojo", "path":"resources\\_base\\_loader", "name":"loader.js"})
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:401)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3003)
at org.mozilla.javascript.gen.c2.call({"Bundle-SymbolicName":"org.dojotoolkit.dojo", "path":"resources\\_base\\_loader", "name":"loader.js"})
at com.ibm.team.rtc.common.scriptengine.environment.dojo.DojoFeature$3.call(DojoFeature.java:179)
at org.mozilla.javascript.ScriptableObject.callMethod(ScriptableObject.java:1862)
...... (lots more, I can post if needed)
Accepted answer
I had something similar a few days ago and thought the server was wrong. Nope, I just had messed up the syntax in a way that the loader failed.
Brackets? Statements outside of the scope they are supposed to be? Semicolon missing? Hard to tell. We tried to provide some guidance in this workshop Lab 5.
I would suggest to check the script syntax. In my case I lazy bone did copy paste and missed that it had put an odd string outside of my inner brackets.
Comments
Hmm. There is a "download sample" URL right there and I gave it the exact file that it saved. I can do it again. The sample file that gets downloaded should work as is, right?
Martina,
provided the Script Attachments are enabled, the sample scripts should at least load an be processed. You should also be able to debug them as described in the process enactment workshop.
I still get the same error. I deleted everything and did it again with new filenames, I didn't edit the content. I saved the sample-condition.js and gave that to it unedited. I originally saved it in My Documents, but I also saved it in C:\rtc_js and in both Unix and win line endings.
Same error all the time.
You say "provided Script Attachments are enabled". How do I check that? (and how do I enable it if it isn't obvious from the check location)
This is 3.0.1.1.
I found https://jazz.net/forum/questions/92320/how-can-i-enable-the-process-attachment-script-in-jazzhub and I don't see that in my admin
I don't know when that feature came in.
Go to your CCM application https://<host>[:<Port>]/ccm/admin
Go to the Advanced Properties section
Use your browser search to search for "Enable Process Attachment Scripts"
The default is false, you have to change it to true and save, to enable them.
See the workshop I mentioned above.
it came in in 3.0.1 according to the Library article I started out from.
SUCCESS. The Enable Process Attachment Scripts was the piece I was missing. I needed to make sure to look in ccm/admin
Thanks for all your help
That was long Martina.We could have saved a lot of time if you had looked into the workshop 8-p. Glad you have it working now. PS, I tend to forget it is switched off in my test repositories too....