Add Approval History to work notes

annasc
Tera Contributor

Hi,

We created a new table (u_requisition) which extends from the Purchase Order table.

I'm trying to display the history approval either in the history log or in the work notes

and have had no luck.

I've already done the following:

Select the Yes check box for the Log User approval activity - such as requested, approved and rejected - in the Approval History journal when using workflows to manage the approvals for a task. property.

I made sure the table was auditable.

I also tried creating a new field "Approval History" with 'Journal' type since it wasn't available in my new table (that didn't work)

I would like to display in the history log (or in the work notes, if possible) the name of the approvers triggered by the workflow and

the names of the manually added approvers.   Or display the 'Approval History' however since this is a new table I tried creating

the field "Approval History" with a 'Journal' and that doesn't seem to work.

Can someone please help me how to include the Approval History in the history log (or work notes)?

Or maybe provide a script for a business rule that would help me achieve this requirement (please kindly include the script)?

I'm not great with scripting.   Thank you!

Thanks,

Anna

4 REPLIES 4

Goran WitchDoc
ServiceNow Employee
ServiceNow Employee

Hi Anna,



Perhaps the OOB functionality with a "approvals" related list would be enough? Here you can see who did what and when etc..
find_real_file.png



Otherwise I would probably do a Async Business Rule from the approval table that trigger on the approval is for a record from a specific table and if so, update that record with a new comment/work notes.



//Göran


Hi Goran,




I'm not good with scripting. Can you provide a script sample of the Business Rule? I'd really appreciate it. Thank you!




Thanks,



Anna


sndangibbard
Mega Guru

Anna



Approval functionality runs on Task tables (Task and everything extended from it). If you need to use approvals on your custom table then I would suggest extending the Task table rather than Purchase Order (which itself is not extended from Task)



Thanks


Dan


Hi Dan,




Thank you, but we've already implemented Requisition in production so unfortunately we can't extend from the task table. If you have any suggestions on how to create a new approval_history in the Purchase Order table or have suggestions on a BR script, please let me know. Thank you!




Thanks,



Anna