How to delete last employee activity(timeline items)

Hello, ERPNext World!
In erpnext, each employee activity is shown on the employee page (below comments area)

In my project, I make some fast testing in Leave Application doctype by this user. Then I delete it.
My question is how can I delete this information(timeline items) from employee page

Thanks all

1 Like

@OmarJaber

You cannot delete the activities. But you can hide that particular “Tools” module for your users.

Sorry, Its not working
It still there !

@OmarJaber

This is not possible as of now. Can you please create a GitHub issue for this?

1 Like

Is there any guide available to hide this timeline activity from Employees?

@rogger

Not Yet…!!!

Is there any custom script to hide it?

yes, yo can include any js file in hook

then add this jqueary code inside the js file
$(".timeline").hide()

awesome @OmarJaber How can I disable this script for site admin only? Currently, I put this inside the custom script.

frappe.ui.form.on(‘Employee’, {
refresh(frm) {
// your $(function() {
$(’.timeline’).hide(); // or .remove();
}
})

you can check if current session user is admin then pass

Hi @OmarJaber. Thanks for reply. Where do I have to check this option?