Business rules Server side scripting

Phani Pasupulet
Tera Contributor

when a caller is selected in the incident table, then the caller's mail id
should be shown as an Info message/alert. (Do not use Client Script).

5 REPLIES 5

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @Phani Pasupulet 

 

What is the question here, so that we can help you.

 

Please mark this response as correct or helpful or the solution accepted if it assisted you with your question.

Regards
Atul G.
Learn N Grow With Atul G

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Clara Lemos
Mega Sage
Mega Sage

Hi @Phani Pasupulet ,

 

In the advanced tab of the business rule you can add : 

gs.addInfoMessage(current.caller_id.email);
 
You can set the business rule to run on display when caller is not empty, the info message will always be shown at the top of the form. 
 
Let me know if that suits your requirement !
 

praneeth7
Tera Guru

Hi @Phani Pasupulet 

using this script you can show a info message with caller's email id, But this will not work unless you save the form.

var email = current.caller_id.email;
	gs.addInfoMessage(email);

 If you want to show the caller's email id on Change, then you can use scratchpad in BR and pass the value to CL

Display Business Rule:

g_scratchpad.email = current.caller_id.email;

Client script:

var email = g_scratchpad.email;
alert(email);

 

I want it for on change but without using lient script