Mapping multiple fields to Incident description

LP4
Kilo Contributor

Hi all,

Hoping for some guidance on this one..

We are looking to create a new Record Producer for submitting an incident. Ideally it should pull info from numerous fields into the producer.description field.

However when setting this up it only one source of data pulls through. Have used the field mapping tool to point to the producer.description field but only one appears.

Also we have amended the script to try and test but still not working:

current.description = producer.comments + producer.issue_2;

It pulls through the comments but nothing from our issue_2 field, which is a select box. Would this make a difference?

Any help and guidance appreciated.

Thanks

L

1 ACCEPTED SOLUTION

Brad Tilton
ServiceNow Employee
ServiceNow Employee

Something like that should work, but the value from your issue_2 variable will be appended directly to the end of the comments. I wonder it's just easy to miss that way. You might try something like:

current.description = producer.comments + '\n\nIssue: ' + producer.issue_2;

Also, that's going to give you the value from the select box, so if you want the display value you'll need to add .getDisplayValue() to the end of issue_2.

View solution in original post

1 REPLY 1

Brad Tilton
ServiceNow Employee
ServiceNow Employee

Something like that should work, but the value from your issue_2 variable will be appended directly to the end of the comments. I wonder it's just easy to miss that way. You might try something like:

current.description = producer.comments + '\n\nIssue: ' + producer.issue_2;

Also, that's going to give you the value from the select box, so if you want the display value you'll need to add .getDisplayValue() to the end of issue_2.