- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2019 11:24 AM
Hello there ,
We have a catalog item with 2 Variables Variable1 will be displayed on the form and Variable 2 is hidden but available on catalog task when the request is raised the variable1 value entered by the user should be populate in the variable 2 on catalog task ,
I tried Below scenarios : used the On submit client script (its populating the values on catalog task but when ever i save the task all the values are clearing /deleting )
is there a way i can copy values form Variable A to Variable B on catalog Task ?
I also tried on catalog task advance script
task.variable1= current.variable2
and
task.current.variable1= current.variable2
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2019 04:37 AM
kam,
Since you're using a Client script, your values aren't saved to the DB when the page reloads. So, when you add notes to the record, the previous values from the Client script disappear. You'll need to run a Server-side script if you want the values to persist.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2019 12:46 PM
yes when i try assigning to SD ,, its populating the value in SD but as the variable is on the Variable editor as shown in the above image ,, its not setting or may be task. wont work

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2019 01:00 PM
I may be missing the crux of your issue. When you say "it's not setting", what do you mean?
When you submit your request and you look at the task record, you're seeing that the value is in the short description. I was under the impression that you were just trying to grab the RITM value from the variables object and assign it to a task field which it sounds like you're already doing with the short_description task field. What other requirement is there?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2019 03:25 PM
when the variable1 is entered with value "333" and after the request is generated if we are populating the variable1 in SD we are seeing 333 in SD but if we are setting variable1 to variable 2 its not setting .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-13-2019 06:34 PM
I tried Client script on submit to set varible 1 to variable 2 ,, this is working fine but when i update the task with any work notes or any thing all the values are clearing off , not sure why

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-14-2019 04:37 AM
kam,
Since you're using a Client script, your values aren't saved to the DB when the page reloads. So, when you add notes to the record, the previous values from the Client script disappear. You'll need to run a Server-side script if you want the values to persist.