Inbound Email body not copying to Additional comments in HR case

sri vijaya
Tera Contributor

Hi

My requirement is when HR case is closed,if user responds to any of the email, then the reply of the email body should copy to additional comments and state should change to work in progress

But the email body is not copying to additional comments as i found an inbound action which is working fine for active cases (like if  we send respond to email, email body is copying to additional comments), 

But whereas in inactive cases, the email body is not copying to additional comments section 

i have checked Business rules which i found nothing related to this

pasting the inbound email script

gs.include("validators');
if(current.getTablename() == "sn_hr_core_case");
current.comments="reply from:" +email.origemail+"\n\n"+email.body_text;
current.update();

 

please guide me if i am missing anything

@Ankur Bawiskar @Vishal Birajdar 

6 REPLIES 6

Vishal Birajdar
Giga Sage

Hi @sri vijaya 

 

Functionally , Its not ITIL best practice to re-open closed cases instead open a new case.

But if possible can you send the screenshot of inbound email action ..!! like below

 

VishalBirajdar_0-1695731980746.png

 

 

Vishal Birajdar
ServiceNow Developer

I know one thing, and that is that I know nothing.
- Socrates

sri vijaya
Tera Contributor

yes @Vishal Birajdar   pasting here

 

Hi @sri vijaya 

 

can you try to update field action & check 

 

VishalBirajdar_0-1695732947903.png

 

 

 

 

Vishal Birajdar
ServiceNow Developer

I know one thing, and that is that I know nothing.
- Socrates

sri vijaya
Tera Contributor

@Vishal Birajdar 

so in my case it should set " state to closed complete"?