- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-18-2016 11:59 PM
Hi,
I have created a catalog item where i'm using two variables "category" and "sub category" which are of reference type.
Based on the value chosen in "category", the values in "sub category" are filtered.The following code is used in the subcategory's Reference qual condition.
javascript: new scriptincludeName().functionName(current.variables.category)
I'm passing the category value as a parameter to a script include function. But current.variables.category returns undefined.
Please share your suggestions to fix this issue.
Regards,
Kamal
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-25-2016 03:20 AM
Servicenow has suggested to clone the instance fix this issue.
Regards,
Kamal

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-19-2016 12:08 AM
Hi Udhay,
Please go through the below wiki link for more info on how to use reference qualifier for catalog item.
Reference Qualifiers for Service Catalog Variables - ServiceNow Wiki
Reference Qualifier on Lookup Select Box Variable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-19-2016 12:22 AM
Thanks Pradeep, But the issue is current.variables.variablename returns undefined.
Also when i tried using the "current.variables.variablename " directly inside script include its still returning undefined.
Moreover this issue is occurring in only one instance. The same code returns correct value in other instances.
Regards,
Udhay

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-19-2016 12:23 AM
variablename is correct?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-19-2016 12:35 AM
Yes, variable name is correct. I have also tried passing current instead of the varaible value object to script include and retrieve the value from there but no luck.
This issue is happening in that specific instance for all Reference variables wherever i try to use current.variables.variablename inside Reference Qual condition.
Regards,
Udhay