Service Portal Content link for incidents and Requested items

JR Guieb
Tera Expert

We are using the Service Portal for our ESS users and we have created email notifications with instructions in the bottom that will take our end users to the Service Portal homepage with instructions on how to find their incidents or requested items.

The reason why we setup it up this way instead of using the ${URI_REF} in the email notifications is because the ${URI_REF} will take the user to our non-service portal side for our instance.  

What I am trying to do is to have a way to have a link take them directly to their incident or requested item in the Service Portal.   I looked in the Docs and found this link: Link to content pages but using ${CMS_URI+ess/incident_detail} doesn't take them to the Service Portal it takes them to the ESS page.   I modified it to ${CMS_URI+sp/incident_detail} but that doesn't work it just gives me an error saying "The page you are looking for could not be found".  

How do I modify this ${CMS_URI+ess/incident_detail} so it will take the user to their incident or requested item in the Service Portal?

1 ACCEPTED SOLUTION

Here is the mail script



var url = '';



  if(current.getTableName() == 'sc_request')


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=sc_request&table=sc_request&sys_id=' + current.sys_id + '">' + current.number + '</a>';


  else if(current.getTableName() == 'sysapproval_approver')


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=approval&table=' + current.getTableName() + '&sys_id=' + current.sys_id + '">' + Link + '</a>';


 


  else


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=ticket&table=' + current.sys_class_name + '&sys_id=' + current.sys_id + '">' + current.number + '</a>';




  template.print(url);





And in email notification call the mail script as belo



Click here to view : ${mail_script:NAME_OF_MAIL_SCRIPT}


View solution in original post

8 REPLIES 8

Here is the mail script



var url = '';



  if(current.getTableName() == 'sc_request')


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=sc_request&table=sc_request&sys_id=' + current.sys_id + '">' + current.number + '</a>';


  else if(current.getTableName() == 'sysapproval_approver')


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=approval&table=' + current.getTableName() + '&sys_id=' + current.sys_id + '">' + Link + '</a>';


 


  else


  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=ticket&table=' + current.sys_class_name + '&sys_id=' + current.sys_id + '">' + current.number + '</a>';




  template.print(url);





And in email notification call the mail script as belo



Click here to view : ${mail_script:NAME_OF_MAIL_SCRIPT}


Hi

When we try to implement  portal link on sc_Request table fwithin the notification

it's showing as undefined url in notification

 

  url = '<a href="' + gs.getProperty('glide.servlet.uri') + 'sp?id=sc_request&table=sc_request&sys_id=' + current.sys_id + '">' + current.number + '</a>';

 

Thanks

I don't see any syntax error in the script. Is the mail script used in notification on sc_request table? 

can you share some screenshots ?

Actually that worked for me the issue was with wrong back_end name of field.

 

Thanks though