- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:35 AM
Hi all,
I have created a select box type variable with no question choices, the question choices of select box are added dynamically from one of the table by using catalog client scripts and script include(g_form.addOption()).When submitting the catalog item, I am used to see the frond end value, but after submitting the cat item in the RITM variable editor section it is showing the backend value(in blue color). Can anyone please help me on this.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:59 AM
Hi,
As I mentioned above, it would also need to apply onLoad...because the catalog item isn't "changing" on the request item, right?
So when the form is loading, your addOptions aren't loading, thus no display value, thus the back-end value that was previously chosen on the catalog item shows.
Please re-read my post above.
Alternatively, you can reference the selections from another table via a different catalog item variable type and then filter to only specific selections, instead of trying to code everything. However, if your situation is a bit more complex than that would allow, then the way you have it is fine, you just need to compensate for it via an onLoad client script as I've mentioned above.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:48 AM
Hello,
Does your client script also apply on the request item and/or catalog task records?
Within that script on your catalog item, you can select other areas it will also be working on.
For those, it would need to have onLoad functionality versus just onChange (with no onLoad ability).
Essentially, the select-box needs to be populated in other areas of the platform and not just within the catalog item itself.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:56 AM
Hi Allen,
It applies on requested item and catalog task records also. And it is onchange client script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:59 AM
Hi,
As I mentioned above, it would also need to apply onLoad...because the catalog item isn't "changing" on the request item, right?
So when the form is loading, your addOptions aren't loading, thus no display value, thus the back-end value that was previously chosen on the catalog item shows.
Please re-read my post above.
Alternatively, you can reference the selections from another table via a different catalog item variable type and then filter to only specific selections, instead of trying to code everything. However, if your situation is a bit more complex than that would allow, then the way you have it is fine, you just need to compensate for it via an onLoad client script as I've mentioned above.
Please mark reply as Helpful/Correct, if applicable. Thanks!
Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2022 06:48 AM
Yes, this is expected one. Keep both label and back value as same in your g_form.addOption() script. So that, user can see readable data.
