- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-26-2024 08:58 AM
I'm working on a record producer on a scoped application. I need to filter options available on a reference variable based on whether or not another checkbox variable is checked. What I am sharing is a simplified case of what I am trying to do - but I can't even get this simple case to work.
Using 'Advanced' reference qualifier
Reference Qualifier is
javascript: new limitProductDeliverables().limitDels(current.variables.checkbox_variable_name);
I have also tried using the full API name of the script include and nothing happened.
I have tried adding ref_qual_elements=checkbox_variable_name to the Variable Attributes on the reference and it didn't help any.
I have seen no indication that this call is working.
My simplified script include has been tested accessible from all scopes, from this application scope only, and also as client callable and not. Script follows (again this is not what I'm trying to do with the script, I was just trying to make sure I could get the call to work first):
var limitProductDeliverables = Class.create();
limitProductDeliverables.prototype = {
initialize: function() {},
limitDels: function(check) {
gs.info('Product Deliverable value = ' + check);
if (check == 'true') {
return "product_deliverable=A";
}else {
return "product_deliverable=B";
}
},
type: 'limitProductDeliverables'
};
I'm pretty sure that my script include is not even being called and that my reference qualifier is not right, but I feel like I've tried everything I could find. I have very limited experience in script includes.
The checkbox in question is with other checkboxes under a Label on the record producer, so I don't know if that makes a difference. In my frustration to get this to work I even tried 'current.variables.label_name.checkbox_variable_name' in the reference qualifier.
I am simply out of ideas. Does anyone have any thoughts? Will this just not work in a scoped application or a record producer?
Thanks for reading down this far!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2024 08:06 AM
Hello Swathi,
I have an update to share. This morning I decided to try moving the Script Include out of my scoped application and into Global. It worked as written, I didn't need to have variable attributes or client callable.
I have written Script Includes for scoped applications in the past that did work, but not any that were used on a record producer. For whatever reason, it just wasn't working in-scope.
Thank you for your support on this!
Izzy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2024 08:06 AM
Hello Swathi,
I have an update to share. This morning I decided to try moving the Script Include out of my scoped application and into Global. It worked as written, I didn't need to have variable attributes or client callable.
I have written Script Includes for scoped applications in the past that did work, but not any that were used on a record producer. For whatever reason, it just wasn't working in-scope.
Thank you for your support on this!
Izzy