Add shortcut link on Doctype Dashboard

Add shortcut link on Doctype Dashboard


For E.g above Employee Dashboard, you can add some link suppose Training Events & Result.
Step 1. Go to particular doctype. then edit following python file
erpnext->erpnext->hr->doctype->employee->employee_dashboard.py
paste this code

from frappe import _

def get_data():
return {
'heatmap': True,
'heatmap_message': _('This is based on the attendance of this Employee'),
'fieldname': 'employee',
'transactions': [
{
'label': _('Leave and Attendance'),
'items': ['Attendance', 'Leave Application', 'Leave Allocation']
},
{
'label': _('Payroll'),
'items': ['Salary Structure', 'Salary Slip', 'Timesheet']
},
{
'label': _('Training Events/Results'),
'items': ['Training Event', 'Training Result']
},
{
'label': _('Expense'),
'items': ['Expense Claim']
},
{
'label': _('Evaluation'),
'items': ['Appraisal']
}
]
}

Now you can see link added on Doctype Dashboard.

Community Forum: https://discuss.erpnext.com/
ERPNext Hosting

Comments