Link to approval in notification for non-task approval

Stacy1
Mega Guru

Hello,

I am unable to create a notification on the sys_approval table for my approvals being generated on a non-task table.   Therefore I have a trigger on when to send these notifications and I can provide the information from the table they are approving on, but I am unable to give them a link to the approval record only to the table's record.

Has anyone ever been able to create a mail script that will take them to the sys_approval record generated for the custom table?

I hope that's not to confusing.

Thanks,

Stacy

1 ACCEPTED SOLUTION

Stacy1
Mega Guru

I was able to create a notification on the sys_approval table.   I created an event registry with my tablename.approval.insert.   I used this event as the trigger on my notification.   In order to get links in to the item being approved in the email, I had to use document_id.URI as the regular sysapproval.URI would not get to the item being approved.



Thanks for your suggestions.


View solution in original post

6 REPLIES 6

Hello Stacy,

I have the same problem, but I can't use the event registry with name 'tablename.approval.insert' as this gets triggered for every new approval record and I have to send different notifications based on different conditions on approval of the same table.

 

I tried triggering same notification from a different event name than tablename.approval.insert, in this case the appoval doesn't work.

Do you know anyway by which I can acheive this?

 

Thanks in advance

You will need to go in to the regular approval email and tell it not to send for the particular type.  Does it have it's own numbering?  You can build a condition: approval for - does not contain - CHG (example).  Here is the script we use when we have designed special approvals on catalog items.

 

if (current.document_id.cat_item.sys_id == 'cb640f9b6f84590006d7bc226e3ee4cc' || current.document_id.cat_item.sys_id == '7ad3f5fd6fc0190006d7bc226e3ee446' || current.document_id.cat_item.sys_id == 'f3ea69f713dc66000439b2228144b01a'){
answer = false;
}
else{
answer = true;
}