On RITM, the field "additionnal comments" visible for writing to "Opened by" and "Requested by"

Consultant Busi
Tera Contributor

Hello everyone, (Scope Service catalog ==> catalog item ==> RITM)

 

I want use a script for in the RITM created by a variable opened by, the field additional comments be visible to the requested fro too and that he can write in it.

 

RITM created by "opened by" ==> field "additionnal comments " visible for writing for " opened by" (ootb)

                                                   ==> field " additionnal comments " also visible for writing for "requested for"

 

Thank you for your help (Is this a BR, etc or script to do ?

 

Best regards

Socrate

5 REPLIES 5

Rohit  Singh
Mega Sage

Hi @Consultant Busi ,

 

You can create a before BR in insert and Condition will be item is "Your Catalog item Name" (If you want this functionality for a specific catalog item. If it is for all then you can remove the condition).

 

Use below script:

 

(function executeRule(current, previous /*null when async*/) {

	// Add your code here

current.additional_comments = "RITM Created by: " + current.variables.u_opened_by;   // Here I have taken variable name of Opened By variable as u_opened_by. You can change it as per your variable name.

})(current, previous);

 

If my response helped, please hit the Thumb Icon and accept the solution so that it benefits future readers.

 

Regards,
Rohit

Robert H
Mega Sage

Hello @Consultant Busi ,

 

To make the "Additional comments" field visible to the Opened by/Requested for users in the core ServiceNow user interface, all you need to do is to configure the Requested Item form layout and add that field, as well as "Activities (filtered)", which can be found near the bottom of the left hand list.

You need to make sure to add it to the "Self Service" view of the form.

RobertH_1-1744041558352.png

 

Result (Abel and Miranda are the Opened by / Requested for users in my example):

RobertH_2-1744041678149.png

 

There is nothing required in terms of scripting or ACLs, as the comments are editable for the Requested for / Opened by users by default.

 

Regards,

Robert

 

Ankur Bawiskar
Tera Patron
Tera Patron

@Consultant Busi 

so what did you debug and what's your findings?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Consultant Busi
Tera Contributor

Thank you so much