Commision Payroll


I wondering how i can add commision in sallary generate tools ? is there any hooks or configuration that i can code thats will not affec the erpnext core?

Because i dont want to edit erpnext basic, because it will be bad when we do update


You should add a custom field for commission in Salary Slip form. And write a method in your app which will calculate the commission. Then in, specify the doc_events for “Salary Slip” validate method, mention the path of newly created function there.


is there any example for adding hooks? will be very helpful if there was an example


Check erpnext/ at develop · frappe/erpnext · GitHub

Hi Nabin,

Thanks for the example, but one more question, this hook just add some calculaation or i will ovveride the original method with the one i created?


Replied via Hourly Payroll Calculation